2020-04-19 09:10:31 -07:00
|
|
|
class CreateThemes < ActiveRecord::Migration[4.2]
|
2015-08-25 01:26:36 -07:00
|
|
|
def change
|
|
|
|
create_table :themes do |t|
|
|
|
|
t.integer :user_id, null: false
|
|
|
|
|
|
|
|
t.integer :primary_color, limit: 4, default: 0x5E35B1
|
|
|
|
t.integer :primary_text, limit: 4, default: 0xFFFFFF
|
|
|
|
|
|
|
|
t.integer :danger_color, limit: 4, default: 0xFF0039
|
|
|
|
t.integer :danger_text, limit: 4, default: 0xFFFFFF
|
|
|
|
|
|
|
|
t.integer :success_color, limit: 4, default: 0x3FB618
|
|
|
|
t.integer :success_text, limit: 4, default: 0xFFFFFF
|
|
|
|
|
|
|
|
t.integer :warning_color, limit: 4, default: 0xFF7518
|
|
|
|
t.integer :warning_text, limit: 4, default: 0xFFFFFF
|
|
|
|
|
|
|
|
t.integer :info_color, limit: 4, default: 0x9954BB
|
|
|
|
t.integer :info_text, limit: 4, default: 0xFFFFFF
|
|
|
|
|
|
|
|
t.integer :default_color, limit: 4, default: 0x222222
|
|
|
|
t.integer :default_text, limit: 4, default: 0xEEEEEE
|
|
|
|
|
|
|
|
t.integer :panel_color, limit: 4, default: 0xF9F9F9
|
|
|
|
t.integer :panel_text, limit: 4, default: 0x151515
|
|
|
|
|
|
|
|
t.integer :link_color, limit: 4, default: 0x5E35B1
|
|
|
|
|
|
|
|
t.integer :background_color, limit: 4, default: 0xFFFFFF
|
|
|
|
t.integer :background_text, limit: 4, default: 0x222222
|
|
|
|
t.integer :background_muted, limit: 4, default: 0xBBBBBB
|
|
|
|
|
2020-05-01 15:43:46 -07:00
|
|
|
t.string :css_file_name
|
|
|
|
t.string :css_content_type
|
|
|
|
t.bigint :css_file_size
|
|
|
|
t.datetime :css_updated_at
|
2015-08-25 01:26:36 -07:00
|
|
|
|
|
|
|
t.timestamps null: false
|
|
|
|
end
|
|
|
|
|
|
|
|
add_index :themes, [:user_id, :created_at]
|
|
|
|
end
|
|
|
|
end
|