File tree Expand file tree Collapse file tree 2 files changed +16
-0
lines changed
view/frontend/web/js/view/payment/method-renderer Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -181,4 +181,19 @@ public function getPaymentMethodName($payment)
181
181
{
182
182
return 'bancontactmrcash ' ;
183
183
}
184
+
185
+ public function isAvailable (\Magento \Quote \Api \Data \CartInterface $ quote = null )
186
+ {
187
+ $ orderId = $ quote ? $ quote ->getReservedOrderId () : null ;
188
+
189
+ $ objectManager = \Magento \Framework \App \ObjectManager::getInstance ();
190
+
191
+ $ paymentGroupTransaction = $ objectManager ->get (\Buckaroo \Magento2 \Helper \PaymentGroupTransaction::class);
192
+
193
+ if ($ paymentGroupTransaction ->getAlreadyPaid ($ orderId ) > 0 ) {
194
+ return false ;
195
+ }
196
+
197
+ return true ;
198
+ }
184
199
}
Original file line number Diff line number Diff line change @@ -291,6 +291,7 @@ define(
291
291
class : 'action primary accept' ,
292
292
click : function ( ) {
293
293
this . closeModal ( true ) ;
294
+ window . location . reload ( ) ;
294
295
}
295
296
} ]
296
297
} ) ;
You can’t perform that action at this time.
0 commit comments