|
|
@ -121,14 +121,15 @@ class Ipa365Controller extends BaseController{
|
|
|
|
'game_id' => $gameId,
|
|
|
|
'game_id' => $gameId,
|
|
|
|
'pay_status' => 0
|
|
|
|
'pay_status' => 0
|
|
|
|
))->find();
|
|
|
|
))->find();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$gameInfo = M('game', 'tab_')->field('game_name,supersign_token')->where(array(
|
|
|
|
|
|
|
|
'id' => $gameId,
|
|
|
|
|
|
|
|
))->find();
|
|
|
|
|
|
|
|
|
|
|
|
if ($payLog) {
|
|
|
|
if ($payLog) {
|
|
|
|
$orderId = $payLog['order_id'];
|
|
|
|
$orderId = $payLog['order_id'];
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
$orderId = "SS_" . date('Ymd') . date('His') . sp_random_string(4); // 超级签
|
|
|
|
$orderId = "SS_" . date('Ymd') . date('His') . sp_random_string(4); // 超级签
|
|
|
|
|
|
|
|
|
|
|
|
$gameInfo = M('game', 'tab_')->field('supersign_token')->where(array(
|
|
|
|
|
|
|
|
'id' => $gameId,
|
|
|
|
|
|
|
|
))->find();
|
|
|
|
|
|
|
|
if (!$gameInfo['supersign_token']) {
|
|
|
|
if (!$gameInfo['supersign_token']) {
|
|
|
|
$this->error("超级签token未填写!");
|
|
|
|
$this->error("超级签token未填写!");
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -169,10 +170,10 @@ class Ipa365Controller extends BaseController{
|
|
|
|
|
|
|
|
|
|
|
|
$weixn = new Weixin();
|
|
|
|
$weixn = new Weixin();
|
|
|
|
$wx_pay = json_decode($weixn->weixin_pay('超级签消费', $orderId, $price, 'MWEB', 4), true);
|
|
|
|
$wx_pay = json_decode($weixn->weixin_pay('超级签消费', $orderId, $price, 'MWEB', 4), true);
|
|
|
|
|
|
|
|
|
|
|
|
$this->assign("wxurl", $wx_pay['mweb_url']);
|
|
|
|
$this->assign("wxurl", $wx_pay['mweb_url']);
|
|
|
|
$this->assign("price", self::signprice);
|
|
|
|
$this->assign("price", self::signprice);
|
|
|
|
$this->assign("order_id", $orderId);
|
|
|
|
$this->assign("order_id", $orderId);
|
|
|
|
|
|
|
|
$this->assign("game_name",$gameInfo['game_name']);
|
|
|
|
|
|
|
|
|
|
|
|
$this->display();
|
|
|
|
$this->display();
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -404,7 +405,7 @@ class Ipa365Controller extends BaseController{
|
|
|
|
->setUserId($param['user_id'])
|
|
|
|
->setUserId($param['user_id'])
|
|
|
|
->setSdkVersion($param['sdk_version']);
|
|
|
|
->setSdkVersion($param['sdk_version']);
|
|
|
|
$pay_['url']= $pay->buildRequestForm($vo);
|
|
|
|
$pay_['url']= $pay->buildRequestForm($vo);
|
|
|
|
$pay_['out_trade_no']= $param['order_id'];
|
|
|
|
//$pay_['out_trade_no']= $out_trade_no;
|
|
|
|
return $pay_;
|
|
|
|
return $pay_;
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|