From 3a38eeb248a2afe29663cda3b009eb0c8b2e5493 Mon Sep 17 00:00:00 2001 From: Matt-Yorkley <9029026+Matt-Yorkley@users.noreply.github.com> Date: Mon, 7 Aug 2023 12:43:04 +0100 Subject: [PATCH] Remove products taxon null constraint --- db/migrate/20230807114014_remove_taxon_constraint.rb | 5 +++++ db/schema.rb | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 db/migrate/20230807114014_remove_taxon_constraint.rb diff --git a/db/migrate/20230807114014_remove_taxon_constraint.rb b/db/migrate/20230807114014_remove_taxon_constraint.rb new file mode 100644 index 0000000000..a2dabbbb35 --- /dev/null +++ b/db/migrate/20230807114014_remove_taxon_constraint.rb @@ -0,0 +1,5 @@ +class RemoveTaxonConstraint < ActiveRecord::Migration[7.0] + def change + change_column_null :spree_products, :primary_taxon_id, true + end +end diff --git a/db/schema.rb b/db/schema.rb index 092a5c9814..51491dce7f 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -698,7 +698,7 @@ ActiveRecord::Schema[7.0].define(version: 2024_02_13_044159) do t.float "variant_unit_scale" t.string "variant_unit_name", limit: 255 t.text "notes" - t.integer "primary_taxon_id", null: false + t.integer "primary_taxon_id" t.boolean "inherits_properties", default: true, null: false t.string "sku", limit: 255, default: "", null: false t.index ["deleted_at"], name: "index_products_on_deleted_at"