Answers for "generate models in rails"

2

rails g model

$ rails generate model Article title:string text:text
Posted by: Guest on October-02-2020
0

rails generate model

rails generate model Article title:string body:text


[Output]

invoke  active_record
create    db/migrate/<timestamp>_create_articles.rb
create    app/models/article.rb
invoke    test_unit
create      test/models/article_test.rb
create      test/fixtures/articles.yml
Posted by: Guest on August-30-2021

Browse Popular Code Answers by Language