[Rails] Restful create URL

2010-03-22 Thread sgallo1
I'm creating and api. I create a scaffold script/generate scaffold user I have users controller, but how do I call the create method via a URL ie...localhost:3000/users/create.xml?params new doesn't work as it returns the empty user object in XML as it should, but when I call create localhost:3

[Rails] Active Record - Select by multiple days of week

2010-02-23 Thread sgallo1
Wondering what would be the best way to implement this. I need to store that an item occurs on a specific day of the week or everyday. Say in the model we have a title and a day of week. I was thinking doing a 0-7 in my model for the item representing the day of the week with zero being everyday.