<%= f.label :type %>
<%= collection_select(:payment_method, :type, @providers, :to_s, :name, {}, {:id => 'gtwy-type', :class => 'select2 fullwidth js-gateway-type'}) %>
<%= f.label :preference_source %>
<%= f.select(:preference_source, [[Spree.t(:preference_source_none), nil]] + @object.class.available_preference_sources, {}, class: 'select2 fullwidth js-preference-source') %>
<% if @object.preference_source.present? %>
<%= Spree.t :preference_source_using, name: @object.preference_source %>
<% elsif !@object.new_record? %>
<%= preference_fields(@object, f) %>
<% end %>
<%= Spree.t(:provider_settings_warning) %>
<%= f.label :display_on %>
<%= select(:payment_method, :display_on, Spree::PaymentMethod::DISPLAY.collect { |display| [Spree.t(display), display == :both ? nil : display.to_s] }, {}, {:class => 'select2 fullwidth'}) %>
<%= f.label :auto_capture %>
<%= select(:payment_method, :auto_capture, [["#{Spree.t(:use_app_default)} (#{Spree::Config[:auto_capture]})", ''], [Spree.t(:say_yes), true], [Spree.t(:say_no), false]], {}, {:class => 'select2 fullwidth'}) %>
<%= label_tag nil, Spree::PaymentMethod.human_attribute_name(:active) %>
-
<%= radio_button :payment_method, :active, true %>
<%= label_tag :payment_method_active_true, Spree.t(:say_yes) %>
-
<%= radio_button :payment_method, :active, false %>
<%= label_tag :payment_method_active_false, Spree.t(:say_no) %>
<%= f.label :name %>
<%= f.text_field :name, :class => 'fullwidth' %>
<%= f.label :description %>
<%= f.text_area :description, {:cols => 60, :rows => 6, :class => 'fullwidth'} %>