From bd704d0c3a072967016a323f73d5a1e7331956da Mon Sep 17 00:00:00 2001 From: wanghongjun <1445693971@qq.com> Date: Fri, 22 May 2026 10:14:21 +0800 Subject: [PATCH] =?UTF-8?q?=E9=BB=98=E8=AE=A4=E5=B1=9E=E6=80=A7=E4=B8=8D?= =?UTF-8?q?=E5=8F=AF=E5=88=A0=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/Services/ParkingSpaceAttributesService.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/Services/ParkingSpaceAttributesService.php b/app/Services/ParkingSpaceAttributesService.php index 0560d5a..99ebaf4 100644 --- a/app/Services/ParkingSpaceAttributesService.php +++ b/app/Services/ParkingSpaceAttributesService.php @@ -117,6 +117,9 @@ class ParkingSpaceAttributesService DB::beginTransaction(); $model = ParkingSpaceAttributes::query()->findOrFail($id); + if ($model['is_default'] == 1) { + throw new Exception(__('admin.delete_failed')); + } $this->logService->logDeleted($model, 'space_attributes.delete');