From f2744910df4054d2ddbb62f07f546825d51dd783 Mon Sep 17 00:00:00 2001 From: ctexthuang Date: Fri, 22 Nov 2024 14:58:21 +0800 Subject: [PATCH] feat : site --- app/Service/Admin/System/SiteService.php | 3 ++- app/Service/Common/OssCallbackService.php | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/Service/Admin/System/SiteService.php b/app/Service/Admin/System/SiteService.php index 1ba19f0..f36eceb 100644 --- a/app/Service/Admin/System/SiteService.php +++ b/app/Service/Admin/System/SiteService.php @@ -219,13 +219,14 @@ class SiteService extends BaseService $id = (int)$this->request->input('id'); $name = $this->request->input('name'); $status = (int)$this->request->input('status'); + $this->cityId = (int)$this->request->input('city_id'); $info = $this->siteModel->getInfoById($id); $nameInfo = $this->siteModel->getInfoByName($name); if (empty($info)) throw new ErrException('数据不存在'); if ($info->id != $nameInfo->id) throw new ErrException('数据已存在'); - if ($this->request->input('city_id') != $info->city_id) throw new ErrException('城市不可更改'); + if ($this->cityId != $info->city_id) throw new ErrException('城市不可更改'); $this->cityInfo = $this->systemCityModel->getInfoByCityId($info->cityId); if ($status != SiteCode::SITE_DISABLE) { diff --git a/app/Service/Common/OssCallbackService.php b/app/Service/Common/OssCallbackService.php index 7ecc090..0874ab1 100644 --- a/app/Service/Common/OssCallbackService.php +++ b/app/Service/Common/OssCallbackService.php @@ -105,6 +105,7 @@ class OssCallbackService 'admin_avatar', 'avatar', 'menu', + 'site', ]; /**