Sha256: 71878975949e0c751aacd05c040ec6a36fe9ffac3748abaa3ab9d5b962a7e2ab
Contents?: true
Size: 960 Bytes
Versions: 120
Compression:
Stored size: 960 Bytes
Contents
class CreateComeeCoreProducts < ActiveRecord::Migration[7.0] def change create_table :comee_core_products do |t| t.string :code, null: false t.string :name, null: false t.string :description t.boolean :leaf, null: false, default: true t.string :ancestry t.jsonb :preferred_units, null: false, default: [] t.float :weight t.references :weight_unit, null: true, index: {name: "wu_on_ccp_indx"}, foreign_key: {to_table: :comee_core_units} t.string :dimensions t.string :hs_code t.string :hs_description t.references :source, null: true, index: {name: "source_on_ccp_indx"}, foreign_key: {to_table: :comee_core_fulfillment_centers} t.timestamps end add_index :comee_core_products, :code, unique: true add_index :comee_core_products, :ancestry end end
Version data entries
120 entries across 120 versions & 1 rubygems