Skip to content

armgit / spree

Public Imported from GitHub
0

Open Source Platform for DTC, B2B Commerce, Marketplaces & Omnichannel. REST APIs, TypeScript SDKs, and production-ready Next.js storefront. Self-host it. Own your data. No vendor lock-in. Zero platform fees.

Add the catalog description in its own migration

Damian Legawiec6957579e1066
diff --git a/spree/core/db/migrate/20260825000001_create_spree_catalogs.rb b/spree/core/db/migrate/20260825000001_create_spree_catalogs.rb
index 5e7df9761b..1ad74e869e 100644
--- a/spree/core/db/migrate/20260825000001_create_spree_catalogs.rb
+++ b/spree/core/db/migrate/20260825000001_create_spree_catalogs.rb
@@ -3,9 +3,6 @@ class CreateSpreeCatalogs < ActiveRecord::Migration[8.1]
create_table :spree_catalogs do |t|
t.references :store, null: false
t.string :name, null: false
- # What the agreement is, in the operator's own words — never shown to
- # a shopper, like a price list's.
- t.text :description
t.boolean :active, null: false, default: true
t.integer :position
if t.respond_to?(:jsonb)
diff --git a/spree/core/db/migrate/20260831000001_add_description_to_spree_catalogs.rb b/spree/core/db/migrate/20260831000001_add_description_to_spree_catalogs.rb
new file mode 100644
index 0000000000..e78fbf6832
--- /dev/null
+++ b/spree/core/db/migrate/20260831000001_add_description_to_spree_catalogs.rb
@@ -0,0 +1,7 @@
+class AddDescriptionToSpreeCatalogs < ActiveRecord::Migration[8.1]
+ def change
+ # What the agreement is, in the operator's own words — never shown to a
+ # shopper, like a price list's.
+ add_column :spree_catalogs, :description, :text
+ end
+end