Переглянути джерело

1 修改供应商银行判断sql

11816 2 місяці тому
джерело
коміт
d5f663c4e1

+ 12
- 12
src/main/java/com/example/backend/pAndSExe/dto/InfJinxiangfapiaoExcelDTO.java Переглянути файл

@@ -21,26 +21,26 @@ public class InfJinxiangfapiaoExcelDTO {
21 21
     private String taxInvType;
22 22
     @ExcelProperty(index = 5) // C列 - 发票号码
23 23
     private String taxInvNo;
24
-    @ExcelProperty(index = 6) // D列 - 发票号
25
-    private String invNo;
26
-    @ExcelProperty(index = 7) // D列 - 物料编码,物料描述,品牌
24
+/*    @ExcelProperty(index = 6) // D列 - 发票号
25
+    private String invNo;*/
26
+    @ExcelProperty(index = 6) // D列 - 物料编码,物料描述,品牌
27 27
     private String itemnoSdescBrand;
28
-    @ExcelProperty(index = 8) // E列 - 数量
28
+    @ExcelProperty(index = 7) // E列 - 数量
29 29
     private Double qty;
30
-    @ExcelProperty(index = 9)
30
+    @ExcelProperty(index = 8)
31 31
     private Double poPrice;
32
-    @ExcelProperty(index = 10) // F列 - 不含税单价
32
+    @ExcelProperty(index = 9) // F列 - 不含税单价
33 33
     private Double ntPoPrice;
34
-    @ExcelProperty(index = 11) // G列 - 单位
34
+    @ExcelProperty(index = 10) // G列 - 单位
35 35
     private String ut;
36
-    @ExcelProperty(index = 12)
36
+    @ExcelProperty(index = 11)
37 37
     private Double poamt;
38
-    @ExcelProperty(index = 13) // H列 - 不含税金额
38
+    @ExcelProperty(index = 12) // H列 - 不含税金额
39 39
     private Double ntPoAmt;
40
-    @ExcelProperty(index = 14) // I列 - 税率
40
+    @ExcelProperty(index = 13) // I列 - 税率
41 41
     private Double inTaxRate;
42
-    @ExcelProperty(index = 15) // J列 - 税额
42
+    @ExcelProperty(index = 14) // J列 - 税额
43 43
     private Double taxAmt;
44
-    @ExcelProperty(index = 16) // K列 - 币别
44
+    @ExcelProperty(index = 15) // K列 - 币别
45 45
     private String curcypo;
46 46
 }

+ 1
- 0
src/main/java/com/example/backend/pAndSExe/mapper/GongyingshangMapper.java Переглянути файл

