|
|
|
@ -588,14 +588,14 @@ ADD COLUMN `pay_url` text NULL AFTER `check_sign`;
|
|
|
|
|
*/
|
|
|
|
|
public function platform_weixin_pay() {
|
|
|
|
|
if (!$this->userId) {
|
|
|
|
|
$this->error("用户未登入");
|
|
|
|
|
jsonOutput(0, "用户未登入");
|
|
|
|
|
}
|
|
|
|
|
$request['user_id'] = $this->userId;
|
|
|
|
|
|
|
|
|
|
// 支付验证 是否让支付
|
|
|
|
|
$payCheck = pay_check($this->userId);
|
|
|
|
|
if (!$payCheck['code']) {
|
|
|
|
|
$this->error($payCheck['msg']);
|
|
|
|
|
jsonOutput(0, $payCheck['msg']);
|
|
|
|
|
// echo json_encode(['code'=>0,'msg'=> $payCheck['msg']]);exit;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -604,7 +604,7 @@ ADD COLUMN `pay_url` text NULL AFTER `check_sign`;
|
|
|
|
|
$game_id = I('request.game_id');
|
|
|
|
|
$user_id = $request['user_id'];
|
|
|
|
|
if($request['price']*1<=0 || $request['price'] > C('WX_PAY_LIMIT')) {
|
|
|
|
|
$this->new_set_message(0,"fail","充值金额有误", 3);
|
|
|
|
|
jsonOutput(0, "充值金额有误");
|
|
|
|
|
//redirect(U('Spend/notice',array('user_id'=>$user_id, 'is_platform' => 1, 'msg'=>'充值金额有误', 'game_id' => $game_id, 'user_token' => $this->userToken)));exit;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -631,7 +631,7 @@ ADD COLUMN `pay_url` text NULL AFTER `check_sign`;
|
|
|
|
|
redirect($json_data['url']);
|
|
|
|
|
} */
|
|
|
|
|
}else{
|
|
|
|
|
$this->new_set_message(0,"fail","支付失败", 3);
|
|
|
|
|
jsonOutput(0, "支付失败");
|
|
|
|
|
// redirect(U('Spend/notice',array('user_id'=>$user_id, 'is_platform' => 1,'game_id'=>$game_id,'msg'=>'支付失败', 'user_token' => $this->userToken)));exit;
|
|
|
|
|
}
|
|
|
|
|
}elseif(get_wx_pay_type() == 1){
|
|
|
|
|