<%= render partial: 'spree/admin/shared/order_tabs', locals: {current: 'Payments'} %> <% content_for :page_title do %> / <%= link_to "#{Spree.t(:payment)} #{@refund.payment.id}", admin_order_payment_path(@refund.payment.order, @refund.payment) %> / <%= Spree.t(:new_refund) %> <% end %> <%= form_for [:admin, @refund.payment.order, @refund.payment, @refund] do |f| %>
<%= f.label :payment_amount, Spree.t(:payment_amount) %>
<%= @refund.payment.amount %>
<%= f.label :credit_allowed, Spree.t(:credit_allowed) %>
<%= @refund.payment.credit_allowed %>
<%= f.label :amount, Spree.t(:amount) %> <%= f.text_field :amount, class: 'form-control' %>
<%= f.label :refund_reason_id, Spree.t(:reason) %> <%= f.collection_select(:refund_reason_id, refund_reasons, :id, :name, {include_blank: true}, {class: 'select2'}) %>
<%= button Spree.t(:refund), 'save' %> <%= Spree.t(:or) %> <%= button_link_to Spree.t('actions.cancel'), admin_order_payments_url(@refund.payment.order), :icon => "delete" %>
<% end %>