This project is archived and is in readonly mode.
time scaffolding uses datetime_select, stores as time
-
Steve St. Martin
- Assigned user set to Ryan Bigg
verified this behavior still exists on both 2.3.5 and master, this issue is probably not mission critical as scaffolds can be changed easily, please submit a patch. for now can probably as mark incomplete.
-
Ryan Bigg
- State changed from new to incomplete
-
Dan Pickett
- Tag changed from 2.3.2, datetime, scaffold, time, time_select to 2.3.2, bugmash, datetime, scaffold, time, time_select
-
Jeff Kreeftmeijer
I've attached a patch that makes sure the scaffold's _form partial uses
time_selectinstead ofdatetime_selectwhen dealing with time attributes. The first one applies to master and the second one's for 2-3-stable. :) -
Robert Beekman
+1
applies cleanly to master, tests pass.
-
Rizwan Reza
- Tag changed from 2.3.2, bugmash, datetime, scaffold, time, time_select to 2.3.2, bugmash, bugmash-review, datetime, scaffold, time, time_select
- State changed from incomplete to verified
-
Jeremy Kemper
- Milestone changed from 3.x to 2.3.6
- State changed from verified to incomplete
No regression test.
-
Rizwan Reza
- Tag changed from 2.3.2, bugmash, bugmash-review, datetime, scaffold, time, time_select to 2.3.2, bugmash, datetime, scaffold, time, time_select
-
Santiago Pastorino
We need to complete test the generation behavior not only the time one.
Please try to do it. -
Jeff Kreeftmeijer
I've attached a patch for master with tests for the Rails::Generators::GeneratedAttribute#field_type method and included my previous patch. What do you think?
I can this for 2-3-stable as well if you guys like it. :)
-
Santiago Pastorino
Nice Jeff, but you should do all in one patch
-
Jeff Kreeftmeijer
One patch, or one commit? The last patch has everything in it (but two commits). :)
-
Santiago Pastorino
- State changed from incomplete to open
- Assigned user changed from Ryan Bigg to José Valim
one commit only
-
Jeff Kreeftmeijer
Ok, I squashed the commits in the master patch and added the same one for 2-3-stable. Here we go. :)
-
Santiago Pastorino
- Milestone cleared.
- State changed from open to verified
Well done Jeff +1 ;).
Wait for José to push to master and 2-3-stable. -
Rizwan Reza
- Tag changed from 2.3.2, bugmash, datetime, scaffold, time, time_select to 2.3.2, bugmash-review, datetime, scaffold, time, time_select
-
Repository
- State changed from verified to resolved
(from [3568c5cee0f37f3302d739472be7477bee1b0d2a]) using :time_select when the attribute type is :time in the scaffold generator. [#2377 state:resolved]
Signed-off-by: José Valim jose.valim@gmail.com
http://github.com/rails/rails/commit/3568c5cee0f37f3302d739472be747... -
Repository
(from [4750e61bfecd210e5c4d96546d638b5cd23bb09e]) using :time_select when the attribute type is :time in the scaffold generator. [#2377 state:resolved]
Signed-off-by: José Valim jose.valim@gmail.com
http://github.com/rails/rails/commit/4750e61bfecd210e5c4d96546d638b... -
José Valim
- State changed from resolved to open
Ops, I forgot to apply the patch with tests. I just asked Jeff on #railsbridge to refactor the current tests (using something like assert_attribute_type and remove the code duplication) and provide new patches with only tests!
-
Jeff Kreeftmeijer
And here they are. I've attached a patch for master adding
assert_attribute_typeto DRY things up, with the forgotten tests. Also, one for 2-3-stable. :) -
Repository
- State changed from open to resolved
(from [5ff6de0982c165bb9038258d867398c73c142084]) Added assert_attribute_type to clean up GeneratedAttributeTest [#2377 state:resolved]
Signed-off-by: José Valim jose.valim@gmail.com
http://github.com/rails/rails/commit/5ff6de0982c165bb9038258d867398... -
Repository
(from [ec017e158a0f006ac30bee94f81411a4d74a5227]) Added assert_attribute_type to clean up GeneratedAttributeTest [#2377 state:resolved]
Signed-off-by: José Valim jose.valim@gmail.com
http://github.com/rails/rails/commit/ec017e158a0f006ac30bee94f81411... -
Rizwan Reza
- Tag changed from 2.3.2, bugmash-review, datetime, scaffold, time, time_select to 2.3.2, datetime, scaffold, time, time_select
