From 11b01181cc89d81fa30cb3b3dcf2ff1e6681f26b Mon Sep 17 00:00:00 2001
From: liurunyu <lry9898@163.com>
Date: 星期二, 12 十一月 2024 19:37:55 +0800
Subject: [PATCH] Merge branch 'master' of http://8.140.179.55:20000/r/pipIrr-SV
---
pipIrr-platform/pipIrr-web/pipIrr-web-base/src/main/java/com/dy/pipIrrBase/rtuUpgrade/program/UgRtuProgramCtrl.java | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/pipIrr-platform/pipIrr-web/pipIrr-web-base/src/main/java/com/dy/pipIrrBase/rtuUpgrade/program/UgRtuProgramCtrl.java b/pipIrr-platform/pipIrr-web/pipIrr-web-base/src/main/java/com/dy/pipIrrBase/rtuUpgrade/program/UgRtuProgramCtrl.java
index 66872cd..33993ce 100644
--- a/pipIrr-platform/pipIrr-web/pipIrr-web-base/src/main/java/com/dy/pipIrrBase/rtuUpgrade/program/UgRtuProgramCtrl.java
+++ b/pipIrr-platform/pipIrr-web/pipIrr-web-base/src/main/java/com/dy/pipIrrBase/rtuUpgrade/program/UgRtuProgramCtrl.java
@@ -151,6 +151,10 @@
if(vo.file == null){
return BaseResponseUtils.buildFail("RTU绋嬪簭鏂囦欢蹇呴』涓婁紶") ;
}
+ String fileName = vo.file.getOriginalFilename() ;
+ if(this.sv.existFileName(fileName)){
+ return BaseResponseUtils.buildFail("RTU绋嬪簭鏂囦欢鍚嶅凡瀛樺湪") ;
+ }
HexFileVo fileVo = null ;
byte[] fileBytes = null ;
@@ -166,7 +170,7 @@
}
if(fileVo != null){
UgRtuProgram po = new UgRtuProgram();
- po.hexFileName = vo.file.getOriginalFilename() ;
+ po.hexFileName = fileName ;
po.programCalculateBytes = (int)fileVo.calculateBytes ;
po.programCrc16 = fileVo.bytesCrc16 ;
po.programBytes = fileVo.bytes;
--
Gitblit v1.8.0