From baae63153a2522cb573eacbdbb3b15052515a669 Mon Sep 17 00:00:00 2001 From: "UNISINSIGHT\\rdpnr_jiangpeng" Date: Mon, 30 Mar 2026 14:52:13 +0800 Subject: [PATCH] =?UTF-8?q?fix=EF=BC=9A=E4=BA=A7=E5=93=81=E4=BA=8C?= =?UTF-8?q?=E7=BA=A7=E7=B1=BB=E5=9E=8B=E7=9B=B8=E5=85=B3=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/ruoyi/sip/domain/OmsPayableBill.java | 2 ++ .../impl/OmsFinanceChargeServiceImpl.java | 23 +++++++++---------- .../mapper/finance/OmsPayableBillMapper.xml | 17 ++++++++------ 3 files changed, 23 insertions(+), 19 deletions(-) diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsPayableBill.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsPayableBill.java index cf09f9f1..22dd8733 100644 --- a/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsPayableBill.java +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsPayableBill.java @@ -59,6 +59,8 @@ public class OmsPayableBill extends BaseEntity /** 产品类型 */ @Excel(name = "产品类型") private String productType; + /** 二级产品类型 */ + private String productLevel2Type; /** 产品编码 */ private String productCode; diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsFinanceChargeServiceImpl.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsFinanceChargeServiceImpl.java index 9f02f34a..5c25826d 100644 --- a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsFinanceChargeServiceImpl.java +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsFinanceChargeServiceImpl.java @@ -194,18 +194,17 @@ public class OmsFinanceChargeServiceImpl implements IOmsFinanceChargeService { queryBill.setOrderCode(omsFinanceCharge.getOrderCode()); List omsPayableBills = payableBillService.selectOmsPayableBillList(queryBill); for (OmsPayableBill omsPayableBill : omsPayableBills) { - if (omsPayableBill.getProductType().equals(ProductInfo.ProductTypeEnum.SOFTWARE_MAINTENANCE.getType())){ - costSoftwareMaintWithTax = costSoftwareMaintWithTax.add(omsPayableBill.getTotalPriceWithTax()); - costSoftwareMaintWithoutTax = costSoftwareMaintWithoutTax.add(omsPayableBill.getTotalPriceWithoutTax()); - }else if (omsPayableBill.getProductType().equals(ProductInfo.ProductTypeEnum.HARDWARE_MAINTENANCE.getType())){ - costHardwareMaintWithTax = costHardwareMaintWithTax.add(omsPayableBill.getTotalPriceWithTax()); - costHardwareMaintWithoutTax = costHardwareMaintWithoutTax.add(omsPayableBill.getTotalPriceWithoutTax()); - }else if (omsPayableBill.getProductType().equals(ProductInfo.ProductTypeEnum.PROVINCE_SERVICE.getType())){ - costProvinceServiceWithTax = costProvinceServiceWithTax.add(omsPayableBill.getTotalPriceWithTax()); - costProvinceServiceWithoutTax = costProvinceServiceWithoutTax.add(omsPayableBill.getTotalPriceWithoutTax()); - }else if (omsPayableBill.getProductType().equals(ProductInfo.ProductTypeEnum.OTHER.getType())){ - costOtherWithTax = costOtherWithTax.add(omsPayableBill.getTotalPriceWithTax()); - costOtherWithoutTax = costOtherWithoutTax.add(omsPayableBill.getTotalPriceWithoutTax()); + if (omsPayableBill.getProductType().equals(ProductInfo.ProductTypeEnum.SERVICE.getType())) { + if (ProductInfo.ProductTypeLevel2ServiceEnum.SOFTWARE_QA.getType().equals((omsPayableBill.getProductLevel2Type()))) { + costSoftwareMaintWithTax = costSoftwareMaintWithTax.add(omsPayableBill.getTotalPriceWithTax()); + costSoftwareMaintWithoutTax = costSoftwareMaintWithoutTax.add(omsPayableBill.getTotalPriceWithoutTax()); + } else if (ProductInfo.ProductTypeLevel2ServiceEnum.HARDWARE_QA.getType().equals((omsPayableBill.getProductLevel2Type()))) { + costHardwareMaintWithTax = costHardwareMaintWithTax.add(omsPayableBill.getTotalPriceWithTax()); + costHardwareMaintWithoutTax = costHardwareMaintWithoutTax.add(omsPayableBill.getTotalPriceWithoutTax()); + } else if (ProductInfo.ProductTypeLevel2ServiceEnum.SHENG_DAI.getType().equals((omsPayableBill.getProductLevel2Type()))) { + costProvinceServiceWithTax = costProvinceServiceWithTax.add(omsPayableBill.getTotalPriceWithTax()); + costProvinceServiceWithoutTax = costProvinceServiceWithoutTax.add(omsPayableBill.getTotalPriceWithoutTax()); + } } } omsFinanceCharge.setCostSoftwareMaintWithoutTax(costSoftwareMaintWithoutTax); diff --git a/ruoyi-sip/src/main/resources/mapper/finance/OmsPayableBillMapper.xml b/ruoyi-sip/src/main/resources/mapper/finance/OmsPayableBillMapper.xml index f8757f3a..f11c9ff7 100644 --- a/ruoyi-sip/src/main/resources/mapper/finance/OmsPayableBillMapper.xml +++ b/ruoyi-sip/src/main/resources/mapper/finance/OmsPayableBillMapper.xml @@ -11,6 +11,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" + @@ -63,7 +64,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" t1.vendor_code, t1.order_code, t1.inventory_code, - t1.product_type, t1.total_price_with_tax, t1.total_price_without_tax, t1.tax_amount, @@ -86,14 +86,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ppp.plan_payment_date, ppp.plan_amount, t5.plan_ticket_date, - t5.plan_amount as plan_ticket_amount + t5.plan_amount as plan_ticket_amount, + t6.type as product_type, + t6.level2_type as product_leve2_type FROM oms_payable_bill t1 - left join project_order_info t2 on t1.order_code=t2.order_code - left join project_info t3 on t2.project_id=t3.id - left join oms_vendor_info t4 on t1.vendor_code=t4.vendor_code - left join oms_payable_payment_plan ppp on t1.last_payment_plan_id = ppp.id - left join oms_payable_ticket_plan t5 on t1.last_ticket_plan_id = t5.id + left join project_order_info t2 on t1.order_code=t2.order_code + left join project_info t3 on t2.project_id=t3.id + left join oms_vendor_info t4 on t1.vendor_code=t4.vendor_code + left join oms_payable_payment_plan ppp on t1.last_payment_plan_id = ppp.id + left join oms_payable_ticket_plan t5 on t1.last_ticket_plan_id = t5.id + left join product_info t6 on t1.product_code = t6.product_code