From 4930b7b658628871a76a4d7283d0cd03c47d826f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20Beganovi=C4=87?= Date: Fri, 22 Jan 2021 22:49:26 +0100 Subject: [PATCH] wip --- resources/lang/en/texts.php | 3 ++ .../authorize/credit_card/pay.blade.php | 37 ++++++++++++++----- 2 files changed, 31 insertions(+), 9 deletions(-) diff --git a/resources/lang/en/texts.php b/resources/lang/en/texts.php index fcc8d3347fd7..e6ebaf287db5 100644 --- a/resources/lang/en/texts.php +++ b/resources/lang/en/texts.php @@ -3376,4 +3376,7 @@ return [ 'notification_credit_bounced_subject' => 'Unable to deliver Credit :invoice', 'save_payment_method_details' => 'Save payment method details', + + 'new_card' => 'New card', + 'new_bank_account' => 'New bank account', ]; diff --git a/resources/views/portal/ninja2020/gateways/authorize/credit_card/pay.blade.php b/resources/views/portal/ninja2020/gateways/authorize/credit_card/pay.blade.php index 2a1e841b36d8..b121661b94af 100644 --- a/resources/views/portal/ninja2020/gateways/authorize/credit_card/pay.blade.php +++ b/resources/views/portal/ninja2020/gateways/authorize/credit_card/pay.blade.php @@ -32,16 +32,35 @@ @include('portal.ninja2020.gateways.includes.payment_details') - @if($token) - @component('portal.ninja2020.components.general.card-element', ['title' => ctrans('texts.credit_card')]) - {{ strtoupper($token->meta->brand) }} - **** {{ $token->meta->last4 }} - @endcomponent + @component('portal.ninja2020.components.general.card-element', ['title' => ctrans('texts.pay_with')]) + @if(count($tokens) > 0) + @foreach($tokens as $token) + + @endforeach + @endisset - @include('portal.ninja2020.gateways.includes.pay_now', ['id' => 'card_button', 'class' => 'pay_now_button', 'data' => ['id' => $token->hashed_id]]) - @else - @include('portal.ninja2020.gateways.authorize.includes.credit_card') - @include('portal.ninja2020.gateways.includes.pay_now', ['id' => 'card_button']) - @endif + + @endcomponent + + @include('portal.ninja2020.gateways.includes.save_card') + + @include('portal.ninja2020.gateways.authorize.includes.credit_card') + @include('portal.ninja2020.gateways.includes.pay_now') @endsection @section('gateway_footer')