头条支付

This commit is contained in:
devil_gong 2019-10-29 14:47:15 +08:00
parent 59ca26e6ce
commit abf692b473
3 changed files with 4 additions and 2 deletions

View File

@ -69,7 +69,7 @@ class ToutiaoService
'subject' => '订单支付',
'body' => $order['order_no'],
'trade_time' => $order['add_time'],
'valid_time' => $order['add_time']+(intval(MyC('common_order_close_limit_time', 30, true))*60),
'valid_time' => intval(MyC('common_order_close_limit_time', 30, true))*60,
'notify_url' => __MY_URL__,
];
$order_info['sign'] = (new \base\Toutiao())->PaySignCreated($order_info, $secret);

View File

@ -67,7 +67,7 @@ App({
// 请求地址
request_url: "{{request_url}}",
request_url: 'http://tp5-dev.com/',
//request_url: 'https://test.shopxo.net/',
request_url: 'https://test.shopxo.net/',
// 基础信息
application_title: "{{application_title}}",

View File

@ -234,9 +234,11 @@ Page({
app.showToast("支付成功", "success");
} else {
console.log(res.data.data.order_info)
tt.pay({
orderInfo: res.data.data.order_info,
service: res.data.data.service,
_debug: 1,
getOrderStatus(res) {
let { out_order_no } = res;
return new Promise(function(resolve, reject) {