Sha256: 394636319ee070b013bf61920ac7594a3771f9a3e8436072ef50ba0596349ffb
Contents?: true
Size: 866 Bytes
Versions: 187
Compression:
Stored size: 866 Bytes
Contents
Description: Stubs out a new resource including an empty model and controller suitable for a restful, resource-oriented application. Pass the singular model name, either CamelCased or under_scored, as the first argument, and an optional list of attribute pairs. Attribute pairs are field:type arguments specifying the model's attributes. Timestamps are added by default, so you don't have to specify them by hand as 'created_at:datetime updated_at:datetime'. You don't have to think up every attribute up front, but it helps to sketch out a few so you can start working with the model immediately. Examples: `rails generate lalala:resource post` # no attributes `rails generate lalala:resource post title:string body:text published:boolean` `rails generate lalala:resource purchase order_id:integer amount:decimal`
Version data entries
187 entries across 187 versions & 1 rubygems