collab/db/migrate/20100305010025_projects_users.rb

16 lines
332 B
Ruby
Raw Normal View History

2010-03-05 06:48:00 +00:00
class ProjectsUsers < ActiveRecord::Migration
def self.up
create_table :projects_users, :id => false do |t|
t.integer :project_id
t.integer :user_id
t.foreign_key :projects
t.foreign_key :users
t.index :project_id, :user_id
end
end
def self.down
drop_table :projects_users
end
end