class CreateMOdrRemises < ActiveRecord::Migration[6.0]
  def change
    create_table :m_odr_remises do |t|
      t.text :notes
      t.references :m_odr, foreign_key: true
      t.datetime :download_at
      t.datetime :confirmed_at
      t.string :state, :default => "Généré"
      t.boolean :confirmed, :default => false
      t.integer :admin_id
      
      t.integer :cc_nbr_virements
      t.integer :ac_nbr_virements
      
      t.string :cc_iban_from
      t.string :ac_iban_from
      t.string :cc_bic_from
      t.string :ac_bic_from
      
      t.string :cc_bank_name
      t.string :ac_bank_name
      
      t.string :cc_bank_subject
      t.string :ac_bank_subject

      t.timestamps
    end
  end
end
