Sha256: cba6cf4556637bc93afbba650199af39c972a1e28ed755a140625674502d04ac
Contents?: true
Size: 469 Bytes
Versions: 97
Compression:
Stored size: 469 Bytes
Contents
class CreateWorkHasSubjects < ActiveRecord::Migration def self.up create_table :work_has_subjects do |t| t.references :subject, :polymorphic => true #t.references :subjectable, :polymorphic => true t.integer :work_id #, :null => false t.integer :position t.timestamps end add_index :work_has_subjects, :subject_id add_index :work_has_subjects, :work_id end def self.down drop_table :work_has_subjects end end
Version data entries
97 entries across 97 versions & 7 rubygems