From 014c441ee261994f37fadc31647053216ffeb4a7 Mon Sep 17 00:00:00 2001 From: "CHIEFSOFT\\ameye" Date: Tue, 28 Nov 2023 22:19:38 -0500 Subject: [PATCH] add credir --- src/app/accounts/addcredit/addcredit.page.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/app/accounts/addcredit/addcredit.page.ts b/src/app/accounts/addcredit/addcredit.page.ts index e713cbb..3e63230 100644 --- a/src/app/accounts/addcredit/addcredit.page.ts +++ b/src/app/accounts/addcredit/addcredit.page.ts @@ -27,6 +27,7 @@ export class AddcreditPage implements OnInit { isModalOpen:boolean = false; isModalOpenBackdrop:boolean = false; card_level:number=200; + flutterwave_key:string=''; @@ -115,6 +116,8 @@ export class AddcreditPage implements OnInit { } payViaPromise() { + this.paymentData.public_key = this.flutterwave_key; + this.flutterwave.asyncInlinePay(this.paymentData).then( (response) =>{ console.log("Promise Res" , response) @@ -162,7 +165,7 @@ export class AddcreditPage implements OnInit { console.log("startCreditResult TOTAL RETURN->", this.startCreditResult); if ( startCreditResult!=undefined && startCreditResult.credit_reference!='' ){ this.startCreditResult = startCreditResult; - + this.flutterwave_key = this.startCreditResult.flutterwave_key; this.isModalOpen = true; this.isModalOpenBackdrop= true; @@ -238,8 +241,10 @@ export class AddcreditPage implements OnInit { }); if(this.processor == 3030){ - debugger; + // debugger; + loading.present(); this.payViaPromise(); + return 0; } if (this.processor == 5000){ this.isProcessDisabled = true;