<%= f.fields_for :return_items, return_items do |item_fields| %> <% return_item = item_fields.object %> <% end %>
<%= Spree::Product.model_name.human %> <%= Spree::Variant.human_attribute_name(:sku) %> <%= Spree::ReturnItem.human_attribute_name(:amount) %> <%= Spree::ReturnItem.human_attribute_name(:inventory_unit_state) %> <%= Spree::ReturnItem.human_attribute_name(:exchange_variant) %> <%= Spree::ReturnItem.human_attribute_name(:resellable) %> <%= Spree::ReturnItem.human_attribute_name(:reception_status) %> <%= Spree::ReturnItem.human_attribute_name(:return_reason) %>
<%= item_fields.hidden_field :inventory_unit_id %> <%= item_fields.hidden_field :return_authorization_id %> <%= item_fields.hidden_field :amount %>
<%= item_fields.check_box :returned, {checked: false, class: 'selectable add-item', "data-price" => return_item.amount}, '1', '0' %>
<%= return_item.inventory_unit.variant.name %>
<%= return_item.inventory_unit.variant.options_text %>
<%= return_item.inventory_unit.variant.sku %> <%= return_item.display_amount %> <%= t( return_item.inventory_unit.state, scope: 'spree.inventory_states' ) %> <%= return_item.exchange_variant.try(:exchange_name) %> <%= item_fields.check_box :resellable, { checked: return_item.resellable } %> <%= item_fields.select :reception_status_event, return_item.potential_reception_transitions, {include_blank: true}, {class: 'add-item custom-select fullwidth'} %> <%= item_fields.select :return_reason_id, @reasons.collect{|r|[r.name, r.id]}, {include_blank: true}, {class: 'custom-select fullwidth'} %>