Pārlūkot izejas kodu

创建Excel解析时间格式的工具类,创建解析数字类型的工具类,并根据测试不断修改代码

胡北宽 1 nedēļu atpakaļ
vecāks
revīzija
bc9b8cab86

+ 6
- 4
src/main/java/com/example/backend/service/contract/impl/SalesContractServiceImpl.java Parādīt failu

@@ -258,12 +258,14 @@ public class SalesContractServiceImpl implements SalesContractService {
258 258
                                 errors.add("主表(Sheet1) 第 " + currentRow + " 行:我方名称有误!");
259 259
                                 currentRowValid = false;
260 260
                             }
261
-                            if (foursnameList != null && !foursnameList.get(0).getFno().isEmpty()) {
262
-                                if(!entity.getFours().equals(foursnameList.get(0).getFno())){
263
-                                    errors.add("主表(Sheet1) 第 " + currentRow + " 行:我方编号与匹配到的不符合!");
264
-                                }
261
+
262
+                            if(foursnameList != null && foursnameList.get(0).getFno().isEmpty()){
263
+                                errors.add("主表(Sheet1) 第 " + currentRow + " 行:我方编号不能为空!");
265 264
                                 currentRowValid = false;
266 265
                             }
266
+                            if (foursnameList != null && !foursnameList.get(0).getFno().isEmpty()) {
267
+                                entity.setFours(foursnameList.get(0).getFno());
268
+                            }
267 269
 
268 270
                             if (foursnameList != null && !foursnameList.get(0).getOurBankNm().isEmpty()) {
269 271
                                 entity.setOurBankNm(foursnameList.get(0).getOurBankNm());

Notiek ielāde…
Atcelt
Saglabāt