From 6f7059beb3f44bcb4bc18cc4bf13285d0913e065 Mon Sep 17 00:00:00 2001
From: zhubaomin <zhubaomin>
Date: 星期四, 22 八月 2024 10:57:03 +0800
Subject: [PATCH] 2024-08-22 朱宝民 优化代码-财务对账

---
 pipIrr-platform/pipIrr-web/pipIrr-web-wechat/src/main/java/com/dy/pipIrrWechat/command/ValveCtrl.java |   15 +++++----------
 1 files changed, 5 insertions(+), 10 deletions(-)

diff --git a/pipIrr-platform/pipIrr-web/pipIrr-web-wechat/src/main/java/com/dy/pipIrrWechat/command/ValveCtrl.java b/pipIrr-platform/pipIrr-web/pipIrr-web-wechat/src/main/java/com/dy/pipIrrWechat/command/ValveCtrl.java
index ca31d85..e534438 100644
--- a/pipIrr-platform/pipIrr-web/pipIrr-web-wechat/src/main/java/com/dy/pipIrrWechat/command/ValveCtrl.java
+++ b/pipIrr-platform/pipIrr-web/pipIrr-web-wechat/src/main/java/com/dy/pipIrrWechat/command/ValveCtrl.java
@@ -1,7 +1,6 @@
 package com.dy.pipIrrWechat.command;
 
 import com.alibaba.fastjson2.JSONObject;
-import com.dy.common.aop.SsoAop;
 import com.dy.common.mw.protocol.p206V1_0_0.CodeV1_0_1;
 import com.dy.common.mw.protocol.p206V1_0_0.downVos.*;
 import com.dy.common.mw.protocol.p206V202404.CodeV202404;
@@ -127,7 +126,7 @@
         }
 
         // 铏氭嫙鍗$姸鎬佷负浣跨敤涓紝涓斾笉鏄己鍒跺紑闃�鏃舵彁绀�
-        if (vc.getInUse() == 1 && !forceOpen) {
+        if (vc.getInUse() && !forceOpen) {
             return BaseResponseUtils.buildCodeMsg(WechatResultCode.IN_USE_VC_CANNOT_OPEN_VALVE.getCode(), WechatResultCode.IN_USE_VC_CANNOT_OPEN_VALVE.getMessage());
         }
 
@@ -317,7 +316,6 @@
      */
     @PostMapping(path = "timed_close", consumes = MediaType.APPLICATION_JSON_VALUE)
     @Transactional(rollbackFor = Exception.class)
-    @SsoAop()
     public BaseResponse<Boolean> timedClose(@RequestBody @Valid AutomaticClose automaticClose, BindingResult bindingResult) {
         if(bindingResult != null && bindingResult.hasErrors()){
             return BaseResponseUtils.buildErrorMsg(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage());
@@ -389,7 +387,7 @@
             myParam.setComId(comId);
             myParam.setComType((byte)2);
             myParam.setCommandCode(commandCode);
-            myParam.setCommandName(CodeV202404.getCodeName(commandCode));
+            myParam.setCommandName(CodeV1_0_1.getCodeName(commandCode));
             myParam.setIntakeId(intakeId);
             myParam.setRtuAddr(rtuAddr);
             myParam.setProtocol(protocol);
@@ -411,7 +409,6 @@
      */
     @PostMapping(path = "quantify_close", consumes = MediaType.APPLICATION_JSON_VALUE)
     @Transactional(rollbackFor = Exception.class)
-    @SsoAop()
     public BaseResponse<Boolean> quantifyClose(@RequestBody @Valid AutomaticClose automaticClose, BindingResult bindingResult) {
         if(bindingResult != null && bindingResult.hasErrors()){
             return BaseResponseUtils.buildErrorMsg(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage());
@@ -482,7 +479,7 @@
             myParam.setComId(comId);
             myParam.setComType((byte)2);
             myParam.setCommandCode(commandCode);
-            myParam.setCommandName(CodeV202404.getCodeName(commandCode));
+            myParam.setCommandName(CodeV1_0_1.getCodeName(commandCode));
             myParam.setIntakeId(intakeId);
             myParam.setRtuAddr(rtuAddr);
             myParam.setProtocol(protocol);
@@ -504,7 +501,6 @@
      */
     @PostMapping(path = "planed_open_timed_close", consumes = MediaType.APPLICATION_JSON_VALUE)
     @Transactional(rollbackFor = Exception.class)
-    @SsoAop()
     public BaseResponse<Boolean> planedOpenTimedClose(@RequestBody @Valid AutomaticClose automaticClose, BindingResult bindingResult) {
         if(bindingResult != null && bindingResult.hasErrors()){
             return BaseResponseUtils.buildErrorMsg(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage());
@@ -588,7 +584,7 @@
             myParam.setComId(comId);
             myParam.setComType((byte)2);
             myParam.setCommandCode(commandCode);
-            myParam.setCommandName(CodeV202404.getCodeName(commandCode));
+            myParam.setCommandName(CodeV1_0_1.getCodeName(commandCode));
             myParam.setIntakeId(intakeId);
             myParam.setRtuAddr(rtuAddr);
             myParam.setProtocol(protocol);
@@ -610,7 +606,6 @@
      */
     @PostMapping(path = "planed_open_quantify_close", consumes = MediaType.APPLICATION_JSON_VALUE)
     @Transactional(rollbackFor = Exception.class)
-    @SsoAop()
     public BaseResponse<Boolean> planedOpenQuantifyClose(@RequestBody @Valid AutomaticClose automaticClose, BindingResult bindingResult) {
         if(bindingResult != null && bindingResult.hasErrors()){
             return BaseResponseUtils.buildErrorMsg(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage());
@@ -694,7 +689,7 @@
             myParam.setComId(comId);
             myParam.setComType((byte)2);
             myParam.setCommandCode(commandCode);
-            myParam.setCommandName(CodeV202404.getCodeName(commandCode));
+            myParam.setCommandName(CodeV1_0_1.getCodeName(commandCode));
             myParam.setIntakeId(intakeId);
             myParam.setRtuAddr(rtuAddr);
             myParam.setProtocol(protocol);

--
Gitblit v1.8.0