<%= render 'spree/admin/shared/shipping_tabs' %> <% admin_breadcrumb(Spree.t(:settings)) %> <% admin_breadcrumb(Spree.t('admin.tab.shipping')) %> <% admin_breadcrumb(plural_resource_name(Spree::ShippingMethod)) %> <% content_for :page_actions do %> <% if can?(:create, Spree::ShippingMethod) %>
  • <%= button_link_to Spree.t(:new_shipping_method), new_object_url, id: 'admin_new_shipping_method_link' %>
  • <% end %> <% end %> <% if @shipping_methods.any? %> <% @shipping_methods.includes(:zones, :calculator).each do |shipping_method|%> <% end %>
    <%= Spree::ShippingMethod.human_attribute_name(:name) %> <%= Spree::Zone.model_name.human %> <%= Spree::Calculator.model_name.human %> <%= Spree::ShippingMethod.human_attribute_name(:available_to_users) %>
    <%= shipping_method.admin_name + ' / ' if shipping_method.admin_name.present? %><%= shipping_method.name %> <%= shipping_method.zones.collect(&:name).join(", ") if shipping_method.zones %> <%= shipping_method.calculator.description %> <%= shipping_method.available_to_users? ? Spree.t(:say_yes) : Spree.t(:say_no) %> <% if can?(:update, shipping_method) %> <%= link_to_edit shipping_method, no_text: true %> <% end %> <% if can?(:destroy, shipping_method) %> <%= link_to_delete shipping_method, no_text: true %> <% end %>
    <% else %>
    <%= render 'spree/admin/shared/no_objects_found', resource: Spree::ShippingMethod, new_resource_url: new_object_url %>
    <% end %>