@@ -29,6 +29,7 @@ public interface GongyingshangMapper  extends BaseMapper<Gongyingshang> {
29 29
             "        LEFT JOIN (\n" +
30 30
             "        SELECT  rid , bankNm , bankAcct , ROW_NUMBER() OVER (PARTITION BY rid ORDER BY id) as row_num\n" +
31 31
             "        FROM SGGMIIP.custbank   WHERE NVL(del_flag, 0) != 1\n" +
32
+            "        and nvl(ctStatus,'')='已准入'\n" +
32 33
             "        ) b ON a.id = b.rid AND b.row_num = 1\n" +
33 34
             "        left join SGGMIIP.custattn c on a.id = c.rid\n" +
34 35
             "        where ifnull(a.del_flag, 0) != 1\n" +

+ 11
- 10
src/main/java/com/example/backend/pAndSExe/util/PsExeExcelUtil.java Переглянути файл

@@ -646,12 +646,12 @@ public class PsExeExcelUtil {
646 646
                     }else {
647 647
                         int i=0;
648 648
                         for (Gongyingshang gongyingshang : gongyingshangList) {
649
-                            if (gongyingshang.getCtBankAcct().equals(strings[2])&&gongyingshang.getCtBankName().equals(strings[1])) {
649
+                            if (gongyingshang.getCtBankAcct().equals(strings[2])) {
650 650
                                 i++;
651 651
                             }
652 652
                         }
653 653
                         if (i==0) {
654
-                            errorLogList.add("银行名称/账号不存在/匹配");
654
+                            errorLogList.add("银行账号不存在/匹配/准入");
655 655
                         }
656 656
                     }
657 657
                 }
@@ -792,12 +792,12 @@ public class PsExeExcelUtil {
792 792
                     }else {
793 793
                         int i=0;
794 794
                         for (Gongyingshang gongyingshang : gongyingshangList) {
795
-                            if (gongyingshang.getCtBankAcct().equals(strings[2])&&gongyingshang.getCtBankName().equals(strings[1])) {
795
+                            if (gongyingshang.getCtBankAcct().equals(strings[2])) {
796 796
                                 i++;
797 797
                             }
798 798
                         }
799 799
                         if (i==0) {
800
-                            errorLogList.add("银行名称/账号不存在/匹配");
800
+                            errorLogList.add("银行账号不存在/匹配/准入");
801 801
                         }
802 802
                     }
803 803
                 }
@@ -1067,9 +1067,9 @@ public class PsExeExcelUtil {
1067 1067
         if (dto.getTaxInvNo() == null || dto.getTaxInvNo().isEmpty()) {
1068 1068
             errorLogList.add("税票号码为空");
1069 1069
         }
1070
-        if (dto.getInvNo()==null|| dto.getInvNo().isEmpty()) {
1070
+/*        if (dto.getInvNo()==null|| dto.getInvNo().isEmpty()) {
1071 1071
             errorLogList.add("发票号码为空");
1072
-        }
1072
+        }*/
1073 1073
 
1074 1074
         if (dto.getItemnoSdescBrand() != null&& !dto.getItemnoSdescBrand().isEmpty()) {
1075 1075
             String[] itemFields = splitCombinedField(dto.getItemnoSdescBrand());
@@ -1136,7 +1136,8 @@ public class PsExeExcelUtil {
1136 1136
             String createBy=infExe1Mapper.selectCreateByFromPono(dto.getPono());
1137 1137
             entity.setCreateBy(createBy);
1138 1138
         }
1139
-        entity.setInvNo(dto.getInvNo());
1139
+
1140
+        //entity.setInvNo(dto.getInvNo());
1140 1141
 
1141 1142
         entity.setDataStatus(errorLog.isEmpty() ? "0" : "9"); // 0=有效,9=无效
1142 1143
         entity.setErrorLog(errorLog); // 错误日志
@@ -1459,12 +1460,12 @@ public class PsExeExcelUtil {
1459 1460
                         }else {
1460 1461
                             int i=0;
1461 1462
                             for (Gongyingshang gongyingshang : gongyingshangList) {
1462
-                                if (gongyingshang.getCtBankAcct().equals(ctInvoiceBankAcct)&&gongyingshang.getCtBankName().equals(ctInvoiceBankName)&&gongyingshang.getCtContNm().equals(ctContNm)) {
1463
+                                if (gongyingshang.getCtBankAcct().equals(ctInvoiceBankAcct)&&gongyingshang.getCtContNm().equals(ctContNm)) {
1463 1464
                                     i++;
1464 1465
                                 }
1465 1466
                             }
1466 1467
                             if (i==0) {
1467
-                                errorLogList.add("银行名称/账号/收票人不存在/匹配");
1468
+                                errorLogList.add("银行名称/账号/收票人不存在/匹配/准入");
1468 1469
                             }
1469 1470
                         }
1470 1471
                     }
@@ -1773,7 +1774,7 @@ public class PsExeExcelUtil {
1773 1774
                         }else {
1774 1775
                             int i=0;
1775 1776
                             for (Gongyingshang gongyingshang : gongyingshangList) {
1776
-                                if (gongyingshang.getCtBankAcct().equals(ctInvoiceBankAcct)&&gongyingshang.getCtBankName().equals(ctInvoiceBankName)&&gongyingshang.getCtContNm().equals(ctContNm)) {
1777
+                                if (gongyingshang.getCtBankAcct().equals(ctInvoiceBankAcct)&&gongyingshang.getCtContNm().equals(ctContNm)) {
1777 1778
                                     i++;
1778 1779
                                 }
1779 1780
                             }

Завантаження…
Відмінити
Зберегти