作者 chencheng

2

... ... @@ -28,8 +28,8 @@ class Business extends Api
$this->auth->id = 1;//测试用
$postParam = $this->request->param();
$this->postParam = $postParam;
if (empty($postParam['code'])) {
$this->error("门店code异常");
if (empty($postParam['store_id'])) {
$this->error("门店store_id异常");
}
$this->store_id = $postParam['code'];
$store = Db::name("verification_store")->where("id", $this->store_id)->find();
... ...
... ... @@ -196,6 +196,7 @@ class Wechat extends Api
$this->error($e->getMessage());
}
if($user_id !=0){
$data['token'] = $this->auth->getToken();
$data['user_info'] = $user;
$this->success('完成',$data);
... ... @@ -206,6 +207,7 @@ class Wechat extends Api
}
/**注册 分销关系 如 https://coupon.xp.yn.cn?store_id=1&activity_id=3&share_id=2
* store_id,activity_id
* 关系 user表 id 和 pid
... ... @@ -239,6 +241,7 @@ class Wechat extends Api
/*
3.订单支付 前端请求
3.1 入库 订单状态
... ... @@ -256,11 +259,11 @@ class Wechat extends Api
});
3.3 回调修改订单状态
*/
public function prepare_order($order_no = ''){
$user_id = $this->auth->id;
if(empty($user_id)){
return $this->error('用户信息错误');
}
... ...