Sha256: 5e6d3a8051033f1fe04f6f8ea40ce8174b8af5bbd67fecad97767d19b653c204

Contents?: true

Size: 1.72 KB

Versions: 1

Compression:

Stored size: 1.72 KB

Contents

<div id="payment" data-hook>
  <p class="payment-type checkout-content-header">
    <%= Harpiya.t(:payment_type).upcase %>
  </p>

  <div data-hook="checkout_payment_step">
    <%= render partial: 'harpiya/checkout/payment/storecredit' %>

    <ul id="payment-method-fields" class="list-unstyled position-relative" data-hook>
      <% checkout_available_payment_methods.each do |method| %>
        <li class="radio">
          <%= label_tag '', class: "form-check-label harpiya-radio-label payment-option", data: { type: method.id == @payment_sources&.first&.payment_method_id ? 'card' : nil } do %>
            <%= radio_button_tag "order[payments_attributes][][payment_method_id]",
                                 method.id,
                                 method.id == @order.payments.checkout.last&.payment_method_id || method == checkout_available_payment_methods.first %>
            <span class="harpiya-radio-label-custom-input"></span>
            <%= Harpiya.t(method.name, scope: :payment_methods, default: method.name) %>
          <% end %>
        </li>
      <% end %>
    </ul>

    <div class="payment-sources">
      <%= render partial: 'payment_sources' if @payment_sources.present? %>

      <ul id="payment-methods" class="list-unstyled position-relative mb-0 payment-sources-add-form" data-hook>
        <% checkout_available_payment_methods.each do |method| %>
          <li id="payment_method_<%= method.id %>" class="<%= 'last' if method == checkout_available_payment_methods.last %>" data-hook>
            <fieldset>
              <%= render partial: "harpiya/checkout/payment/#{method.method_type}", locals: { payment_method: method } %>
            </fieldset>
          </li>
        <% end %>
      </ul>
    </div>
  </div>
</div>

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
harpiya_frontend-4.3.0.alpha app/views/harpiya/checkout/_payment.html.erb