@@ -290,10 +290,9 @@ impl
290
290
| api_models:: payments:: VoucherData :: FamilyMart { .. }
291
291
| api_models:: payments:: VoucherData :: Seicomart { .. }
292
292
| api_models:: payments:: VoucherData :: PayEasy { .. } => {
293
- Err ( errors:: ConnectorError :: NotSupported {
294
- message : utils:: SELECTED_PAYMENT_METHOD . to_string ( ) ,
295
- connector : "Zen" ,
296
- } ) ?
293
+ Err ( errors:: ConnectorError :: NotImplemented (
294
+ utils:: get_unimplemented_payment_method_error_message ( "Zen" ) ,
295
+ ) ) ?
297
296
}
298
297
} ;
299
298
Ok ( Self :: ApiRequest ( Box :: new ( ApiRequest {
@@ -342,12 +341,8 @@ impl
342
341
api_models:: payments:: BankTransferData :: Pse { .. } => {
343
342
ZenPaymentChannels :: PclBoacompraPse
344
343
}
345
- api_models:: payments:: BankTransferData :: SepaBankTransfer { .. } => {
346
- Err ( errors:: ConnectorError :: NotImplemented (
347
- utils:: get_unimplemented_payment_method_error_message ( "Zen" ) ,
348
- ) ) ?
349
- }
350
- api_models:: payments:: BankTransferData :: AchBankTransfer { .. }
344
+ api_models:: payments:: BankTransferData :: SepaBankTransfer { .. }
345
+ | api_models:: payments:: BankTransferData :: AchBankTransfer { .. }
351
346
| api_models:: payments:: BankTransferData :: BacsBankTransfer { .. }
352
347
| api_models:: payments:: BankTransferData :: PermataBankTransfer { .. }
353
348
| api_models:: payments:: BankTransferData :: BcaBankTransfer { .. }
@@ -356,10 +351,9 @@ impl
356
351
| api_models:: payments:: BankTransferData :: CimbVaBankTransfer { .. }
357
352
| api_models:: payments:: BankTransferData :: DanamonVaBankTransfer { .. }
358
353
| api_models:: payments:: BankTransferData :: MandiriVaBankTransfer { .. } => {
359
- Err ( errors:: ConnectorError :: NotSupported {
360
- message : utils:: SELECTED_PAYMENT_METHOD . to_string ( ) ,
361
- connector : "Zen" ,
362
- } ) ?
354
+ Err ( errors:: ConnectorError :: NotImplemented (
355
+ utils:: get_unimplemented_payment_method_error_message ( "Zen" ) ,
356
+ ) ) ?
363
357
}
364
358
} ;
365
359
Ok ( Self :: ApiRequest ( Box :: new ( ApiRequest {
@@ -489,12 +483,8 @@ impl
489
483
api_models:: payments:: WalletData :: WeChatPayRedirect ( _)
490
484
| api_models:: payments:: WalletData :: PaypalRedirect ( _)
491
485
| api_models:: payments:: WalletData :: ApplePay ( _)
492
- | api_models:: payments:: WalletData :: GooglePay ( _) => {
493
- Err ( errors:: ConnectorError :: NotImplemented (
494
- utils:: get_unimplemented_payment_method_error_message ( "Zen" ) ,
495
- ) ) ?
496
- }
497
- api_models:: payments:: WalletData :: AliPayQr ( _)
486
+ | api_models:: payments:: WalletData :: GooglePay ( _)
487
+ | api_models:: payments:: WalletData :: AliPayQr ( _)
498
488
| api_models:: payments:: WalletData :: AliPayRedirect ( _)
499
489
| api_models:: payments:: WalletData :: AliPayHkRedirect ( _)
500
490
| api_models:: payments:: WalletData :: MomoRedirect ( _)
@@ -514,10 +504,9 @@ impl
514
504
| api_models:: payments:: WalletData :: CashappQr ( _)
515
505
| api_models:: payments:: WalletData :: SwishQr ( _)
516
506
| api_models:: payments:: WalletData :: WeChatPayQr ( _) => {
517
- Err ( errors:: ConnectorError :: NotSupported {
518
- message : utils:: SELECTED_PAYMENT_METHOD . to_string ( ) ,
519
- connector : "Zen" ,
520
- } ) ?
507
+ Err ( errors:: ConnectorError :: NotImplemented (
508
+ utils:: get_unimplemented_payment_method_error_message ( "Zen" ) ,
509
+ ) ) ?
521
510
}
522
511
} ;
523
512
let terminal_uuid = session_data
@@ -719,10 +708,9 @@ impl TryFrom<&ZenRouterData<&types::PaymentsAuthorizeRouterData>> for ZenPayment
719
708
| api_models:: payments:: PaymentMethodData :: MandatePayment
720
709
| api_models:: payments:: PaymentMethodData :: Reward
721
710
| api_models:: payments:: PaymentMethodData :: Upi ( _) => {
722
- Err ( errors:: ConnectorError :: NotSupported {
723
- message : utils:: SELECTED_PAYMENT_METHOD . to_string ( ) ,
724
- connector : "Zen" ,
725
- } ) ?
711
+ Err ( errors:: ConnectorError :: NotImplemented (
712
+ utils:: get_unimplemented_payment_method_error_message ( "Zen" ) ,
713
+ ) ) ?
726
714
}
727
715
}
728
716
}
@@ -736,13 +724,8 @@ impl TryFrom<&api_models::payments::BankRedirectData> for ZenPaymentsRequest {
736
724
| api_models:: payments:: BankRedirectData :: Sofort { .. }
737
725
| api_models:: payments:: BankRedirectData :: BancontactCard { .. }
738
726
| api_models:: payments:: BankRedirectData :: Blik { .. }
739
- | api_models:: payments:: BankRedirectData :: Trustly { .. } => {
740
- Err ( errors:: ConnectorError :: NotImplemented (
741
- utils:: get_unimplemented_payment_method_error_message ( "Zen" ) ,
742
- )
743
- . into ( ) )
744
- }
745
- api_models:: payments:: BankRedirectData :: Eps { .. }
727
+ | api_models:: payments:: BankRedirectData :: Trustly { .. }
728
+ | api_models:: payments:: BankRedirectData :: Eps { .. }
746
729
| api_models:: payments:: BankRedirectData :: Giropay { .. }
747
730
| api_models:: payments:: BankRedirectData :: Przelewy24 { .. }
748
731
| api_models:: payments:: BankRedirectData :: Bizum { }
@@ -754,10 +737,9 @@ impl TryFrom<&api_models::payments::BankRedirectData> for ZenPaymentsRequest {
754
737
| api_models:: payments:: BankRedirectData :: OpenBankingUk { .. }
755
738
| api_models:: payments:: BankRedirectData :: OnlineBankingFpx { .. }
756
739
| api_models:: payments:: BankRedirectData :: OnlineBankingThailand { .. } => {
757
- Err ( errors:: ConnectorError :: NotSupported {
758
- message : utils:: SELECTED_PAYMENT_METHOD . to_string ( ) ,
759
- connector : "Zen" ,
760
- }
740
+ Err ( errors:: ConnectorError :: NotImplemented (
741
+ utils:: get_unimplemented_payment_method_error_message ( "Zen" ) ,
742
+ )
761
743
. into ( ) )
762
744
}
763
745
}
@@ -776,10 +758,9 @@ impl TryFrom<&api_models::payments::PayLaterData> for ZenPaymentsRequest {
776
758
| api_models:: payments:: PayLaterData :: WalleyRedirect { }
777
759
| api_models:: payments:: PayLaterData :: AlmaRedirect { }
778
760
| api_models:: payments:: PayLaterData :: AtomeRedirect { } => {
779
- Err ( errors:: ConnectorError :: NotSupported {
780
- message : utils:: SELECTED_PAYMENT_METHOD . to_string ( ) ,
781
- connector : "Zen" ,
782
- }
761
+ Err ( errors:: ConnectorError :: NotImplemented (
762
+ utils:: get_unimplemented_payment_method_error_message ( "Zen" ) ,
763
+ )
783
764
. into ( ) )
784
765
}
785
766
}
@@ -794,10 +775,9 @@ impl TryFrom<&api_models::payments::BankDebitData> for ZenPaymentsRequest {
794
775
| api_models:: payments:: BankDebitData :: SepaBankDebit { .. }
795
776
| api_models:: payments:: BankDebitData :: BecsBankDebit { .. }
796
777
| api_models:: payments:: BankDebitData :: BacsBankDebit { .. } => {
797
- Err ( errors:: ConnectorError :: NotSupported {
798
- message : utils:: SELECTED_PAYMENT_METHOD . to_string ( ) ,
799
- connector : "Zen" ,
800
- }
778
+ Err ( errors:: ConnectorError :: NotImplemented (
779
+ utils:: get_unimplemented_payment_method_error_message ( "Zen" ) ,
780
+ )
801
781
. into ( ) )
802
782
}
803
783
}
@@ -811,10 +791,9 @@ impl TryFrom<&api_models::payments::CardRedirectData> for ZenPaymentsRequest {
811
791
api_models:: payments:: CardRedirectData :: Knet { }
812
792
| api_models:: payments:: CardRedirectData :: Benefit { }
813
793
| api_models:: payments:: CardRedirectData :: MomoAtm { } => {
814
- Err ( errors:: ConnectorError :: NotSupported {
815
- message : utils:: SELECTED_PAYMENT_METHOD . to_string ( ) ,
816
- connector : "Zen" ,
817
- }
794
+ Err ( errors:: ConnectorError :: NotImplemented (
795
+ utils:: get_unimplemented_payment_method_error_message ( "Zen" ) ,
796
+ )
818
797
. into ( ) )
819
798
}
820
799
}
@@ -825,19 +804,13 @@ impl TryFrom<&api_models::payments::GiftCardData> for ZenPaymentsRequest {
825
804
type Error = error_stack:: Report < errors:: ConnectorError > ;
826
805
fn try_from ( value : & api_models:: payments:: GiftCardData ) -> Result < Self , Self :: Error > {
827
806
match value {
828
- api_models:: payments:: GiftCardData :: PaySafeCard { } => {
807
+ api_models:: payments:: GiftCardData :: PaySafeCard { }
808
+ | api_models:: payments:: GiftCardData :: Givex ( _) => {
829
809
Err ( errors:: ConnectorError :: NotImplemented (
830
810
utils:: get_unimplemented_payment_method_error_message ( "Zen" ) ,
831
811
)
832
812
. into ( ) )
833
813
}
834
- api_models:: payments:: GiftCardData :: Givex ( _) => {
835
- Err ( errors:: ConnectorError :: NotSupported {
836
- message : utils:: SELECTED_PAYMENT_METHOD . to_string ( ) ,
837
- connector : "Zen" ,
838
- }
839
- . into ( ) )
840
- }
841
814
}
842
815
}
843
816
}
0 commit comments