<%= render 'spree/admin/shared/configuration_menu' %> <% content_for :page_title do %> <%= Spree.t(:payment_methods) %> <% end %> <% content_for :page_actions do %> <% if can?(:create, Spree::PaymentMethod) %>
  • <%= button_link_to Spree.t(:new_payment_method), new_object_url, :icon => 'plus', :id => 'admin_new_payment_methods_link' %>
  • <% end %> <% end %> <% if @payment_methods.any? %> <% @payment_methods.each do |method|%> <% end %>
    <%= Spree.t(:name) %> <%= Spree.t(:provider) %> <%= Spree.t(:display) %> <%= Spree.t(:active) %>
    <%= method.name %> <%= method.type %> <%= method.display_on.blank? ? Spree.t(:both) : Spree.t(method.display_on) %> <%= method.active ? Spree.t(:say_yes) : Spree.t(:say_no) %> <% if can?(:update, method.becomes(Spree::PaymentMethod)) %> <%= link_to_edit method.becomes(Spree::PaymentMethod), :no_text => true %> <% end %> <% if can?(:destroy, method.becomes(Spree::PaymentMethod)) %> <%= link_to_delete method.becomes(Spree::PaymentMethod), :no_text => true %> <% end %>
    <% else %>
    <%= Spree.t(:no_resource_found, resource: I18n.t(:other, scope: 'activerecord.models.spree/payment_method')) %> <% if can?(:create, Spree::PaymentMethod) %> <%= link_to Spree.t(:add_one), spree.new_admin_payment_method_path %>! <% end %>
    <% end %>