配置修改
This commit is contained in:
@ -35,7 +35,28 @@ class Distribution extends Api
|
||||
return JsonServer::error('请求方式错误');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 扫码成为分销会员
|
||||
*/
|
||||
public function wxCodeApply()
|
||||
{
|
||||
if($this->request->isPost()){
|
||||
$post = $this->request->post();
|
||||
$user_id = $this->user_id;
|
||||
try{
|
||||
validate(DistributionValidate::class)->scene('apply')->check($post);
|
||||
}catch(ValidateException $e) {
|
||||
return JsonServer::error($e->getError());
|
||||
}
|
||||
$result = DistributionLogic::wxCodeApply($post,$user_id);
|
||||
if($result) {
|
||||
return JsonServer::success('成功');
|
||||
}
|
||||
return JsonServer::error('失败');
|
||||
}else{
|
||||
return JsonServer::error('请求方式错误');
|
||||
}
|
||||
}
|
||||
/**
|
||||
* 判断是否为分销会员
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user