Added Sources model + controller
commands: rails generate redmine_plugin_model body_tracking source project:references name:string description:text rails generate redmine_plugin_controller body_tracking sources index create destroy
This commit is contained in:
10
db/migrate/002_create_sources.rb
Normal file
10
db/migrate/002_create_sources.rb
Normal file
@@ -0,0 +1,10 @@
|
||||
class CreateSources < ActiveRecord::Migration
|
||||
def change
|
||||
create_table :sources do |t|
|
||||
t.references :project, index: true, foreign_key: true
|
||||
t.string :name
|
||||
t.text :description
|
||||
end
|
||||
add_index :sources, :project_id
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user