From 79e481b7da2a83c769f9709eeec0e7130359be1b Mon Sep 17 00:00:00 2001
From: wuzeyu <1223318623@qq.com>
Date: 星期五, 05 七月 2024 16:59:12 +0800
Subject: [PATCH] 添加取水口和更改取水口时判断取水口是否重名 重新优化

---
 pipIrr-platform/pipIrr-web/pipIrr-web-base/src/main/java/com/dy/pipIrrBase/block/BlockCtrl.java |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/pipIrr-platform/pipIrr-web/pipIrr-web-base/src/main/java/com/dy/pipIrrBase/block/BlockCtrl.java b/pipIrr-platform/pipIrr-web/pipIrr-web-base/src/main/java/com/dy/pipIrrBase/block/BlockCtrl.java
index 341e897..db4b1fe 100644
--- a/pipIrr-platform/pipIrr-web/pipIrr-web-base/src/main/java/com/dy/pipIrrBase/block/BlockCtrl.java
+++ b/pipIrr-platform/pipIrr-web/pipIrr-web-base/src/main/java/com/dy/pipIrrBase/block/BlockCtrl.java
@@ -1,6 +1,7 @@
 package com.dy.pipIrrBase.block;
 
 import com.dy.common.aop.SsoAop;
+import com.dy.common.mybatis.envm.Deleted;
 import com.dy.common.webUtil.BaseResponse;
 import com.dy.common.webUtil.BaseResponseUtils;
 import com.dy.common.webUtil.QueryResultVo;
@@ -99,7 +100,8 @@
                             schema = @Schema(implementation = BaBlock.class))}
             )
     })
-    @GetMapping(path = "one", consumes = MediaType.TEXT_PLAIN_VALUE)
+    //@GetMapping(path = "one", consumes = MediaType.TEXT_PLAIN_VALUE)
+    @GetMapping(path = "one")
     @SsoAop()
     public BaseResponse<BaBlock> one(Long id){
         return BaseResponseUtils.buildSuccess(this.sv.selectById(id));
@@ -126,6 +128,7 @@
             return BaseResponseUtils.buildFail(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage());
         }
         po.id = null ;
+        po.deleted = Deleted.NO;
         int count;
         try {
             count = this.sv.save(po);
@@ -192,7 +195,8 @@
                             schema = @Schema(implementation = Boolean.class))}
             )
     })
-    @GetMapping(path = "delete", consumes = MediaType.TEXT_PLAIN_VALUE)
+    //@GetMapping(path = "delete", consumes = MediaType.TEXT_PLAIN_VALUE)
+    @GetMapping(path = "delete")
     @SsoAop()
     public BaseResponse<Boolean> delete(Long id){
         if(id == null){

--
Gitblit v1.8.0