Project

General

Profile

RE: Contacts plugin ยป 009_create_taggings.rb

Kirill Bezrukov (RedmineUP), 2011-02-21 13:37

 
class CreateTaggings < ActiveRecord::Migration
def self.up
create_table :taggings, :id => false do |t|
t.column :tag_id, :integer
t.column :container_id, :integer
t.column :container_type, :string
end

add_index :taggings, [:container_id, :container_type, :container_id], :name => "taggings_ids", :unique => true

end


def self.down
drop_table :taggings
end
end
    (1-1/1)