|
|
@@ -483,6 +483,7 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
e.setPreReleaseDate(preReleaseDate);// 81时间
|
|
|
e.setPassMode("1");// 一体化通关
|
|
|
e.setDeclPort(declPort);
|
|
|
+ e.setCustomsCode(rootCustomsMap.get(declPort));
|
|
|
e.setIePort(iePort);
|
|
|
e.setIeDate(ieDate);
|
|
|
e.setDeclDate(declDate);
|
|
|
@@ -672,7 +673,7 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
e.setManChkTimeEnd(manChkTimeEnd);//查验结束时间
|
|
|
e.setManProcResult(manProcResult);
|
|
|
e.setManProcIdea(manProcIdea);
|
|
|
- e.setCheckCustomsCode(checkCustomsCode);
|
|
|
+ e.setCheckCustomsCode(rootCustomsMap.get(checkCustomsCode));
|
|
|
dao.executeUpdate("delete from WXJY_ENTRY_HEAD where ENTRY_ID = ?", entryId);
|
|
|
|
|
|
entryHeadRepository.save(e);
|
|
|
@@ -752,7 +753,7 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
if (ieFlag.equals("0")) {
|
|
|
if (codeTs[16] != null) {
|
|
|
//syncChemicalsCiq只可能是包含了危化品,因为这个表的数据就是查询的系统中危险品模块里用户已经维护的包含了危化品的数据
|
|
|
- Object[] obj = (Object[]) dao.getObjectBySql("select * from iedg_sync_chemicals_ciq where CIQ_CODE = ?", (String) codeTs[16]);
|
|
|
+ Object[] obj = (Object[]) iedgRepository.getObjectBySql("select * from iedg_sync_chemicals_ciq where CIQ_CODE = ?", (String) codeTs[16]);
|
|
|
if (obj != null) {
|
|
|
if (codeTs[16] != null) {
|
|
|
entity.setGoodsType("1,2,3");
|
|
|
@@ -1192,6 +1193,7 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
e.setPassMode("3");// 转关
|
|
|
}
|
|
|
e.setDeclPort(declPort);
|
|
|
+ e.setCustomsCode(rootCustomsMap.get(declPort));
|
|
|
e.setIePort(iePort);
|
|
|
e.setIeDate(ieDate);
|
|
|
e.setDeclDate(declDate);
|
|
|
@@ -1390,7 +1392,7 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
e.setManChkTimeEnd(manChkTimeEnd);//查验结束时间
|
|
|
e.setManProcResult(manProcResult);
|
|
|
e.setManProcIdea(manProcIdea);
|
|
|
- e.setCheckCustomsCode(checkCustomsCode);
|
|
|
+ e.setCheckCustomsCode(rootCustomsMap.get(checkCustomsCode));
|
|
|
dao.executeUpdate("delete from WXJY_ENTRY_HEAD where ENTRY_ID = ?", entryId);
|
|
|
entryHeadRepository.save(e);
|
|
|
}
|
|
|
@@ -1469,7 +1471,7 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
if (ieFlag.equals("0")) {
|
|
|
if (codeTs[16] != null) {
|
|
|
//syncChemicalsCiq只可能是包含了危化品,因为这个表的数据就是查询的系统中危险品模块里用户已经维护的包含了危化品的数据
|
|
|
- Object[] obj = (Object[]) dao.getObjectBySql("select * from iedg_sync_chemicals_ciq where CIQ_CODE = ?", (String) codeTs[16]);
|
|
|
+ Object[] obj = (Object[]) iedgRepository.getObjectBySql("select * from iedg_sync_chemicals_ciq where CIQ_CODE = ?", (String) codeTs[16]);
|
|
|
if (obj != null) {
|
|
|
if (codeTs[16] != null) {
|
|
|
entity.setGoodsType("1,2,3");
|
|
|
@@ -1810,6 +1812,7 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
e.setPreReleaseDate(preReleaseDate);// 81时间
|
|
|
e.setPassMode("2");// 一体化通关
|
|
|
e.setDeclPort(declPort);
|
|
|
+ e.setCustomsCode(rootCustomsMap.get(declPort));
|
|
|
e.setIePort(iePort);
|
|
|
e.setIeDate(ieDate);
|
|
|
e.setDeclDate(declDate);
|
|
|
@@ -1996,7 +1999,7 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
e.setManChkTimeEnd(manChkTimeEnd);//查验结束时间
|
|
|
e.setManProcResult(manProcResult);
|
|
|
e.setManProcIdea(manProcIdea);
|
|
|
- e.setCheckCustomsCode(checkCustomsCode);
|
|
|
+ e.setCheckCustomsCode(rootCustomsMap.get(checkCustomsCode));
|
|
|
dao.executeUpdate("delete from WXJY_ENTRY_HEAD where ENTRY_ID = ?", entryId);
|
|
|
entryHeadRepository.save(e);
|
|
|
|
|
|
@@ -2076,7 +2079,7 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
if (ieFlag.equals("0")) {
|
|
|
if (codeTs[16] != null) {
|
|
|
//syncChemicalsCiq只可能是包含了危化品,因为这个表的数据就是查询的系统中危险品模块里用户已经维护的包含了危化品的数据
|
|
|
- Object[] obj = (Object[]) dao.getObjectBySql("select * from iedg_sync_chemicals_ciq where CIQ_CODE = ?", (String) codeTs[16]);
|
|
|
+ Object[] obj = (Object[]) iedgRepository.getObjectBySql("select * from iedg_sync_chemicals_ciq where CIQ_CODE = ?", (String) codeTs[16]);
|
|
|
if (obj != null) {
|
|
|
if (codeTs[16] != null) {
|
|
|
entity.setGoodsType("1,2,3");
|
|
|
@@ -2807,41 +2810,42 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
String customCodeT = (String) s[2];
|
|
|
if (customCode.equals(customCodeT)) {// 找到了既是唯一一条
|
|
|
CustomMonthlyStatFinal stat = new CustomMonthlyStatFinal();
|
|
|
+ stat.setCustomCode(customCodeT);
|
|
|
stat.setMonth((String) s[1]);
|
|
|
- stat.setImpDeclCount(Integer.valueOf(((BigDecimal) s[2]).toString()));
|
|
|
- stat.setImpManDeclCount(Integer.valueOf(((BigDecimal) s[3]).toString()));
|
|
|
- stat.setImpManualAuditDeclCount(Integer.valueOf(((BigDecimal) s[4]).toString()));
|
|
|
- stat.setImpDeclCountLastMonth(Integer.valueOf(((BigDecimal) s[5]).toString()));
|
|
|
- stat.setImpDeclCountLastYearDecember(Integer.valueOf(((BigDecimal) s[6]).toString()));
|
|
|
- stat.setImpDeclCountCurentYear(Integer.valueOf(((BigDecimal) s[7]).toString()));
|
|
|
- stat.setImpDeclCountYearBeforeLast(Integer.valueOf(((BigDecimal) s[8]).toString()));
|
|
|
- stat.setImpTotalCost((BigDecimal) s[9]);
|
|
|
- stat.setImpTotalCostLastMonth((BigDecimal) s[10]);
|
|
|
- stat.setImpTotalCostLastYearDecember((BigDecimal) s[11]);
|
|
|
- stat.setImpTotalCostCurentYear((BigDecimal) s[12]);
|
|
|
- stat.setImpTotalCostYearBeforeLast((BigDecimal) s[13]);
|
|
|
- stat.setImpCuCost((BigDecimal) s[14]);
|
|
|
- stat.setImpCuCostLastMonth((BigDecimal) s[15]);
|
|
|
- stat.setImpCuCostLastYearDecember((BigDecimal) s[16]);
|
|
|
- stat.setImpCuCostCurentYear((BigDecimal) s[17]);
|
|
|
- stat.setImpCuCostYearBeforeLast((BigDecimal) s[18]);
|
|
|
- stat.setExpDeclCount(Integer.valueOf(((BigDecimal) s[19]).toString()));
|
|
|
- stat.setExpManDeclCount(Integer.valueOf(((BigDecimal) s[20]).toString()));
|
|
|
- stat.setExpManualAuditDeclCount(Integer.valueOf(((BigDecimal) s[21]).toString()));
|
|
|
- stat.setExpDeclCountLastMonth(Integer.valueOf(((BigDecimal) s[22]).toString()));
|
|
|
- stat.setExpDeclCountLastYearDecember(Integer.valueOf(((BigDecimal) s[23]).toString()));
|
|
|
- stat.setExpDeclCountCurentYear(Integer.valueOf(((BigDecimal) s[24]).toString()));
|
|
|
- stat.setExpDeclCountYearBeforeLast(Integer.valueOf(((BigDecimal) s[25]).toString()));
|
|
|
- stat.setExpTotalCost((BigDecimal) s[26]);
|
|
|
- stat.setExpTotalCostLastMonth((BigDecimal) s[27]);
|
|
|
- stat.setExpTotalCostLastYearDecember((BigDecimal) s[28]);
|
|
|
- stat.setExpTotalCostCurentYear((BigDecimal) s[29]);
|
|
|
- stat.setExpTotalCostYearBeforeLast((BigDecimal) s[30]);
|
|
|
- stat.setExpCuCost((BigDecimal) s[31]);
|
|
|
- stat.setExpCuCostLastMonth((BigDecimal) s[32]);
|
|
|
- stat.setExpCuCostLastYearDecember((BigDecimal) s[33]);
|
|
|
- stat.setExpCuCostCurentYear((BigDecimal) s[34]);
|
|
|
- stat.setExpCuCostYearBeforeLast((BigDecimal) s[35]);
|
|
|
+ stat.setImpDeclCount(Integer.valueOf(((BigDecimal) s[3]).intValue()));
|
|
|
+ stat.setImpManDeclCount(Integer.valueOf(((BigDecimal) s[4]).intValue()));
|
|
|
+ stat.setImpManualAuditDeclCount(Integer.valueOf(((BigDecimal) s[5]).intValue()));
|
|
|
+ stat.setImpDeclCountLastMonth(Integer.valueOf(((BigDecimal) s[6]).intValue()));
|
|
|
+ stat.setImpDeclCountLastYearDecember(Integer.valueOf(((BigDecimal) s[7]).intValue()));
|
|
|
+ stat.setImpDeclCountCurentYear(Integer.valueOf(((BigDecimal) s[8]).intValue()));
|
|
|
+ stat.setImpDeclCountYearBeforeLast(Integer.valueOf(((BigDecimal) s[9]).intValue()));
|
|
|
+ stat.setImpTotalCost((BigDecimal) s[10]);
|
|
|
+ stat.setImpTotalCostLastMonth((BigDecimal) s[11]);
|
|
|
+ stat.setImpTotalCostLastYearDecember((BigDecimal) s[12]);
|
|
|
+ stat.setImpTotalCostCurentYear((BigDecimal) s[13]);
|
|
|
+ stat.setImpTotalCostYearBeforeLast((BigDecimal) s[14]);
|
|
|
+ stat.setImpCuCost((BigDecimal) s[15]);
|
|
|
+ stat.setImpCuCostLastMonth((BigDecimal) s[16]);
|
|
|
+ stat.setImpCuCostLastYearDecember((BigDecimal) s[17]);
|
|
|
+ stat.setImpCuCostCurentYear((BigDecimal) s[18]);
|
|
|
+ stat.setImpCuCostYearBeforeLast((BigDecimal) s[19]);
|
|
|
+ stat.setExpDeclCount(Integer.valueOf(((BigDecimal) s[20]).intValue()));
|
|
|
+ stat.setExpManDeclCount(Integer.valueOf(((BigDecimal) s[21]).intValue()));
|
|
|
+ stat.setExpManualAuditDeclCount(Integer.valueOf(((BigDecimal) s[22]).intValue()));
|
|
|
+ stat.setExpDeclCountLastMonth(Integer.valueOf(((BigDecimal) s[23]).intValue()));
|
|
|
+ stat.setExpDeclCountLastYearDecember(Integer.valueOf(((BigDecimal) s[24]).intValue()));
|
|
|
+ stat.setExpDeclCountCurentYear(Integer.valueOf(((BigDecimal) s[25]).intValue()));
|
|
|
+ stat.setExpDeclCountYearBeforeLast(Integer.valueOf(((BigDecimal) s[26]).intValue()));
|
|
|
+ stat.setExpTotalCost((BigDecimal) s[27]);
|
|
|
+ stat.setExpTotalCostLastMonth((BigDecimal) s[28]);
|
|
|
+ stat.setExpTotalCostLastYearDecember((BigDecimal) s[29]);
|
|
|
+ stat.setExpTotalCostCurentYear((BigDecimal) s[30]);
|
|
|
+ stat.setExpTotalCostYearBeforeLast((BigDecimal) s[31]);
|
|
|
+ stat.setExpCuCost((BigDecimal) s[32]);
|
|
|
+ stat.setExpCuCostLastMonth((BigDecimal) s[33]);
|
|
|
+ stat.setExpCuCostLastYearDecember((BigDecimal) s[34]);
|
|
|
+ stat.setExpCuCostCurentYear((BigDecimal) s[35]);
|
|
|
+ stat.setExpCuCostYearBeforeLast((BigDecimal) s[36]);
|
|
|
stat.setId(dao.getGuidStringBySql());
|
|
|
customMonthlyStatFinalRepository.save(stat);
|
|
|
existData = true;
|
|
|
@@ -2883,10 +2887,10 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
monthSdf.format(lastMonthDate), customCode);
|
|
|
if (lastMonthData != null && lastMonthData.size() > 0) {
|
|
|
for (Object[] s : lastMonthData) {
|
|
|
- stat.setImpDeclCountLastMonth(Integer.valueOf(((BigDecimal) s[6]).toString()));
|
|
|
+ stat.setImpDeclCountLastMonth(Integer.valueOf(((BigDecimal) s[6]).intValue()));
|
|
|
stat.setImpCuCostLastMonth((BigDecimal) s[15]);
|
|
|
stat.setImpTotalCostLastMonth((BigDecimal) s[10]);
|
|
|
- stat.setExpDeclCountLastMonth(Integer.valueOf(((BigDecimal) s[22]).toString()));
|
|
|
+ stat.setExpDeclCountLastMonth(Integer.valueOf(((BigDecimal) s[22]).intValue()));
|
|
|
stat.setExpCuCostLastMonth((BigDecimal) s[31]);
|
|
|
stat.setExpTotalCostLastMonth((BigDecimal) s[26]);
|
|
|
|
|
|
@@ -2898,10 +2902,10 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
stat.setExpCuCostCurentYear(zero);
|
|
|
stat.setExpTotalCostCurentYear(zero);
|
|
|
// 去年12月也就是上个月
|
|
|
- stat.setImpDeclCountLastYearDecember(Integer.valueOf(((BigDecimal) s[3]).toString()));
|
|
|
+ stat.setImpDeclCountLastYearDecember(Integer.valueOf(((BigDecimal) s[3]).intValue()));
|
|
|
stat.setImpCuCostLastYearDecember((BigDecimal) s[14]);
|
|
|
stat.setImpTotalCostLastYearDecember((BigDecimal) s[9]);
|
|
|
- stat.setExpDeclCountLastYearDecember(Integer.valueOf(((BigDecimal) s[21]).toString()));
|
|
|
+ stat.setExpDeclCountLastYearDecember(Integer.valueOf(((BigDecimal) s[21]).intValue()));
|
|
|
stat.setExpCuCostLastYearDecember((BigDecimal) s[30]);
|
|
|
stat.setExpTotalCostLastYearDecember((BigDecimal) s[25]);
|
|
|
// 前年平均值需要重新查询&计算
|
|
|
@@ -2928,7 +2932,7 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
BigDecimal sumExpTotalCostYBL = new BigDecimal(0);
|
|
|
|
|
|
for (Object[] t : yearBeforeLastData) {
|
|
|
- Integer impCount = Integer.valueOf(((BigDecimal) t[3]).toString());
|
|
|
+ Integer impCount = Integer.valueOf(((BigDecimal) t[3]).intValue());
|
|
|
if (impCount != null && impCount != 0) {
|
|
|
sumImpDeclCountYBL += impCount;
|
|
|
BigDecimal mul = new BigDecimal(impCount);
|
|
|
@@ -2943,7 +2947,7 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- Integer expCount = Integer.valueOf(((BigDecimal) t[21]).toString());
|
|
|
+ Integer expCount = Integer.valueOf(((BigDecimal) t[21]).intValue());
|
|
|
if (expCount != null && expCount != 0) {
|
|
|
sumExpDeclCountYBL += expCount;
|
|
|
BigDecimal mul = new BigDecimal(expCount);
|
|
|
@@ -2999,24 +3003,24 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
stat.setExpTotalCostYearBeforeLast(zero);
|
|
|
}
|
|
|
} else {
|
|
|
- stat.setImpDeclCountCurentYear(Integer.valueOf(((BigDecimal) s[8]).toString()));
|
|
|
+ stat.setImpDeclCountCurentYear(Integer.valueOf(((BigDecimal) s[8]).intValue()));
|
|
|
stat.setImpCuCostCurentYear((BigDecimal) s[17]);
|
|
|
stat.setImpTotalCostCurentYear((BigDecimal) s[12]);
|
|
|
- stat.setExpDeclCountCurentYear(Integer.valueOf(((BigDecimal) s[24]).toString()));
|
|
|
+ stat.setExpDeclCountCurentYear(Integer.valueOf(((BigDecimal) s[24]).intValue()));
|
|
|
stat.setExpCuCostCurentYear((BigDecimal) s[33]);
|
|
|
stat.setExpTotalCostCurentYear((BigDecimal) s[28]);
|
|
|
// 去年12月数据是上个月对应字段的值
|
|
|
- stat.setImpDeclCountLastYearDecember(Integer.valueOf(((BigDecimal) s[7]).toString()));
|
|
|
+ stat.setImpDeclCountLastYearDecember(Integer.valueOf(((BigDecimal) s[7]).intValue()));
|
|
|
stat.setImpCuCostLastYearDecember((BigDecimal) s[16]);
|
|
|
stat.setImpTotalCostLastYearDecember((BigDecimal) s[11]);
|
|
|
- stat.setExpDeclCountLastYearDecember(Integer.valueOf(((BigDecimal) s[23]).toString()));
|
|
|
+ stat.setExpDeclCountLastYearDecember(Integer.valueOf(((BigDecimal) s[23]).intValue()));
|
|
|
stat.setExpCuCostLastYearDecember((BigDecimal) s[32]);
|
|
|
stat.setExpTotalCostLastYearDecember((BigDecimal) s[27]);
|
|
|
|
|
|
- stat.setImpDeclCountYearBeforeLast(Integer.valueOf(((BigDecimal) s[9]).toString()));
|
|
|
+ stat.setImpDeclCountYearBeforeLast(Integer.valueOf(((BigDecimal) s[9]).intValue()));
|
|
|
stat.setImpCuCostYearBeforeLast((BigDecimal) s[18]);
|
|
|
stat.setImpTotalCostYearBeforeLast((BigDecimal) s[13]);
|
|
|
- stat.setExpDeclCountYearBeforeLast(Integer.valueOf(((BigDecimal) s[25]).toString()));
|
|
|
+ stat.setExpDeclCountYearBeforeLast(Integer.valueOf(((BigDecimal) s[25]).intValue()));
|
|
|
stat.setExpCuCostYearBeforeLast((BigDecimal) s[34]);
|
|
|
stat.setExpTotalCostYearBeforeLast((BigDecimal) s[29]);
|
|
|
}
|
|
|
@@ -3094,23 +3098,23 @@ public class H2018ZhOldDangerGoodsUtil {
|
|
|
|
|
|
for (Object[] s : copyList) {
|
|
|
if (customCode.equals((String) s[2])) {
|
|
|
- sumImpDeclCount += Integer.valueOf(((BigDecimal) s[3]).toString());
|
|
|
- sumImpManDeclCount += Integer.valueOf(((BigDecimal) s[4]).toString());
|
|
|
- sumImpAuditDeclCount += Integer.valueOf(((BigDecimal) s[5]).toString());
|
|
|
- sumImpDeclCountLastMonth += s[6] != null ? Integer.valueOf(((BigDecimal) s[6]).toString()) : 0;
|
|
|
- sumImpDeclCountLastYearDecember += s[7] != null ? Integer.valueOf(((BigDecimal) s[7]).toString())
|
|
|
+ sumImpDeclCount += Integer.valueOf(((BigDecimal) s[3]).intValue());
|
|
|
+ sumImpManDeclCount += Integer.valueOf(((BigDecimal) s[4]).intValue());
|
|
|
+ sumImpAuditDeclCount += Integer.valueOf(((BigDecimal) s[5]).intValue());
|
|
|
+ sumImpDeclCountLastMonth += s[6] != null ? Integer.valueOf(((BigDecimal) s[6]).intValue()) : 0;
|
|
|
+ sumImpDeclCountLastYearDecember += s[7] != null ? Integer.valueOf(((BigDecimal) s[7]).intValue())
|
|
|
: 0;
|
|
|
- sumImpDeclCountCurentYear += s[8] != null ? Integer.valueOf(((BigDecimal) s[8]).toString()) : 0;
|
|
|
- sumImpDeclCountYearBeforeLast += s[9] != null ? Integer.valueOf(((BigDecimal) s[9]).toString()) : 0;
|
|
|
-
|
|
|
- sumExpDeclCount += Integer.valueOf(((BigDecimal) s[20]).toString());
|
|
|
- sumExpManDeclCount += Integer.valueOf(((BigDecimal) s[21]).toString());
|
|
|
- sumExpAuditDeclCount += Integer.valueOf(((BigDecimal) s[22]).toString());
|
|
|
- sumExpDeclCountLastMonth += s[23] != null ? Integer.valueOf(((BigDecimal) s[23]).toString()) : 0;
|
|
|
- sumExpDeclCountLastYearDecember += s[24] != null ? Integer.valueOf(((BigDecimal) s[24]).toString())
|
|
|
+ sumImpDeclCountCurentYear += s[8] != null ? Integer.valueOf(((BigDecimal) s[8]).intValue()) : 0;
|
|
|
+ sumImpDeclCountYearBeforeLast += s[9] != null ? Integer.valueOf(((BigDecimal) s[9]).intValue()) : 0;
|
|
|
+
|
|
|
+ sumExpDeclCount += Integer.valueOf(((BigDecimal) s[20]).intValue());
|
|
|
+ sumExpManDeclCount += Integer.valueOf(((BigDecimal) s[21]).intValue());
|
|
|
+ sumExpAuditDeclCount += Integer.valueOf(((BigDecimal) s[22]).intValue());
|
|
|
+ sumExpDeclCountLastMonth += s[23] != null ? Integer.valueOf(((BigDecimal) s[23]).intValue()) : 0;
|
|
|
+ sumExpDeclCountLastYearDecember += s[24] != null ? Integer.valueOf(((BigDecimal) s[24]).intValue())
|
|
|
: 0;
|
|
|
- sumExpDeclCountCurentYear += s[25] != null ? Integer.valueOf(((BigDecimal) s[25]).toString()) : 0;
|
|
|
- sumExpDeclCountYearBeforeLast += s[26] != null ? Integer.valueOf(((BigDecimal) s[26]).toString()) : 0;
|
|
|
+ sumExpDeclCountCurentYear += s[25] != null ? Integer.valueOf(((BigDecimal) s[25]).intValue()) : 0;
|
|
|
+ sumExpDeclCountYearBeforeLast += s[26] != null ? Integer.valueOf(((BigDecimal) s[26]).intValue()) : 0;
|
|
|
|
|
|
BigDecimal impCurMonthMultiply = (BigDecimal) s[3];
|
|
|
BigDecimal impLastMonthMultiply = s[6] != null ? (BigDecimal) s[6] : new BigDecimal(0);
|