Files
Dena/db/migrate/20180315132521_migrate_all_currency_models_to_single.rb
2026-08-13 19:50:53 +03:30

10 lines
329 B
Ruby

# encoding: UTF-8
# frozen_string_literal: true
class MigrateAllCurrencyModelsToSingle < ActiveRecord::Migration[4.2]
def change
execute %[ UPDATE deposits SET type = 'Deposits::Coin' WHERE type <> 'Deposits::Bank' ]
execute %[ UPDATE withdraws SET type = 'Withdraws::Coin' WHERE type <> 'Withdraws::Bank' ]
end
end