【问题标题】:UPI integration with ionic app is not getting throughUPI 与 ionic 应用程序的集成没有通过
【发布时间】:2020-12-03 22:54:59
【问题描述】:

我已将我的 ionic App 与 UPI 集成。一切都很完美,就像所有 UPI 应用程序在付款时都打开供选择一样,但是当我输入我的 UPI 密码时。我总是遇到错误,付款没有发生。尝试了不同的 UPi 应用程序,但问题相同。请帮帮我

我的代码如下:-

import { Component, OnInit } from "@angular/core";

import { WebIntent } from "@ionic-native/web-intent/ngx";

import { Router } from "@angular/router";

@Component(
             {
               selector: "app-cart",

              templateUrl: "./cart.page.html",

              styleUrls: ["./cart.page.scss"],

            })
export class CartPage implements OnInit {

  totalPrice:number;
  UPI_ID:string;
  UPI_TXN_NOTE:string;
  UPI_NAME:string;
  TXN_Ref:string;

  constructor(private webIntent: WebIntent,
              private router   : Router) {}

  ngOnInit() {}

  weekly() {

    
    this.totalPrice = 10.00;
    this.UPI_ID = '1234567890@upi';
    this.UPI_NAME = 'test_KUMAR';
    this.UPI_TXN_NOTE = 'Weekly%20Package';
    this.TXN_Ref = '#Week001'
    const options = {
      action: this.webIntent.ACTION_VIEW,
      url:'upi://pay?pa=' + this.UPI_ID + '&pn=' + this.UPI_NAME + '&am=' + this.totalPrice + '&tn=' + this.UPI_TXN_NOTE + '&tr=' + this.TXN_Ref 
      };

      this.webIntent.startActivityForResult(options).then(
        (success)=>{
        
          console.log("Payment Succesfull",success);         
          
        },         
        err => {
          alert('error block' + err);
        }   
      
      );
  
    }

我也在 appmodule.ts 中导入了 webintent .. 一切都完成了,但仍然出现错误。请检查。

应用错误:-

error coming on phonepe app

【问题讨论】:

  • 怎么解决的?

标签: ionic-framework deep-linking upi


【解决方案1】:

这很简单。您需要为使用深度链接进行的交易使用商家 upi id

【讨论】:

  • 如何获取商家upi id?
  • 您需要注册 Google Pay for Business。你可以在这里获得更多信息。 support.google.com/pay/business/answer/7684271?hl=en 如果您仍然卡住,请告诉我。我们在应用程序中成功地做到了这一点。
  • sure.on Razorpay 我生成了 Marchant upi 及其工作,感谢您的帮助
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2016-05-05
  • 1970-01-01
  • 1970-01-01
  • 2018-02-10
  • 2022-10-04
  • 2012-05-18
相关资源
最近更新 更多