Displaying 20 results from an estimated 2000 matches similar to: "Default in date_select"
2006 Jul 26
1
Plz answer my query in date_select
hello gentlemen
I want to set my (default)own date in date_select, how to do this, plz
explain with example
advance thx
have a nice day
regards
narayana
--
Posted via http://www.ruby-forum.com/.
2006 Jan 07
4
set date with date_select
when retreiving a date from a DATETIME field in a database, is there a
way to set the date to the value of the DB in the view? It seems to
always default to the current date...
if I have a field called birthdate in the users table and i do
@user = User.find(@params[:id])
in my view i have a <%= date_select ''birthdate'',''user'' %>
but dont know how to
2006 Nov 22
6
My Rails Blog
Hi guys,
I have created a new blog for Rails people from chennai.
chennairails:
http://chennairails.blogspot.com/
please visit my blog.
Sorry for making noise.
ok bye bye
regards,
Karthick.
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails:
2006 Oct 26
8
doubt in Selenium test
Hi guys,
I am just started to do selenium test in rails. can u guys plz tell me
how to write selenium test for the below code. for ex: i want to use
click action in selenium test for the below code
<a href="#" onClick="javascript:show_form(''short'');">Add a Short Media
Buy</a>
advance thx
regards,
Karthick.
--
Posted via
2006 Jan 19
2
date_select broken
I am using date_select and in some instances it only shows about 10
years worth of choices. Same form on other users shows the whole
range. date_select looks like this
<%= date_select ''user'',''birthdate'' , :start_year => 1940 %>
I would expect to always see 1940-2006 or so , but i dont always do.
Is there a way to force the range or explain why i
2005 Feb 15
5
date_select where to add "class"=>"something"
Hi,
I''ve looked on api.rubyonrails.org but I''ve not found how to add to a
date_select(object, method, options = {}) a class option to set the
class of all the select tags.
I''ve tried using "class" => "myclass" in thoose ways:
<%= date_select("costo", "data", "class" => "testo" ) %>
<%=
2006 Nov 04
2
date_select parameter
Trying to add start year to date_select
<%= date_select(:start_year => 1980)%>
It''s throwing an exception "wrong number of arguments (1 for 0)
Can''t I add a start_year, API shows this option ?
TIA
Stuart
http://en.wikipedia.org/wiki/Dark_ambient
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the
2006 Sep 29
7
help needed in UNIT Testing
hi guys,
I needed help in Unit test. i just try to save new data intomy test
database.
but save method does not works for me. the result shows here
def test_new_avail
avail = Avail.new(:vendor_id => 1,
:last_mod_by => ''Murali'',
:updated_at => ''2006-08-17 13:14:59)
assert avail.valid?
assert avail.save
end
2005 Dec 15
1
date_select help
I''m trying to select items from a database by their date field. The date
data is coming from a form using the date_select helper.
The field in the database is named date_notified_on.
My controller method is this:
def history_date
if(@params)
@notifications = Notification.find(:all, :conditions =>
["date_notified_on = ?",
2006 Jul 26
2
text_field and date_select in collection
hello,
i would like to display a collection of records on one page (e.g. an
author record with all his/her books).
a record contains a text_area (e.g. a description of the book) and a
date_select (e.g. when the book was published).
<% for @book in @author.books %>
<%= text_area ''book[]'', ''note'' %>
<%= datetime_select
2006 Nov 15
1
how to handle alert box message in selenium test?
hi guys,
how to handle alert box message in selenium test?
i want to handle alert box. i want to test(verify text present) the
text in alert box & then click ok to alert box. how can i do this.? plz
tell me...
advance thx.
regards,
karthick.
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are
2005 Apr 20
1
default date in date_select?
Hi there,
I''m new to Rails -- started with this project just about five days ago
-- I''m re-building an in-house ordering tool, and it would be handy to
pre-populate a date_select field with a value two weeks from now. The
calculation isn''t the hard part, it''s getting date_select to
pre-populate itself.
Any suggestions?
Thanks,
--Jim
2009 Mar 13
2
date_select and HTML options?
I have the following code, but can''t seem to get the class attribute
to show up in the generated select elements. I saw something about a
bug/patch. However, as am still learning RoR I didn''t want to jump to
conclusions. Anyone see anything wrong:
<%= f.date_select :expiration_date, :order =>
[:month, :year], :discard_day => true, :class => "dtfld" %>
2007 Oct 13
5
default date for date_select
Hi,
How can I set a default date for a date_select?
I''m trying to do something along the lines of:
<%= date_select("requirement", "target_date", :end_year =>
2020, :discard_day => true, :include_blank => true, :order =>
[:month, :year], :default => {:month => 10, :year => 2012 }) %>
but the default that comes up on the form is blank month
2010 Jul 31
5
date_select Year as a text_field
Hey all,
Using date_select in a form, how can I make the Year field a
text_field instead of a select? It looks like it will take more than a
simple modification of the date_select method.
Thanks in advance.
Cam
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to
2006 May 10
2
Rails, Postgres and the Date Field.
Hi guys,
I''m having problems with my app. First of all, I created a date_select
with the code:
<%= date_select(''contact'', ''birthday'', :order => [''day'',''month'',''year'']) %>
In the contacts table, I create a date field:
birthday DATE
When I save the values goes wrong into the database.
2008 Oct 31
3
Date_select vs wrong date weird behavior
In my date_select if I choose 31 april 2008, it converts it for 1st may
2008 which it seems odd for me?
I say odd because first its difficult to validate at the model level, I
have to hook some code in the controller and secondly when I finally get
the validation errors I have to go back at the edit page and show the
selected date(and the error message) which should be 31 april 2008 but
the date
2007 Jun 13
3
date_select css options
Just looked at the Date helper in the rails API and noticed that none
of the functions there (i.e. date_select) allow me to specify html
options (i.e. class) for the generated selects.
I was wondering how do other group members css format date select
dropdowns?
Best,
Gabor
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
2006 Jun 12
2
date_select() in collection
Hi,
I am doing the following:
<% obj.contracts.each do |@contract| -%>
...
<%= hidden_field("contract[]", :contractor_id, :index =>
@contract.contractor.id) %>
<%= date_select("contract[]", :starting_on, :index =>
@contract.contractor.id) %>
...
<% end -%>
Here are the request parameters:
{"commit"=>"Save",
2006 Feb 28
1
Working with date_select ...
I am a little confused about the best way to work with date_select. I see that
in my views it generates a simple input form that allows for the entry of year,
month and date information. If I just leave it at that, great!
But what if now in the controller, I want to work with the date information. I
actually want to take the user input date and compute a new date some number of
days in the