Wed 28 May 2008
Rails 2 new ways
Posted by kosmas under ruby on rails
Problem
To get used to the new ways of working with Rails 2.
Solution
Here are some of the new ways of doing things in Rails 2.
- Create a scaffold and migration on one step:
./script/generate scaffold product fied1_name:string field2_name:string field3_name:float
Make sure that you don’t have any previous migration(ie manually created) for the same model, as the generator will stop and won’t overwrite the previous migration.
No Responses to “ Rails 2 new ways ”
Comments:
Leave a Reply
You must be logged in to post a comment.