update migration
This commit is contained in:
parent
07014ae159
commit
7a5e27685c
@ -1,11 +1,12 @@
|
||||
class CreateSorecopTaxes < ActiveRecord::Migration[6.0]
|
||||
def change
|
||||
create_table :sorecop_taxes do |t|
|
||||
t.decimal :critere_min, :precision => 10, :scale => 2
|
||||
t.decimal :critere_max, :precision => 10, :scale => 2
|
||||
t.decimal :critere_min, precision: 10, scale: 2
|
||||
t.decimal :critere_max, precision: 10, scale: 2
|
||||
t.string :title
|
||||
t.boolean :fixed_price, default: true
|
||||
t.references :sorecop_cats, foreign_key: true
|
||||
t.decimal :price, precision: 10, scale: 2
|
||||
t.references :sorecop_cat, foreign_key: true
|
||||
|
||||
t.timestamps
|
||||
end
|
||||
|
@ -0,0 +1,5 @@
|
||||
class AddSorecopCatIdToPProductRefs < ActiveRecord::Migration[6.0]
|
||||
def change
|
||||
add_column :p_product_refs, :sorecop_cat_id, :integer
|
||||
end
|
||||
end
|
10
db/schema.rb
10
db/schema.rb
@ -10,7 +10,7 @@
|
||||
#
|
||||
# It's strongly recommended that you check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema.define(version: 2021_09_23_165046) do
|
||||
ActiveRecord::Schema.define(version: 2021_09_23_170130) do
|
||||
|
||||
create_table "accounting_zones", options: "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4", force: :cascade do |t|
|
||||
t.string "name"
|
||||
@ -1801,6 +1801,7 @@ ActiveRecord::Schema.define(version: 2021_09_23_165046) do
|
||||
t.decimal "ct_deee", precision: 10, scale: 2
|
||||
t.string "ean"
|
||||
t.string "sorecop_comment"
|
||||
t.integer "sorecop_cat_id"
|
||||
end
|
||||
|
||||
create_table "p_product_specs", options: "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4", force: :cascade do |t|
|
||||
@ -2765,10 +2766,11 @@ ActiveRecord::Schema.define(version: 2021_09_23_165046) do
|
||||
t.decimal "critere_max", precision: 10, scale: 2
|
||||
t.string "title"
|
||||
t.boolean "fixed_price", default: true
|
||||
t.bigint "sorecop_cats_id"
|
||||
t.decimal "price", precision: 10, scale: 2
|
||||
t.bigint "sorecop_cat_id"
|
||||
t.datetime "created_at", precision: 6, null: false
|
||||
t.datetime "updated_at", precision: 6, null: false
|
||||
t.index ["sorecop_cats_id"], name: "index_sorecop_taxes_on_sorecop_cats_id"
|
||||
t.index ["sorecop_cat_id"], name: "index_sorecop_taxes_on_sorecop_cat_id"
|
||||
end
|
||||
|
||||
create_table "specific_preferences", options: "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4", force: :cascade do |t|
|
||||
@ -3193,7 +3195,7 @@ ActiveRecord::Schema.define(version: 2021_09_23_165046) do
|
||||
add_foreign_key "partition_lines", "partitions"
|
||||
add_foreign_key "partitions", "admins"
|
||||
add_foreign_key "s_modules", "s_modules_states"
|
||||
add_foreign_key "sorecop_taxes", "sorecop_cats", column: "sorecop_cats_id"
|
||||
add_foreign_key "sorecop_taxes", "sorecop_cats"
|
||||
add_foreign_key "stat_lines", "p_commercials"
|
||||
add_foreign_key "stat_lines", "p_customers"
|
||||
add_foreign_key "stat_lines", "p_product_refs"
|
||||
|
Reference in New Issue
Block a user