class CreateTrPayments < ActiveRecord::Migration
  def change
    create_table :tr_payments do |t|
      t.references :tr_payment_type
      t.decimal :amount
      t.string :check_number
      t.string :check_bank
      t.string :payplug_payment_id
      t.string :payplug_card_id
      t.string :payplug_card_expiry_month
      t.string :payplug_card_expiry_year
      t.string :payplug_card_last_number
      t.datetime :paid_at
      t.datetime :tr_canceled_at
      t.boolean :tr_canceled, :default => false
      t.references :tr_payment_bank_account
      t.references :donator_transaction
      

      t.timestamps null: false
    end
  end
end
