Sha256: 8b8e3a776881b262757c172734cbfb1f21e58c5b493a7bd32dddf818e9106d51

Contents?: true

Size: 471 Bytes

Versions: 34

Compression:

Stored size: 471 Bytes

Contents

class CreateSpreeStockItems < ActiveRecord::Migration
  def change
    create_table :spree_stock_items do |t|
      t.belongs_to :stock_location
      t.belongs_to :variant
      t.integer :count_on_hand, null: false, default: 0
      t.integer :lock_version

      t.timestamps null: false
    end
    add_index :spree_stock_items, :stock_location_id
    add_index :spree_stock_items, [:stock_location_id, :variant_id], :name => 'stock_item_by_loc_and_var_id'
  end
end

Version data entries

34 entries across 34 versions & 1 rubygems

Version Path
spree_core-3.1.0.rc1 db/migrate/20130211190146_create_spree_stock_items.rb
spree_core-3.0.8 db/migrate/20130211190146_create_spree_stock_items.rb
spree_core-3.0.7 db/migrate/20130211190146_create_spree_stock_items.rb
spree_core-3.0.6.1 db/migrate/20130211190146_create_spree_stock_items.rb
spree_core-3.0.6 db/migrate/20130211190146_create_spree_stock_items.rb
spree_core-3.0.5 db/migrate/20130211190146_create_spree_stock_items.rb
spree_core-3.0.4 db/migrate/20130211190146_create_spree_stock_items.rb
spree_core-3.0.3 db/migrate/20130211190146_create_spree_stock_items.rb
spree_core-3.0.2 db/migrate/20130211190146_create_spree_stock_items.rb
spree_core-3.0.1 db/migrate/20130211190146_create_spree_stock_items.rb
spree_core-3.0.0 db/migrate/20130211190146_create_spree_stock_items.rb
spree_core-3.0.0.rc4 db/migrate/20130211190146_create_spree_stock_items.rb
spree_core-3.0.0.rc3 db/migrate/20130211190146_create_spree_stock_items.rb
spree_core-3.0.0.rc1 db/migrate/20130211190146_create_spree_stock_items.rb