diff --git a/dxhy-core/src/main/java/com/dxhy/core/service/export/impl/FpzhcxmxServiceImpl.java b/dxhy-core/src/main/java/com/dxhy/core/service/export/impl/FpzhcxmxServiceImpl.java index 5bd3aaf6..2def332b 100644 --- a/dxhy-core/src/main/java/com/dxhy/core/service/export/impl/FpzhcxmxServiceImpl.java +++ b/dxhy-core/src/main/java/com/dxhy/core/service/export/impl/FpzhcxmxServiceImpl.java @@ -17,12 +17,10 @@ import com.dxhy.common.datasource.config.DynamicContextHolder; import com.dxhy.common.service.DictdetaServcice; import com.dxhy.common.service.impl.MpBaseServiceImpl; import com.dxhy.common.util.MathUtil; -import com.dxhy.common.vo.DictdetaModel; import com.dxhy.core.dao.BbfpzhmxDao; import com.dxhy.core.dao.InvoiceDetailDao; import com.dxhy.core.model.BbfpzhmxcxRespVO; import com.dxhy.core.service.export.FpzhcxmxService; -import com.dxhy.core.util.InvoiceTypeUtils; import com.github.pagehelper.PageHelper; import com.github.pagehelper.PageInfo; @@ -57,9 +55,9 @@ public class FpzhcxmxServiceImpl extends MpBaseServiceImpl gfshList = (List)pramsMap.get("gfsh"); + String gfsh = (String) pramsMap.get("gfsh"); String inAccountStatus = (String)pramsMap.get("inAccountStatus"); - if (gfshList.size() == 0) { + if (StringUtils.isBlank(gfsh)) { // 未从getUserInfo()获取到购方税号信息 json.put("hjsl", "0"); json.put("hjje", "0"); diff --git a/dxhy-core/src/main/java/com/dxhy/core/thread/FpzhcxmxExportThread.java b/dxhy-core/src/main/java/com/dxhy/core/thread/FpzhcxmxExportThread.java index f248d0a8..f124f603 100644 --- a/dxhy-core/src/main/java/com/dxhy/core/thread/FpzhcxmxExportThread.java +++ b/dxhy-core/src/main/java/com/dxhy/core/thread/FpzhcxmxExportThread.java @@ -112,6 +112,7 @@ public class FpzhcxmxExportThread extends BaseThread { // 应该保存的参数 JSONObject prams = JSONObject.parseObject(condition); String gfsh = prams.getString("gfsh"); + String companyCode = prams.getString("companyCode"); String kpksrq = prams.getString("kpksrq"); String kpjsrq = prams.getString("kpjsrq"); String invoiceType = prams.getString("invoiceType"); @@ -139,6 +140,7 @@ public class FpzhcxmxExportThread extends BaseThread { pramsMap.put("dbName", dbName); pramsMap.put("business", businesses); pramsMap.put("gfsh", gfsh); + pramsMap.put("companyCode",companyCode); if (!StringHelper.isBlank(invoiceType)) { if (!"99".equals(invoiceType)) { pramsMap.put("invoiceType", invoiceType); diff --git a/dxhy-core/src/main/java/com/dxhy/core/thread/FpzhcxslExportThread.java b/dxhy-core/src/main/java/com/dxhy/core/thread/FpzhcxslExportThread.java index 4d3cef9f..1599d984 100644 --- a/dxhy-core/src/main/java/com/dxhy/core/thread/FpzhcxslExportThread.java +++ b/dxhy-core/src/main/java/com/dxhy/core/thread/FpzhcxslExportThread.java @@ -109,6 +109,7 @@ public class FpzhcxslExportThread extends BaseThread { // 应该保存的参数 JSONObject prams = JSONObject.parseObject(condition); String gfsh = prams.getString("gfsh"); + String companyCode = prams.getString("companyCode"); String kpksrq = prams.getString("kpksrq"); String kpjsrq = prams.getString("kpjsrq"); String invoiceType = prams.getString("invoiceType"); @@ -136,6 +137,7 @@ public class FpzhcxslExportThread extends BaseThread { pramsMap.put("dbName", dbName); pramsMap.put("business", businesses); pramsMap.put("gfsh", gfsh); + pramsMap.put("companyCode",companyCode); if (!StringHelper.isBlank(invoiceType)) { if (!"99".equals(invoiceType)) { pramsMap.put("invoiceType", invoiceType); diff --git a/dxhy-core/src/main/resources/mapper/BbfpzhmxMapper.xml b/dxhy-core/src/main/resources/mapper/BbfpzhmxMapper.xml index 7a1efb90..8161c375 100644 --- a/dxhy-core/src/main/resources/mapper/BbfpzhmxMapper.xml +++ b/dxhy-core/src/main/resources/mapper/BbfpzhmxMapper.xml @@ -53,6 +53,7 @@ left JOIN ${dxhyDetail}.t_dx_record_invoice_detail b ON t.uuid = b.uuid WHERE t.invoice_date between #{kpksrq} and #{kpjsrq} and t.gf_tax_no = #{gfsh} + and t.comp_code = #{companyCode} and t.invoice_status = #{invoiceStatus}