|
@@ -30,8 +30,11 @@ class CustomController extends BaseController
|
|
|
$id = $get['id'] ?? 0;
|
|
$id = $get['id'] ?? 0;
|
|
|
$isHd = $get['isHd'] ?? 1;
|
|
$isHd = $get['isHd'] ?? 1;
|
|
|
$custom = CustomClass::getById($id, true);
|
|
$custom = CustomClass::getById($id, true);
|
|
|
- if (empty($custom) || $custom->ownMainId != $this->mainId) {
|
|
|
|
|
- util::fail('修改失败');
|
|
|
|
|
|
|
+ if (empty($custom)) {
|
|
|
|
|
+ util::fail('没有找到客户');
|
|
|
|
|
+ }
|
|
|
|
|
+ if ($custom->ownMainId != $this->mainId) {
|
|
|
|
|
+ util::fail('没有权限');
|
|
|
}
|
|
}
|
|
|
$ghsId = $custom->ghsId ?? 0;
|
|
$ghsId = $custom->ghsId ?? 0;
|
|
|
$ghs = GhsClass::getById($ghsId, true);
|
|
$ghs = GhsClass::getById($ghsId, true);
|