Sha256: 73dd5359bf76f6407c3589ea8872786fe88b99e9b6fb81f2cc3a2e20439c525b

Contents?: true

Size: 1.64 KB

Versions: 31

Compression:

Stored size: 1.64 KB

Contents

<% admin_breadcrumb(link_to plural_resource_name(Spree::Product), spree.admin_products_path) %>
<% admin_breadcrumb(link_to plural_resource_name(Spree::OptionType), spree.admin_option_types_path) %>
<% admin_breadcrumb(@option_type.name) %>

<% content_for :page_actions do %>
  <li>
    <span id="new_add_option_value" data-hook>
      <%= button_tag t('spree.add_option_value'), type: 'button',
            data: { target: 'tbody#option_values' },
            class: 'btn btn-primary spree_add_fields' %>
    </span>
  </li>
<% end %>

<%= render partial: 'spree/shared/error_messages', locals: { target: @option_type } %>

<%= form_for [:admin, @option_type] do |f| %>

  <fieldset class="no-border-bottom">
    <legend><%= Spree::OptionType.model_name.human %></legend>
    <%= render partial: 'form', locals: { f: f } %>
  </fieldset>

  <fieldset>
    <legend><%= plural_resource_name(Spree::OptionValue) %></legend>
    <table class="index sortable" data-hook data-sortable-link="<%= update_values_positions_admin_option_types_url %>">
      <thead data-hook="option_header">
        <tr>
          <th></th>
          <th><%= Spree::OptionValue.human_attribute_name(:name) %></th>
          <th><%= Spree::OptionValue.human_attribute_name(:presentation) %></th>
          <th class="actions"></th>
        </tr>
      </thead>
      <tbody id="option_values">
        <%= f.fields_for :option_values, @option_values do |option_value_form| %>
          <%= render partial: 'option_value_fields', locals: { f: option_value_form } %>
        <% end %>
      </tbody>
    </table>
    <%= render partial: 'spree/admin/shared/edit_resource_links' %>
  </fieldset>
<% end %>

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
solidus_backend-4.4.2 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.4.1 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.4.0 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.3.4 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.2.4 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.1.5 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.3.3 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.3.2 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.1.4 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.3.1 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.3.0 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.2.3 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.1.3 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.0.4 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-3.4.6 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.0.3 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.1.2 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.2.2 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-3.4.5 app/views/spree/admin/option_types/edit.html.erb
solidus_backend-4.2.1 app/views/spree/admin/option_types/edit.html.erb