class ChangeNameOfPaymentMethodTypes < ActiveRecord::Migration
  def up
    name_maps.each do |old, new|
      Spree::PaymentMethod.where(type: old).update_all(type: new)
    end
  end

  def down
    name_maps.each do |old, new|
      Spree::PaymentMethod.where(type: new).update_all(type: old)
    end
  end

  private
  def name_maps
    {
     'Spree::BillingIntegration::SisowBilling::Ideal' => 'Spree::PaymentMethod::SisowBilling::Ideal',
     'Spree::BillingIntegration::SisowBilling::Bancontact' => 'Spree::PaymentMethod::SisowBilling::Bancontact',
     'Spree::BillingIntegration::SisowBilling::Sofort' => 'Spree::PaymentMethod::SisowBilling::Sofort'
    }
  end
end

Add migration to change the names of already made payment methods.
Add migration to change the names of already made payment methods.
