Sha256: ceccd088bfbf1c095cb0ddc007506b373435f880627198fdae6b8d8d341c0d76

Contents?: true

Size: 966 Bytes

Versions: 6

Compression:

Stored size: 966 Bytes

Contents

# This migration comes from spree (originally 20150118210639)
class CreateSpreeStoreCredits < ActiveRecord::Migration[4.2]
  def change
    create_table :spree_store_credits do |t|
      t.references :user
      t.references :category
      t.references :created_by
      t.decimal :amount, precision: 8, scale: 2, default: 0.0, null: false
      t.decimal :amount_used, precision: 8, scale: 2, default: 0.0, null: false
      t.text :memo
      t.datetime :deleted_at
      t.string :currency
      t.decimal :amount_authorized, precision: 8, scale: 2, default: 0.0, null: false
      t.integer :originator_id
      t.string :originator_type
      t.integer :type_id
      t.timestamps null: false
    end

    add_index :spree_store_credits, :deleted_at
    add_index :spree_store_credits, :user_id
    add_index :spree_store_credits, :type_id
    add_index :spree_store_credits, [:originator_id, :originator_type], name: :spree_store_credits_originator
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
spree_purchase_order-3.6.0 spec/dummy/db/migrate/20180516182034_create_spree_store_credits.spree.rb
spree_purchase_order-3.5.0 spec/dummy/db/migrate/20180516182034_create_spree_store_credits.spree.rb
spree_purchase_order-3.5.0.rc1 spec/dummy/db/migrate/20180516182034_create_spree_store_credits.spree.rb
spree_purchase_order-3.4.0 spec/dummy/db/migrate/20180516182034_create_spree_store_credits.spree.rb
spree_purchase_order-3.3.0 spec/dummy/db/migrate/20180516182034_create_spree_store_credits.spree.rb
spree_purchase_order-3.2.0 spec/dummy/db/migrate/20180516182034_create_spree_store_credits.spree.rb