Born_at(1i) ?!?


#1

When I use scaffold,
if I have a datetime field in the model, in the view there is some combo
to set the date and time.

The HTML source has the combos with the names
name=“user[born_at(1i)]”
name=“user[born_at(2i)]”
name=“user[born_at(3i)]”

someone can explain how work "born_at(?i) " ? or suggest some page page
who explain than

thank you,
Alessandro


#2

It’s one of (IMHO) the most hidden rails feature :smiley:
You can find the method (and some info) by looking directly in the rails
source file (
http://github.com/rails/rails/blob/ee5520a0a5ea83843ce88f6b9550e3c36b8cdd49/activerecord/lib/active_record/base.rb#L3029)

Sandro


#3

You’re right ! ruby code is the best documentation :smiley:

Thank you,
Alessandro

Sandro P. wrote:

It’s one of (IMHO) the most hidden rails feature :smiley:
You can find the method (and some info) by looking directly in the rails
source file (
http://github.com/rails/rails/blob/ee5520a0a5ea83843ce88f6b9550e3c36b8cdd49/activerecord/lib/active_record/base.rb#L3029)

Sandro