Remove project_id from keys table

This commit is contained in:
Dmitriy Zaporozhets 2013-05-06 15:10:05 +03:00
parent b7f1cf9f49
commit 8e4625af61
2 changed files with 10 additions and 3 deletions

View file

@ -0,0 +1,9 @@
class RemoveProjectIdFromKey < ActiveRecord::Migration
def up
remove_column :keys, :project_id
end
def down
add_column :keys, :project_id, :integer
end
end

View file

@ -11,7 +11,7 @@
#
# It's strongly recommended to check this file into your version control system.
ActiveRecord::Schema.define(:version => 20130506090604) do
ActiveRecord::Schema.define(:version => 20130506095501) do
create_table "deploy_keys_projects", :force => true do |t|
t.integer "deploy_key_id", :null => false
@ -76,12 +76,10 @@ ActiveRecord::Schema.define(:version => 20130506090604) do
t.text "key"
t.string "title"
t.string "identifier"
t.integer "project_id"
t.string "type"
end
add_index "keys", ["identifier"], :name => "index_keys_on_identifier"
add_index "keys", ["project_id"], :name => "index_keys_on_project_id"
add_index "keys", ["user_id"], :name => "index_keys_on_user_id"
create_table "merge_requests", :force => true do |t|