增加添加活到规则自动添加到身份权限里

This commit is contained in:
2020-08-19 13:46:28 +08:00
parent 488ab4f410
commit 156ad845f8
6 changed files with 84 additions and 9 deletions

View File

@@ -15,13 +15,13 @@ class YsdGrant extends Init
$activity = Activity::where('code', $this->activityId)->first();
if (!$activity) {
return '没有找到这个活动。';
return '发券失败,没有找到这个活动。';
}
if ($activity->user) {
$info = User::where('outlet_id', $this->outletId)->first();
if (!$info) {
return '未查询到此网点信息。';
return '发券失败,未查询到此网点信息。';
}
if ($info->parent_id != $activity->user_id) {

View File

@@ -27,7 +27,7 @@ class YsdVerification extends Init
return $res;
}
//查询卡券信息 返回model string 说明报错
//查询卡券信息 返回model 返回string 说明报错
$this->query_coupon = (new YsdQuery)->setOutletId($this->outletId)
->setCode($this->redemptionCode)
->start();