【问题标题】:This MID is not available on our staging environment in flutterFlutter 暂存环境中不提供此 MID
【发布时间】:2019-09-21 05:45:34
【问题描述】:

我正在尝试在 Flutter 中集成 paytm 支付网关,但它在分期中运行良好,但是当我将分期转移到生产环境时,会显示错误。此 MID 在我们的暂存环境中不可用。

依赖: 支付宝:^1.0.0

导入'package:paytm/paytm.dart';

void generateCheckSum() 异步 {

var url ='https://us-central1-mrdishant-4819c.cloudfunctions.net/generateCheckSum';

String orderId = tnxidController.text;

//Please use your parameters here
//CHANNEL_ID etc provided to you by paytm

final response = await http.post(url, headers: {
  "Content-Type": "application/x-www-form-urlencoded"
}, body: {
  "mid": "------------------",
  "CHANNEL_ID": "WAP",
  'INDUSTRY_TYPE_ID': 'Retail',
  'WEBSITE': 'APPSTAGING',
  'PAYTM_MERCHANT_KEY': '--------------',
  'TXN_AMOUNT': amountController.text,
  'ORDER_ID': orderId,
  'CUST_ID': Constant.SUPERID,
});

String callBackUrl ='https://securegw-stage.paytm.in/theia/paytmCallback?ORDER_ID=' + orderId;

print("Response :" + response.body);

var paytmResponse = Paytm.startPaytmPayment(
    true,
    "---------------------",
    orderId,
    Constant.SUPERID,
    "WAP",
    amountController.text,
    'APPSTAGING',
    callBackUrl,
    'Retail',
    response.body);

paytmResponse.then((value) {
  setState(() {
    payment_response = value.toString();
  });
});

}

【问题讨论】:

    标签: android flutter dart


    【解决方案1】:

    您仍在使用暂存callBackUrl、暂存WEBSITE 和暂存INDUSTRY_TYPE_ID。您应该将它们更改为它们的生产值,因为 callBackUrl 它以 https://securegw.paytm.in 开头

    【讨论】:

      猜你喜欢
      • 2019-10-31
      • 2018-08-25
      • 2015-11-03
      • 2015-07-29
      • 2016-11-04
      • 1970-01-01
      • 2015-09-05
      • 2014-02-01
      • 2014-05-08
      相关资源
      最近更新 更多