Sha256: 14bceb2a10b2083a9c2d80c2001bee7e40a8cf71c5ddae3ee2faba50220cd1ad

Contents?: true

Size: 573 Bytes

Versions: 14

Compression:

Stored size: 573 Bytes

Contents

class CreateComeeCoreExternalProducts < ActiveRecord::Migration[7.0]
  def change
    create_table :comee_core_product_lookups do |t|
      t.string :code, null: false
      t.references :itemable, polymorphic: true, null: false
      t.references :product,
        null: false,
        index: {name: "product_on_ccep_indx"},
        foreign_key: {to_table: :comee_core_products}

      t.timestamps
    end
    add_index :comee_core_product_lookups,
      [:itemable_id, :itemable_type, :product_id],
      name: "itemable_product_indx_uniq",
      unique: true
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
comee_core-0.1.23 db/migrate/20230914041307_create_comee_core_external_products.rb
comee_core-0.1.22 db/migrate/20230914041307_create_comee_core_external_products.rb
comee_core-0.1.21 db/migrate/20230914041307_create_comee_core_external_products.rb
comee_core-0.1.20 db/migrate/20230914041307_create_comee_core_external_products.rb
comee_core-0.1.19 db/migrate/20230914041307_create_comee_core_external_products.rb
comee_core-0.1.18 db/migrate/20230914041307_create_comee_core_external_products.rb
comee_core-0.1.17 db/migrate/20230914041307_create_comee_core_external_products.rb
comee_core-0.1.16 db/migrate/20230914041307_create_comee_core_external_products.rb
comee_core-0.1.15 db/migrate/20230914041307_create_comee_core_external_products.rb
comee_core-0.1.14 db/migrate/20230914041307_create_comee_core_external_products.rb
comee_core-0.1.13 db/migrate/20230914041307_create_comee_core_external_products.rb
comee_core-0.1.12 db/migrate/20230914041307_create_comee_core_external_products.rb
comee_core-0.1.11 db/migrate/20230914041307_create_comee_core_external_products.rb
comee_core-0.1.10 db/migrate/20230914041307_create_comee_core_external_products.rb