@@ -549,7 +549,7 @@ public void processSavedCardTransaction(SavedCard savedCard, RavePayInitializer
549549
550550
551551 @ Override
552- public void chargeCardWithSuggestedAuthModel (Payload payload , String zipOrPin , String authModel , String encryptionKey ) {
552+ public void chargeCardWithSuggestedAuthModel (final Payload payload , String zipOrPin , String authModel , String encryptionKey ) {
553553
554554 if (authModel .equalsIgnoreCase (AVS_VBVSECURECODE )) {
555555 payload .setBillingzip (zipOrPin );
@@ -595,6 +595,22 @@ public void onSuccess(ChargeResponse response, String responseAsJSONString) {
595595 } else if (authModelUsed .equalsIgnoreCase (AVS_VBVSECURECODE )) {
596596 String flwRef = response .getData ().getFlwRef ();
597597 mView .onAVSVBVSecureCodeModelUsed (response .getData ().getAuthurl (), flwRef );
598+ } else if (authModelUsed .equalsIgnoreCase (VBV )) {
599+ String authUrlCrude = response .getData ().getAuthurl ();
600+ String flwRef = response .getData ().getFlwRef ();
601+
602+ mView .onVBVAuthModelUsed (authUrlCrude , flwRef );
603+ } else if (authModelUsed .equalsIgnoreCase (GTB_OTP )
604+ || authModelUsed .equalsIgnoreCase (ACCESS_OTP )
605+ || authModelUsed .toLowerCase ().contains ("otp" )) {
606+ String flwRef = response .getData ().getFlwRef ();
607+ String chargeResponseMessage = response .getData ().getChargeResponseMessage ();
608+ chargeResponseMessage = chargeResponseMessage == null ? enterOTP : chargeResponseMessage ;
609+ mView .showOTPLayout (flwRef , chargeResponseMessage );
610+
611+ } else if (authModelUsed .equalsIgnoreCase (NOAUTH )) {
612+ String flwRef = response .getData ().getFlwRef ();
613+ mView .onNoAuthUsed (flwRef , payload .getPBFPubKey ());
598614 } else {
599615 mView .onPaymentError (unknownAuthmsg );
600616 }
0 commit comments