Sha256: c0182eca68d2ff37ee0d33f4b8e22f562aafa9e6ea4c609a2aa2a3c2e9e7d979

Contents?: true

Size: 732 Bytes

Versions: 104

Compression:

Stored size: 732 Bytes

Contents

Description:
    Invokes the active_record:model generator, but the generated
    model file contains the fields block, (and the migration option
    is false by default).

Examples:
    $ rails generate declare_schema:model account

        creates an Account model, test and fixture:
            Model:      app/models/account.rb
            Test:       test/unit/account_test.rb
            Fixtures:   test/fixtures/accounts.yml

    $ rails generate declare_schema:model post title:string body:text published:boolean

        creates a Post model with a string title, text body, and published flag.

After the model is created, and the fields are specified, use declare_schema:migration
to create the migrations incrementally.

Version data entries

104 entries across 104 versions & 1 rubygems

Version Path
declare_schema-0.7.1 lib/generators/declare_schema/model/USAGE
declare_schema-0.7.0 lib/generators/declare_schema/model/USAGE
declare_schema-0.6.4 lib/generators/declare_schema/model/USAGE
declare_schema-0.6.3 lib/generators/declare_schema/model/USAGE
declare_schema-0.6.2 lib/generators/declare_schema/model/USAGE
declare_schema-0.6.1 lib/generators/declare_schema/model/USAGE
declare_schema-0.6.0 lib/generators/declare_schema/model/USAGE
declare_schema-0.5.0 lib/generators/declare_schema/model/USAGE
declare_schema-0.5.0.pre.3 lib/generators/declare_schema/model/USAGE
declare_schema-0.5.0.pre.2 lib/generators/declare_schema/model/USAGE
declare_schema-0.5.0.pre.1 lib/generators/declare_schema/model/USAGE
declare_schema-0.4.2 lib/generators/declare_schema/model/USAGE
declare_schema-0.4.1 lib/generators/declare_schema/model/USAGE
declare_schema-0.4.0 lib/generators/declare_schema/model/USAGE
declare_schema-0.3.1 lib/generators/declare_schema/model/USAGE
declare_schema-0.3.0 lib/generators/declare_schema/model/USAGE
declare_schema-0.3.0.pre.2 lib/generators/declare_schema/model/USAGE
declare_schema-0.3.0.pre.1 lib/generators/declare_schema/model/USAGE
declare_schema-0.2.0 lib/generators/declare_schema/model/USAGE
declare_schema-0.2.0.pre.1 lib/generators/declare_schema/model/USAGE