blob: 12677fa1f0f5035ef29ed1471227e0b3ebea6fb1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
class DropImports < ActiveRecord::Migration
def up
if table_exists? :imports
execute "DROP TABLE imports" # fix Foreigner bug < 1.5.0
# drop_table :imports
end
end
def down
unless table_exists? :imports
create_table :imports do |t|
t.belongs_to :referential
t.string :status
t.string :type
t.string :options
t.string :file_type
t.timestamps
end
add_index :imports, :referential_id
end
end
end
|