Sha256: 82405a7db3846c6ee5c90a05ee4218156588c98d2e421b783227c6bdaebd0bd2

Contents?: true

Size: 1.59 KB

Versions: 4

Compression:

Stored size: 1.59 KB

Contents

- unless @payments.empty?
  .table
    %table.data
      %thead
        %tr
          %th= t('tienda.orders.id')
          %th= t('tienda.orders.type')
          %th= t('tienda.orders.method')
          %th= t('tienda.orders.reference')
          %th= t('tienda.orders.amount')
          %th= t('tienda.orders.refunded?')
          %th
      %tbody
        - for payment in @payments
          %tr
            %td= payment.id
            %td
              = payment.refund? ? t('tienda.orders.refund') : t('tienda.orders.payment')
              %span.float-right= boolean_tag payment.confirmed?
            %td= payment.method
            %td= link_to_if payment.transaction_url, payment.reference, payment.transaction_url

            - if payment.refund?
              %td{:colspan => 2}
                %b= number_to_currency payment.amount
                - if payment.parent_payment_id
                  #{t('tienda.orders.from_payment')} ##{payment.parent_payment_id}
            - else
              %td= number_to_currency payment.amount
              %td= boolean_tag payment.refunded?, nil, :true_text => number_to_currency(payment.amount_refunded)
            %td.refund
              - if payment.refundable?
                = link_to t('tienda.orders.refund'), [:refund, @order, payment], :class => 'button purple button-mini', :rel => 'dialog'
              - else
                = link_to t('tienda.delete'), [@order, payment], :class => 'button purple button-mini', :data => {:confirm => t('tienda.orders.payment_remove_confirmation') }, :method => :delete
- else
  %p.notice= t('tienda.orders.no_payments')

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
tienda-1.1.2 app/views/tienda/orders/_payments_table.html.haml
tienda-1.1.1 app/views/tienda/orders/_payments_table.html.haml
tienda-1.1.0 app/views/tienda/orders/_payments_table.html.haml
tienda-1.0.0 app/views/tienda/orders/_payments_table.html.haml