app/views/spree/checkout/_payment.html.erb in spree_frontend-4.2.0.beta vs app/views/spree/checkout/_payment.html.erb in spree_frontend-4.2.0.rc1
- old
+ new
@@ -2,11 +2,10 @@
<p class="payment-type checkout-content-header">
<%= Spree.t(:payment_type).upcase %>
</p>
<div data-hook="checkout_payment_step">
-
<%= render partial: 'spree/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">
@@ -20,28 +19,10 @@
</li>
<% end %>
</ul>
<div class="payment-sources">
- <% if @payment_sources.present? %>
- <div id="existing_cards" class="payment-sources-existing-cards">
- <%= radio_button_tag 'use_existing_card', 'yes', true, class: 'd-none' %>
- <div class="form-group" data-hook="existing_cards">
- <div class="d-flex flex-column payment-sources-list">
- <% @payment_sources.each do |card| %>
- <%= render partial: 'credit_card', locals: { card: card } %>
- <% end %>
- <div>
- <label class="form-check-label spree-radio-label col-6 mb-2">
- <%= radio_button_tag 'use_existing_card', 'no' %>
- <span class="spree-radio-label-custom-input"></span>
- <span><%= Spree.t(:add_new_credit_card) %></span>
- </label>
- </div>
- </div>
- </div>
- </div>
- <% end %>
+ <%= 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>