Created
April 23, 2012 14:07
-
-
Save ahmdrefat/2471102 to your computer and use it in GitHub Desktop.
Generating new models
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# run first | |
rails g model course name:string description:text university:string lectures_counter:integer | |
# and then | |
rails g model lecture name:string description:text youtube_url:string course_id:integer | |
# and then | |
rails g model enrollment course_id:integer person_id:integer | |
# and then run the database migration to create the tables | |
rake db:migrate |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment