diff --git a/src/main/java/com/zcloud/controller/accident/AccidentRecordsController.java b/src/main/java/com/zcloud/controller/accident/AccidentRecordsController.java index b7ddfa80..d1f125a8 100644 --- a/src/main/java/com/zcloud/controller/accident/AccidentRecordsController.java +++ b/src/main/java/com/zcloud/controller/accident/AccidentRecordsController.java @@ -1,13 +1,11 @@ package com.zcloud.controller.accident; -import cn.hutool.core.bean.BeanUtil; import cn.hutool.core.collection.CollUtil; import cn.hutool.core.util.ObjectUtil; import cn.hutool.core.util.StrUtil; import com.zcloud.controller.base.BaseController; import com.zcloud.entity.Page; import com.zcloud.entity.PageData; -import com.zcloud.entity.accident.AccidentRecords; import com.zcloud.service.accident.AccidentRecordsService; import com.zcloud.util.ObjectExcelView; import lombok.RequiredArgsConstructor; @@ -95,7 +93,7 @@ public class AccidentRecordsController extends BaseController { if (CollUtil.isEmpty(pageData)){ throw new RuntimeException("参数不能为空"); } - if (pageData.get("id") != null) { + if (pageData.get("id") == null) { throw new RuntimeException("id不能为空"); } accidentRecordsService.update(pageData);