From 6545b505826973c2078b6189bd267b370df24b6e Mon Sep 17 00:00:00 2001 From: chenhao Date: Wed, 22 Oct 2025 15:45:13 +0800 Subject: [PATCH] =?UTF-8?q?feat(finance):=20=E6=96=B0=E5=A2=9E=E9=87=87?= =?UTF-8?q?=E8=B4=AD=E6=94=B6=E7=A5=A8=E5=8D=95=E3=80=81=E5=BA=94=E4=BB=98?= =?UTF-8?q?=E5=8D=95=E3=80=81=E4=BB=98=E6=AC=BE=E5=8D=95=E5=8A=9F=E8=83=BD?= =?UTF-8?q?=E6=A8=A1=E5=9D=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 新增收票单、应付单、付款单的新增页面模板 - 新增收票单、应付单、付款单的编辑页面模板 - 新增收票单、应付单、付款单的列表查询页面模板- 新增收票单、应付单、付款单的后端服务接口定义 - 在库存信息实体中增加应付账单号字段并更新数据库映射 - 完善入库逻辑中的SN码重复校验功能 - 添加批量插入库存信息时对新增应付账单号的支持 --- .../templates/finance/invoice/add.html | 89 ++++++++ .../templates/finance/invoice/edit.html | 82 +++++++ .../templates/finance/invoice/invoice.html | 130 +++++++++++ .../templates/finance/payable/add.html | 132 +++++++++++ .../templates/finance/payable/edit.html | 125 +++++++++++ .../templates/finance/payable/payable.html | 212 ++++++++++++++++++ .../templates/finance/payment/add.html | 108 +++++++++ .../templates/finance/payment/edit.html | 101 +++++++++ .../templates/finance/payment/payment.html | 142 ++++++++++++ .../OmsInvoiceReceiptBillController.java | 128 +++++++++++ .../controller/OmsPayableBillController.java | 128 +++++++++++ .../controller/OmsPaymentBillController.java | 128 +++++++++++ .../com/ruoyi/sip/domain/InventoryInfo.java | 3 +- .../sip/domain/OmsInvoiceReceiptBill.java | 147 ++++++++++++ .../com/ruoyi/sip/domain/OmsPayableBill.java | 75 +++++++ .../com/ruoyi/sip/domain/OmsPaymentBill.java | 180 +++++++++++++++ .../mapper/OmsInvoiceReceiptBillMapper.java | 61 +++++ .../sip/mapper/OmsPayableBillMapper.java | 63 ++++++ .../sip/mapper/OmsPaymentBillMapper.java | 61 +++++ .../IOmsInvoiceReceiptBillService.java | 61 +++++ .../sip/service/IOmsPayableBillService.java | 61 +++++ .../sip/service/IOmsPaymentBillService.java | 61 +++++ .../impl/OmsInventoryInnerServiceImpl.java | 47 ++-- .../OmsInvoiceReceiptBillServiceImpl.java | 97 ++++++++ .../impl/OmsPayableBillServiceImpl.java | 115 ++++++++++ .../impl/OmsPaymentBillServiceImpl.java | 97 ++++++++ .../impl/ProjectOrderInfoServiceImpl.java | 35 +-- .../finance/OmsInvoiceReceiptBillMapper.xml | 106 +++++++++ .../mapper/finance/OmsPayableBillMapper.xml | 136 +++++++++++ .../mapper/finance/OmsPaymentBillMapper.xml | 116 ++++++++++ .../mapper/inventory/InventoryInfoMapper.xml | 6 +- 31 files changed, 3002 insertions(+), 31 deletions(-) create mode 100644 ruoyi-admin/src/main/resources/templates/finance/invoice/add.html create mode 100644 ruoyi-admin/src/main/resources/templates/finance/invoice/edit.html create mode 100644 ruoyi-admin/src/main/resources/templates/finance/invoice/invoice.html create mode 100644 ruoyi-admin/src/main/resources/templates/finance/payable/add.html create mode 100644 ruoyi-admin/src/main/resources/templates/finance/payable/edit.html create mode 100644 ruoyi-admin/src/main/resources/templates/finance/payable/payable.html create mode 100644 ruoyi-admin/src/main/resources/templates/finance/payment/add.html create mode 100644 ruoyi-admin/src/main/resources/templates/finance/payment/edit.html create mode 100644 ruoyi-admin/src/main/resources/templates/finance/payment/payment.html create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/controller/OmsInvoiceReceiptBillController.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/controller/OmsPayableBillController.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/controller/OmsPaymentBillController.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsInvoiceReceiptBill.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsPayableBill.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsPaymentBill.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/mapper/OmsInvoiceReceiptBillMapper.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/mapper/OmsPayableBillMapper.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/mapper/OmsPaymentBillMapper.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/service/IOmsInvoiceReceiptBillService.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/service/IOmsPayableBillService.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/service/IOmsPaymentBillService.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsInvoiceReceiptBillServiceImpl.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsPayableBillServiceImpl.java create mode 100644 ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsPaymentBillServiceImpl.java create mode 100644 ruoyi-sip/src/main/resources/mapper/finance/OmsInvoiceReceiptBillMapper.xml create mode 100644 ruoyi-sip/src/main/resources/mapper/finance/OmsPayableBillMapper.xml create mode 100644 ruoyi-sip/src/main/resources/mapper/finance/OmsPaymentBillMapper.xml diff --git a/ruoyi-admin/src/main/resources/templates/finance/invoice/add.html b/ruoyi-admin/src/main/resources/templates/finance/invoice/add.html new file mode 100644 index 00000000..4e3a9198 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/finance/invoice/add.html @@ -0,0 +1,89 @@ + + + + + + +
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/finance/invoice/edit.html b/ruoyi-admin/src/main/resources/templates/finance/invoice/edit.html new file mode 100644 index 00000000..4cd88299 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/finance/invoice/edit.html @@ -0,0 +1,82 @@ + + + + + + +
+
+ +
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/finance/invoice/invoice.html b/ruoyi-admin/src/main/resources/templates/finance/invoice/invoice.html new file mode 100644 index 00000000..0e3cb6e8 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/finance/invoice/invoice.html @@ -0,0 +1,130 @@ + + + + + + +
+
+
+
+
+
    +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • +  搜索 +  重置 +
  • +
+
+
+
+ + +
+
+
+
+
+ + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/finance/payable/add.html b/ruoyi-admin/src/main/resources/templates/finance/payable/add.html new file mode 100644 index 00000000..40fae60c --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/finance/payable/add.html @@ -0,0 +1,132 @@ + + + + + + + +
+
+
+
+ +
+ +
+
+
+
+
+ +
+
+ + +
+
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ + + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/finance/payable/edit.html b/ruoyi-admin/src/main/resources/templates/finance/payable/edit.html new file mode 100644 index 00000000..5d065251 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/finance/payable/edit.html @@ -0,0 +1,125 @@ + + + + + + + +
+
+ +
+
+ +
+ +
+
+
+
+
+ +
+
+ + +
+
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ + + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/finance/payable/payable.html b/ruoyi-admin/src/main/resources/templates/finance/payable/payable.html new file mode 100644 index 00000000..0a08c633 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/finance/payable/payable.html @@ -0,0 +1,212 @@ + + + + + + + + +
+
+
+
+
+
    +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • + +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • +
    + + +
    + - + +
    + +
    + +
  • +
  • +  搜索 +  重置 +
  • +
+
+
+
+ + +
+
+
+
+
+ + + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/finance/payment/add.html b/ruoyi-admin/src/main/resources/templates/finance/payment/add.html new file mode 100644 index 00000000..c9a567f7 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/finance/payment/add.html @@ -0,0 +1,108 @@ + + + + + + + +
+
+
+
+ +
+ +
+
+
+
+
+ +
+
+ + +
+
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ + + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/finance/payment/edit.html b/ruoyi-admin/src/main/resources/templates/finance/payment/edit.html new file mode 100644 index 00000000..b96c47a0 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/finance/payment/edit.html @@ -0,0 +1,101 @@ + + + + + + + +
+
+ +
+
+ +
+ +
+
+
+
+
+ +
+
+ + +
+
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
+
+ + + + + \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/finance/payment/payment.html b/ruoyi-admin/src/main/resources/templates/finance/payment/payment.html new file mode 100644 index 00000000..ee1f4704 --- /dev/null +++ b/ruoyi-admin/src/main/resources/templates/finance/payment/payment.html @@ -0,0 +1,142 @@ + + + + + + +
+
+
+
+
+
    +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
  • +  搜索 +  重置 +
  • +
+
+
+
+ + +
+
+
+
+
+ + + + \ No newline at end of file diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/controller/OmsInvoiceReceiptBillController.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/controller/OmsInvoiceReceiptBillController.java new file mode 100644 index 00000000..5ec9238f --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/controller/OmsInvoiceReceiptBillController.java @@ -0,0 +1,128 @@ +package com.ruoyi.sip.controller; + +import java.util.List; +import org.apache.shiro.authz.annotation.RequiresPermissions; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Controller; +import org.springframework.ui.ModelMap; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.ResponseBody; +import com.ruoyi.common.annotation.Log; +import com.ruoyi.common.enums.BusinessType; +import com.ruoyi.sip.domain.OmsInvoiceReceiptBill; +import com.ruoyi.sip.service.IOmsInvoiceReceiptBillService; +import com.ruoyi.common.core.controller.BaseController; +import com.ruoyi.common.core.domain.AjaxResult; +import com.ruoyi.common.utils.poi.ExcelUtil; +import com.ruoyi.common.core.page.TableDataInfo; + +/** + * 采购收票单Controller + * + * @author ruoyi + * @date 2025-10-22 + */ +@Controller +@RequestMapping("/finance/invoice") +public class OmsInvoiceReceiptBillController extends BaseController +{ + private String prefix = "finance/invoice"; + + @Autowired + private IOmsInvoiceReceiptBillService omsInvoiceReceiptBillService; + + @RequiresPermissions("finance:invoice:view") + @GetMapping() + public String invoice() + { + return prefix + "/invoice"; + } + + /** + * 查询采购收票单列表 + */ + @RequiresPermissions("finance:invoice:list") + @PostMapping("/list") + @ResponseBody + public TableDataInfo list(OmsInvoiceReceiptBill omsInvoiceReceiptBill) + { + startPage(); + List list = omsInvoiceReceiptBillService.selectOmsInvoiceReceiptBillList(omsInvoiceReceiptBill); + return getDataTable(list); + } + + /** + * 导出采购收票单列表 + */ + @RequiresPermissions("finance:invoice:export") + @Log(title = "采购收票单", businessType = BusinessType.EXPORT) + @PostMapping("/export") + @ResponseBody + public AjaxResult export(OmsInvoiceReceiptBill omsInvoiceReceiptBill) + { + List list = omsInvoiceReceiptBillService.selectOmsInvoiceReceiptBillList(omsInvoiceReceiptBill); + ExcelUtil util = new ExcelUtil(OmsInvoiceReceiptBill.class); + return util.exportExcel(list, "采购收票单数据"); + } + + /** + * 新增采购收票单 + */ + @RequiresPermissions("finance:invoice:add") + @GetMapping("/add") + public String add() + { + return prefix + "/add"; + } + + /** + * 新增保存采购收票单 + */ + @RequiresPermissions("finance:invoice:add") + @Log(title = "采购收票单", businessType = BusinessType.INSERT) + @PostMapping("/add") + @ResponseBody + public AjaxResult addSave(OmsInvoiceReceiptBill omsInvoiceReceiptBill) + { + return toAjax(omsInvoiceReceiptBillService.insertOmsInvoiceReceiptBill(omsInvoiceReceiptBill)); + } + + /** + * 修改采购收票单 + */ + @RequiresPermissions("finance:invoice:edit") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") Long id, ModelMap mmap) + { + OmsInvoiceReceiptBill omsInvoiceReceiptBill = omsInvoiceReceiptBillService.selectOmsInvoiceReceiptBillById(id); + mmap.put("omsInvoiceReceiptBill", omsInvoiceReceiptBill); + return prefix + "/edit"; + } + + /** + * 修改保存采购收票单 + */ + @RequiresPermissions("finance:invoice:edit") + @Log(title = "采购收票单", businessType = BusinessType.UPDATE) + @PostMapping("/edit") + @ResponseBody + public AjaxResult editSave(OmsInvoiceReceiptBill omsInvoiceReceiptBill) + { + return toAjax(omsInvoiceReceiptBillService.updateOmsInvoiceReceiptBill(omsInvoiceReceiptBill)); + } + + /** + * 删除采购收票单 + */ + @RequiresPermissions("finance:invoice:remove") + @Log(title = "采购收票单", businessType = BusinessType.DELETE) + @PostMapping( "/remove") + @ResponseBody + public AjaxResult remove(String ids) + { + return toAjax(omsInvoiceReceiptBillService.deleteOmsInvoiceReceiptBillByIds(ids)); + } +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/controller/OmsPayableBillController.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/controller/OmsPayableBillController.java new file mode 100644 index 00000000..8b450606 --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/controller/OmsPayableBillController.java @@ -0,0 +1,128 @@ +package com.ruoyi.sip.controller; + +import java.util.List; +import org.apache.shiro.authz.annotation.RequiresPermissions; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Controller; +import org.springframework.ui.ModelMap; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.ResponseBody; +import com.ruoyi.common.annotation.Log; +import com.ruoyi.common.enums.BusinessType; +import com.ruoyi.sip.domain.OmsPayableBill; +import com.ruoyi.sip.service.IOmsPayableBillService; +import com.ruoyi.common.core.controller.BaseController; +import com.ruoyi.common.core.domain.AjaxResult; +import com.ruoyi.common.utils.poi.ExcelUtil; +import com.ruoyi.common.core.page.TableDataInfo; + +/** + * 采购应付单Controller + * + * @author ruoyi + * @date 2025-10-22 + */ +@Controller +@RequestMapping("/finance/payable") +public class OmsPayableBillController extends BaseController +{ + private String prefix = "finance/payable"; + + @Autowired + private IOmsPayableBillService omsPayableBillService; + + @RequiresPermissions("finance:payable:view") + @GetMapping() + public String payable() + { + return prefix + "/payable"; + } + + /** + * 查询采购应付单列表 + */ + @RequiresPermissions("finance:payable:list") + @PostMapping("/list") + @ResponseBody + public TableDataInfo list(OmsPayableBill omsPayableBill) + { + startPage(); + List list = omsPayableBillService.selectOmsPayableBillList(omsPayableBill); + return getDataTable(list); + } + + /** + * 导出采购应付单列表 + */ + @RequiresPermissions("finance:payable:export") + @Log(title = "采购应付单", businessType = BusinessType.EXPORT) + @PostMapping("/export") + @ResponseBody + public AjaxResult export(OmsPayableBill omsPayableBill) + { + List list = omsPayableBillService.selectOmsPayableBillList(omsPayableBill); + ExcelUtil util = new ExcelUtil(OmsPayableBill.class); + return util.exportExcel(list, "采购应付单数据"); + } + + /** + * 新增采购应付单 + */ + @RequiresPermissions("finance:payable:add") + @GetMapping("/add") + public String add() + { + return prefix + "/add"; + } + + /** + * 新增保存采购应付单 + */ + @RequiresPermissions("finance:payable:add") + @Log(title = "采购应付单", businessType = BusinessType.INSERT) + @PostMapping("/add") + @ResponseBody + public AjaxResult addSave(OmsPayableBill omsPayableBill) + { + return toAjax(omsPayableBillService.insertOmsPayableBill(omsPayableBill)); + } + + /** + * 修改采购应付单 + */ + @RequiresPermissions("finance:payable:edit") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") Long id, ModelMap mmap) + { + OmsPayableBill omsPayableBill = omsPayableBillService.selectOmsPayableBillById(id); + mmap.put("omsPayableBill", omsPayableBill); + return prefix + "/edit"; + } + + /** + * 修改保存采购应付单 + */ + @RequiresPermissions("finance:payable:edit") + @Log(title = "采购应付单", businessType = BusinessType.UPDATE) + @PostMapping("/edit") + @ResponseBody + public AjaxResult editSave(OmsPayableBill omsPayableBill) + { + return toAjax(omsPayableBillService.updateOmsPayableBill(omsPayableBill)); + } + + /** + * 删除采购应付单 + */ + @RequiresPermissions("finance:payable:remove") + @Log(title = "采购应付单", businessType = BusinessType.DELETE) + @PostMapping( "/remove") + @ResponseBody + public AjaxResult remove(String ids) + { + return toAjax(omsPayableBillService.deleteOmsPayableBillByIds(ids)); + } +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/controller/OmsPaymentBillController.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/controller/OmsPaymentBillController.java new file mode 100644 index 00000000..111057bb --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/controller/OmsPaymentBillController.java @@ -0,0 +1,128 @@ +package com.ruoyi.sip.controller; + +import java.util.List; +import org.apache.shiro.authz.annotation.RequiresPermissions; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Controller; +import org.springframework.ui.ModelMap; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.ResponseBody; +import com.ruoyi.common.annotation.Log; +import com.ruoyi.common.enums.BusinessType; +import com.ruoyi.sip.domain.OmsPaymentBill; +import com.ruoyi.sip.service.IOmsPaymentBillService; +import com.ruoyi.common.core.controller.BaseController; +import com.ruoyi.common.core.domain.AjaxResult; +import com.ruoyi.common.utils.poi.ExcelUtil; +import com.ruoyi.common.core.page.TableDataInfo; + +/** + * 采购付款单Controller + * + * @author ruoyi + * @date 2025-10-22 + */ +@Controller +@RequestMapping("/finance/payment") +public class OmsPaymentBillController extends BaseController +{ + private String prefix = "finance/payment"; + + @Autowired + private IOmsPaymentBillService omsPaymentBillService; + + @RequiresPermissions("finance:payment:view") + @GetMapping() + public String payment() + { + return prefix + "/payment"; + } + + /** + * 查询采购付款单列表 + */ + @RequiresPermissions("finance:payment:list") + @PostMapping("/list") + @ResponseBody + public TableDataInfo list(OmsPaymentBill omsPaymentBill) + { + startPage(); + List list = omsPaymentBillService.selectOmsPaymentBillList(omsPaymentBill); + return getDataTable(list); + } + + /** + * 导出采购付款单列表 + */ + @RequiresPermissions("finance:payment:export") + @Log(title = "采购付款单", businessType = BusinessType.EXPORT) + @PostMapping("/export") + @ResponseBody + public AjaxResult export(OmsPaymentBill omsPaymentBill) + { + List list = omsPaymentBillService.selectOmsPaymentBillList(omsPaymentBill); + ExcelUtil util = new ExcelUtil(OmsPaymentBill.class); + return util.exportExcel(list, "采购付款单数据"); + } + + /** + * 新增采购付款单 + */ + @RequiresPermissions("finance:payment:add") + @GetMapping("/add") + public String add() + { + return prefix + "/add"; + } + + /** + * 新增保存采购付款单 + */ + @RequiresPermissions("finance:payment:add") + @Log(title = "采购付款单", businessType = BusinessType.INSERT) + @PostMapping("/add") + @ResponseBody + public AjaxResult addSave(OmsPaymentBill omsPaymentBill) + { + return toAjax(omsPaymentBillService.insertOmsPaymentBill(omsPaymentBill)); + } + + /** + * 修改采购付款单 + */ + @RequiresPermissions("finance:payment:edit") + @GetMapping("/edit/{id}") + public String edit(@PathVariable("id") Long id, ModelMap mmap) + { + OmsPaymentBill omsPaymentBill = omsPaymentBillService.selectOmsPaymentBillById(id); + mmap.put("omsPaymentBill", omsPaymentBill); + return prefix + "/edit"; + } + + /** + * 修改保存采购付款单 + */ + @RequiresPermissions("finance:payment:edit") + @Log(title = "采购付款单", businessType = BusinessType.UPDATE) + @PostMapping("/edit") + @ResponseBody + public AjaxResult editSave(OmsPaymentBill omsPaymentBill) + { + return toAjax(omsPaymentBillService.updateOmsPaymentBill(omsPaymentBill)); + } + + /** + * 删除采购付款单 + */ + @RequiresPermissions("finance:payment:remove") + @Log(title = "采购付款单", businessType = BusinessType.DELETE) + @PostMapping( "/remove") + @ResponseBody + public AjaxResult remove(String ids) + { + return toAjax(omsPaymentBillService.deleteOmsPaymentBillByIds(ids)); + } +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/InventoryInfo.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/InventoryInfo.java index af238706..fd5f5793 100644 --- a/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/InventoryInfo.java +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/InventoryInfo.java @@ -57,7 +57,8 @@ public class InventoryInfo extends BaseEntity /** 入库价 */ @Excel(name = "入库价") private BigDecimal innerPrice; - + /** 应付账单号 */ + private String payableBillCode; /** 出库价 */ @Excel(name = "出库价") private BigDecimal outerPrice; diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsInvoiceReceiptBill.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsInvoiceReceiptBill.java new file mode 100644 index 00000000..de30c8e4 --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsInvoiceReceiptBill.java @@ -0,0 +1,147 @@ +package com.ruoyi.sip.domain; + +import java.math.BigDecimal; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.ruoyi.common.annotation.Excel; +import com.ruoyi.common.core.domain.BaseEntity; + +/** + * 采购收票单对象 oms_invoice_receipt_bill + * + * @author ruoyi + * @date 2025-10-22 + */ +public class OmsInvoiceReceiptBill extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键ID */ + private Long id; + + /** 收票单编号 */ + @Excel(name = "收票单编号") + private String invoiceReceiptBillCode; + + /** 制造商名称 */ + @Excel(name = "制造商名称") + private String vendorCode; + + /** 合同编号 */ + @Excel(name = "合同编号") + private String orderCode; + + /** 含税总价 */ + @Excel(name = "含税总价") + private BigDecimal totalPriceWithTax; + + /** 未税总价 */ + @Excel(name = "未税总价") + private BigDecimal totalPriceWithoutTax; + + /** 税额 */ + @Excel(name = "税额") + private BigDecimal taxAmount; + + /** 删除标志(0代表存在 2代表删除) */ + private String delFlag; + + public void setId(Long id) + { + this.id = id; + } + + public Long getId() + { + return id; + } + + public void setInvoiceReceiptBillCode(String invoiceReceiptBillCode) + { + this.invoiceReceiptBillCode = invoiceReceiptBillCode; + } + + public String getInvoiceReceiptBillCode() + { + return invoiceReceiptBillCode; + } + + public void setVendorCode(String vendorCode) + { + this.vendorCode = vendorCode; + } + + public String getVendorCode() + { + return vendorCode; + } + + public void setOrderCode(String orderCode) + { + this.orderCode = orderCode; + } + + public String getOrderCode() + { + return orderCode; + } + + public void setTotalPriceWithTax(BigDecimal totalPriceWithTax) + { + this.totalPriceWithTax = totalPriceWithTax; + } + + public BigDecimal getTotalPriceWithTax() + { + return totalPriceWithTax; + } + + public void setTotalPriceWithoutTax(BigDecimal totalPriceWithoutTax) + { + this.totalPriceWithoutTax = totalPriceWithoutTax; + } + + public BigDecimal getTotalPriceWithoutTax() + { + return totalPriceWithoutTax; + } + + public void setTaxAmount(BigDecimal taxAmount) + { + this.taxAmount = taxAmount; + } + + public BigDecimal getTaxAmount() + { + return taxAmount; + } + + public void setDelFlag(String delFlag) + { + this.delFlag = delFlag; + } + + public String getDelFlag() + { + return delFlag; + } + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("invoiceReceiptBillCode", getInvoiceReceiptBillCode()) + .append("vendorCode", getVendorCode()) + .append("orderCode", getOrderCode()) + .append("totalPriceWithTax", getTotalPriceWithTax()) + .append("totalPriceWithoutTax", getTotalPriceWithoutTax()) + .append("taxAmount", getTaxAmount()) + .append("createBy", getCreateBy()) + .append("createTime", getCreateTime()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("remark", getRemark()) + .append("delFlag", getDelFlag()) + .toString(); + } +} 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 new file mode 100644 index 00000000..8cd7e074 --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsPayableBill.java @@ -0,0 +1,75 @@ +package com.ruoyi.sip.domain; + +import java.math.BigDecimal; +import java.util.Date; +import com.fasterxml.jackson.annotation.JsonFormat; +import lombok.*; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.ruoyi.common.annotation.Excel; +import com.ruoyi.common.core.domain.BaseEntity; + +/** + * 采购应付单对象 oms_payable_bill + * + * @author ruoyi + * @date 2025-10-22 + */ +@Data +@Builder +public class OmsPayableBill extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键ID */ + private Long id; + + /** 应付单编号 */ + @Excel(name = "应付单编号") + private String payableBillCode; + + /** 预计付款时间 */ + @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") + @Excel(name = "预计付款时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss") + private Date estimatedPaymentTime; + + /** 制造商编码 */ + @Excel(name = "制造商编码") + private String vendorCode; + + /** 合同编号 */ + @Excel(name = "合同编号") + private String orderCode; + + /** 入库/出库单号 */ + @Excel(name = "入库/出库单号") + private String inventoryCode; + + /** 产品类型 */ + @Excel(name = "产品类型") + private String productType; + + /** 含税总价 */ + @Excel(name = "含税总价") + private BigDecimal totalPriceWithTax; + + /** 未税总价 */ + @Excel(name = "未税总价") + private BigDecimal totalPriceWithoutTax; + + /** 税额 */ + @Excel(name = "税额") + private BigDecimal taxAmount; + + /** 关联的付款单ID */ + @Excel(name = "关联的付款单ID") + private Long paymentBillId; + + /** 关联的收票单ID */ + @Excel(name = "关联的收票单ID") + private Long invoiceReceiptBillId; + + /** 删除标志(0代表存在 2代表删除) */ + private String delFlag; + +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsPaymentBill.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsPaymentBill.java new file mode 100644 index 00000000..96ea9dd6 --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/domain/OmsPaymentBill.java @@ -0,0 +1,180 @@ +package com.ruoyi.sip.domain; + +import java.math.BigDecimal; +import java.util.Date; +import com.fasterxml.jackson.annotation.JsonFormat; +import org.apache.commons.lang3.builder.ToStringBuilder; +import org.apache.commons.lang3.builder.ToStringStyle; +import com.ruoyi.common.annotation.Excel; +import com.ruoyi.common.core.domain.BaseEntity; + +/** + * 采购付款单对象 oms_payment_bill + * + * @author ruoyi + * @date 2025-10-22 + */ +public class OmsPaymentBill extends BaseEntity +{ + private static final long serialVersionUID = 1L; + + /** 主键ID */ + private Long id; + + /** 付款单编号 */ + @Excel(name = "付款单编号") + private String paymentBillCode; + + /** 付款单类型 (FROM_PAYABLE, PRE_PAYMENT) */ + @Excel(name = "付款单类型 (FROM_PAYABLE, PRE_PAYMENT)") + private String paymentBillType; + + /** 付款时间 */ + @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") + @Excel(name = "付款时间", width = 30, dateFormat = "yyyy-MM-dd") + private Date paymentTime; + + /** 制造商名称 */ + @Excel(name = "制造商名称") + private String vendorCode; + + /** 合同编号 */ + @Excel(name = "合同编号") + private String orderCode; + + /** 含税总价 */ + @Excel(name = "含税总价") + private BigDecimal totalPriceWithTax; + + /** 未税总价 */ + @Excel(name = "未税总价") + private BigDecimal totalPriceWithoutTax; + + /** 税额 */ + @Excel(name = "税额") + private BigDecimal taxAmount; + + /** 删除标志(0代表存在 2代表删除) */ + private String delFlag; + + public void setId(Long id) + { + this.id = id; + } + + public Long getId() + { + return id; + } + + public void setPaymentBillCode(String paymentBillCode) + { + this.paymentBillCode = paymentBillCode; + } + + public String getPaymentBillCode() + { + return paymentBillCode; + } + + public void setPaymentBillType(String paymentBillType) + { + this.paymentBillType = paymentBillType; + } + + public String getPaymentBillType() + { + return paymentBillType; + } + + public void setPaymentTime(Date paymentTime) + { + this.paymentTime = paymentTime; + } + + public Date getPaymentTime() + { + return paymentTime; + } + + public void setVendorCode(String vendorCode) + { + this.vendorCode = vendorCode; + } + + public String getVendorCode() + { + return vendorCode; + } + + public void setOrderCode(String orderCode) + { + this.orderCode = orderCode; + } + + public String getOrderCode() + { + return orderCode; + } + + public void setTotalPriceWithTax(BigDecimal totalPriceWithTax) + { + this.totalPriceWithTax = totalPriceWithTax; + } + + public BigDecimal getTotalPriceWithTax() + { + return totalPriceWithTax; + } + + public void setTotalPriceWithoutTax(BigDecimal totalPriceWithoutTax) + { + this.totalPriceWithoutTax = totalPriceWithoutTax; + } + + public BigDecimal getTotalPriceWithoutTax() + { + return totalPriceWithoutTax; + } + + public void setTaxAmount(BigDecimal taxAmount) + { + this.taxAmount = taxAmount; + } + + public BigDecimal getTaxAmount() + { + return taxAmount; + } + + public void setDelFlag(String delFlag) + { + this.delFlag = delFlag; + } + + public String getDelFlag() + { + return delFlag; + } + + @Override + public String toString() { + return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) + .append("id", getId()) + .append("paymentBillCode", getPaymentBillCode()) + .append("paymentBillType", getPaymentBillType()) + .append("paymentTime", getPaymentTime()) + .append("vendorCode", getVendorCode()) + .append("orderCode", getOrderCode()) + .append("totalPriceWithTax", getTotalPriceWithTax()) + .append("totalPriceWithoutTax", getTotalPriceWithoutTax()) + .append("taxAmount", getTaxAmount()) + .append("createBy", getCreateBy()) + .append("createTime", getCreateTime()) + .append("updateBy", getUpdateBy()) + .append("updateTime", getUpdateTime()) + .append("remark", getRemark()) + .append("delFlag", getDelFlag()) + .toString(); + } +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/mapper/OmsInvoiceReceiptBillMapper.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/mapper/OmsInvoiceReceiptBillMapper.java new file mode 100644 index 00000000..ba0f2e23 --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/mapper/OmsInvoiceReceiptBillMapper.java @@ -0,0 +1,61 @@ +package com.ruoyi.sip.mapper; + +import java.util.List; +import com.ruoyi.sip.domain.OmsInvoiceReceiptBill; + +/** + * 采购收票单Mapper接口 + * + * @author ruoyi + * @date 2025-10-22 + */ +public interface OmsInvoiceReceiptBillMapper +{ + /** + * 查询采购收票单 + * + * @param id 采购收票单主键 + * @return 采购收票单 + */ + public OmsInvoiceReceiptBill selectOmsInvoiceReceiptBillById(Long id); + + /** + * 查询采购收票单列表 + * + * @param omsInvoiceReceiptBill 采购收票单 + * @return 采购收票单集合 + */ + public List selectOmsInvoiceReceiptBillList(OmsInvoiceReceiptBill omsInvoiceReceiptBill); + + /** + * 新增采购收票单 + * + * @param omsInvoiceReceiptBill 采购收票单 + * @return 结果 + */ + public int insertOmsInvoiceReceiptBill(OmsInvoiceReceiptBill omsInvoiceReceiptBill); + + /** + * 修改采购收票单 + * + * @param omsInvoiceReceiptBill 采购收票单 + * @return 结果 + */ + public int updateOmsInvoiceReceiptBill(OmsInvoiceReceiptBill omsInvoiceReceiptBill); + + /** + * 删除采购收票单 + * + * @param id 采购收票单主键 + * @return 结果 + */ + public int deleteOmsInvoiceReceiptBillById(Long id); + + /** + * 批量删除采购收票单 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteOmsInvoiceReceiptBillByIds(String[] ids); +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/mapper/OmsPayableBillMapper.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/mapper/OmsPayableBillMapper.java new file mode 100644 index 00000000..2e37be96 --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/mapper/OmsPayableBillMapper.java @@ -0,0 +1,63 @@ +package com.ruoyi.sip.mapper; + +import java.util.List; +import com.ruoyi.sip.domain.OmsPayableBill; + +/** + * 采购应付单Mapper接口 + * + * @author ruoyi + * @date 2025-10-22 + */ +public interface OmsPayableBillMapper +{ + /** + * 查询采购应付单 + * + * @param id 采购应付单主键 + * @return 采购应付单 + */ + public OmsPayableBill selectOmsPayableBillById(Long id); + + /** + * 查询采购应付单列表 + * + * @param omsPayableBill 采购应付单 + * @return 采购应付单集合 + */ + public List selectOmsPayableBillList(OmsPayableBill omsPayableBill); + + /** + * 新增采购应付单 + * + * @param omsPayableBill 采购应付单 + * @return 结果 + */ + public int insertOmsPayableBill(OmsPayableBill omsPayableBill); + + /** + * 修改采购应付单 + * + * @param omsPayableBill 采购应付单 + * @return 结果 + */ + public int updateOmsPayableBill(OmsPayableBill omsPayableBill); + + /** + * 删除采购应付单 + * + * @param id 采购应付单主键 + * @return 结果 + */ + public int deleteOmsPayableBillById(Long id); + + /** + * 批量删除采购应付单 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteOmsPayableBillByIds(String[] ids); + + Integer selectMaxCodeByPrefix(String codePrefix); +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/mapper/OmsPaymentBillMapper.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/mapper/OmsPaymentBillMapper.java new file mode 100644 index 00000000..319776f7 --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/mapper/OmsPaymentBillMapper.java @@ -0,0 +1,61 @@ +package com.ruoyi.sip.mapper; + +import java.util.List; +import com.ruoyi.sip.domain.OmsPaymentBill; + +/** + * 采购付款单Mapper接口 + * + * @author ruoyi + * @date 2025-10-22 + */ +public interface OmsPaymentBillMapper +{ + /** + * 查询采购付款单 + * + * @param id 采购付款单主键 + * @return 采购付款单 + */ + public OmsPaymentBill selectOmsPaymentBillById(Long id); + + /** + * 查询采购付款单列表 + * + * @param omsPaymentBill 采购付款单 + * @return 采购付款单集合 + */ + public List selectOmsPaymentBillList(OmsPaymentBill omsPaymentBill); + + /** + * 新增采购付款单 + * + * @param omsPaymentBill 采购付款单 + * @return 结果 + */ + public int insertOmsPaymentBill(OmsPaymentBill omsPaymentBill); + + /** + * 修改采购付款单 + * + * @param omsPaymentBill 采购付款单 + * @return 结果 + */ + public int updateOmsPaymentBill(OmsPaymentBill omsPaymentBill); + + /** + * 删除采购付款单 + * + * @param id 采购付款单主键 + * @return 结果 + */ + public int deleteOmsPaymentBillById(Long id); + + /** + * 批量删除采购付款单 + * + * @param ids 需要删除的数据主键集合 + * @return 结果 + */ + public int deleteOmsPaymentBillByIds(String[] ids); +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/IOmsInvoiceReceiptBillService.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/IOmsInvoiceReceiptBillService.java new file mode 100644 index 00000000..2cf884ee --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/IOmsInvoiceReceiptBillService.java @@ -0,0 +1,61 @@ +package com.ruoyi.sip.service; + +import java.util.List; +import com.ruoyi.sip.domain.OmsInvoiceReceiptBill; + +/** + * 采购收票单Service接口 + * + * @author ruoyi + * @date 2025-10-22 + */ +public interface IOmsInvoiceReceiptBillService +{ + /** + * 查询采购收票单 + * + * @param id 采购收票单主键 + * @return 采购收票单 + */ + public OmsInvoiceReceiptBill selectOmsInvoiceReceiptBillById(Long id); + + /** + * 查询采购收票单列表 + * + * @param omsInvoiceReceiptBill 采购收票单 + * @return 采购收票单集合 + */ + public List selectOmsInvoiceReceiptBillList(OmsInvoiceReceiptBill omsInvoiceReceiptBill); + + /** + * 新增采购收票单 + * + * @param omsInvoiceReceiptBill 采购收票单 + * @return 结果 + */ + public int insertOmsInvoiceReceiptBill(OmsInvoiceReceiptBill omsInvoiceReceiptBill); + + /** + * 修改采购收票单 + * + * @param omsInvoiceReceiptBill 采购收票单 + * @return 结果 + */ + public int updateOmsInvoiceReceiptBill(OmsInvoiceReceiptBill omsInvoiceReceiptBill); + + /** + * 批量删除采购收票单 + * + * @param ids 需要删除的采购收票单主键集合 + * @return 结果 + */ + public int deleteOmsInvoiceReceiptBillByIds(String ids); + + /** + * 删除采购收票单信息 + * + * @param id 采购收票单主键 + * @return 结果 + */ + public int deleteOmsInvoiceReceiptBillById(Long id); +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/IOmsPayableBillService.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/IOmsPayableBillService.java new file mode 100644 index 00000000..37d73ea8 --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/IOmsPayableBillService.java @@ -0,0 +1,61 @@ +package com.ruoyi.sip.service; + +import java.util.List; +import com.ruoyi.sip.domain.OmsPayableBill; + +/** + * 采购应付单Service接口 + * + * @author ruoyi + * @date 2025-10-22 + */ +public interface IOmsPayableBillService +{ + /** + * 查询采购应付单 + * + * @param id 采购应付单主键 + * @return 采购应付单 + */ + public OmsPayableBill selectOmsPayableBillById(Long id); + + /** + * 查询采购应付单列表 + * + * @param omsPayableBill 采购应付单 + * @return 采购应付单集合 + */ + public List selectOmsPayableBillList(OmsPayableBill omsPayableBill); + + /** + * 新增采购应付单 + * + * @param omsPayableBill 采购应付单 + * @return 结果 + */ + public int insertOmsPayableBill(OmsPayableBill omsPayableBill); + + /** + * 修改采购应付单 + * + * @param omsPayableBill 采购应付单 + * @return 结果 + */ + public int updateOmsPayableBill(OmsPayableBill omsPayableBill); + + /** + * 批量删除采购应付单 + * + * @param ids 需要删除的采购应付单主键集合 + * @return 结果 + */ + public int deleteOmsPayableBillByIds(String ids); + + /** + * 删除采购应付单信息 + * + * @param id 采购应付单主键 + * @return 结果 + */ + public int deleteOmsPayableBillById(Long id); +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/IOmsPaymentBillService.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/IOmsPaymentBillService.java new file mode 100644 index 00000000..3ceab459 --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/IOmsPaymentBillService.java @@ -0,0 +1,61 @@ +package com.ruoyi.sip.service; + +import java.util.List; +import com.ruoyi.sip.domain.OmsPaymentBill; + +/** + * 采购付款单Service接口 + * + * @author ruoyi + * @date 2025-10-22 + */ +public interface IOmsPaymentBillService +{ + /** + * 查询采购付款单 + * + * @param id 采购付款单主键 + * @return 采购付款单 + */ + public OmsPaymentBill selectOmsPaymentBillById(Long id); + + /** + * 查询采购付款单列表 + * + * @param omsPaymentBill 采购付款单 + * @return 采购付款单集合 + */ + public List selectOmsPaymentBillList(OmsPaymentBill omsPaymentBill); + + /** + * 新增采购付款单 + * + * @param omsPaymentBill 采购付款单 + * @return 结果 + */ + public int insertOmsPaymentBill(OmsPaymentBill omsPaymentBill); + + /** + * 修改采购付款单 + * + * @param omsPaymentBill 采购付款单 + * @return 结果 + */ + public int updateOmsPaymentBill(OmsPaymentBill omsPaymentBill); + + /** + * 批量删除采购付款单 + * + * @param ids 需要删除的采购付款单主键集合 + * @return 结果 + */ + public int deleteOmsPaymentBillByIds(String ids); + + /** + * 删除采购付款单信息 + * + * @param id 采购付款单主键 + * @return 结果 + */ + public int deleteOmsPaymentBillById(Long id); +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsInventoryInnerServiceImpl.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsInventoryInnerServiceImpl.java index 5104e0c2..8522e831 100644 --- a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsInventoryInnerServiceImpl.java +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsInventoryInnerServiceImpl.java @@ -1,5 +1,7 @@ package com.ruoyi.sip.service.impl; +import java.math.BigDecimal; +import java.math.RoundingMode; import java.util.*; import java.util.function.Function; import java.util.stream.Collectors; @@ -42,6 +44,8 @@ public class OmsInventoryInnerServiceImpl implements IOmsInventoryInnerService { @Autowired private IInventoryAuthService inventoryAuthService; + @Autowired + private IOmsPayableBillService payableBillService; /** * 查询入库单信息 * @@ -103,24 +107,41 @@ public class OmsInventoryInnerServiceImpl implements IOmsInventoryInnerService { if (!omsInventoryInner.getVendorCode().equals(vendorCode)) { throw new ServiceException("添加产品信息中产品编码和选择制造商不匹配,导入失败"); } - List warehouseIdList = inventoryInfoList.stream().map(InventoryInfo::getWarehouseId).distinct().filter(Objects::nonNull).collect(Collectors.toList()); - if (warehouseIdList.size() != 1) { - throw new ServiceException("添加产品信息中仓库不允许多个,导入失败"); - } - omsInventoryInner.setWarehouseId(warehouseIdList.get(0)); - inventoryInfoList.forEach(item->{ - item.setInnerCode(omsInventoryInner.getInnerCode()); - item.setCreateBy(currentUserId); - item.setCreateTime(nowDate); - if (StringUtils.isEmpty(item.getInventoryStatus())) { - item.setInventoryStatus(InventoryInfo.InventoryStatusEnum.INNER.getCode()); - } - }); //校验sn是否重复 List repeatSnList = inventoryInfoService.checkUnq(inventoryInfoList.stream().map(InventoryInfo::getProductSn).collect(Collectors.toList())); if (CollUtil.isNotEmpty(repeatSnList)) { throw new ServiceException(StrUtil.format("SN码[{}]已存在,保存失败", repeatSnList)); } + List warehouseIdList = inventoryInfoList.stream().map(InventoryInfo::getWarehouseId).distinct().filter(Objects::nonNull).collect(Collectors.toList()); + if (warehouseIdList.size() != 1) { + throw new ServiceException("添加产品信息中仓库不允许多个,导入失败"); + } + omsInventoryInner.setWarehouseId(warehouseIdList.get(0)); + + //todo 判断制造商是否需要生成应付单 +// BigDecimal totalPriceWithTax = inventoryInfoList.stream().map(InventoryInfo::getInnerPrice).filter(Objects::nonNull).reduce(BigDecimal.ZERO, BigDecimal::add); +// //生成应付单 +// BigDecimal taxAmount = totalPriceWithTax.multiply(new BigDecimal("0.13")).setScale(2, RoundingMode.HALF_UP); +// OmsPayableBill payableBill = OmsPayableBill.builder() +// .inventoryCode(omsInventoryInner.getInnerCode()) +// .vendorCode(omsInventoryInner.getVendorCode()) +// .productType(productInfos.get(0).getType()) +// .estimatedPaymentTime(DateUtils.addDays(DateUtils.getNowDate(),30)) +// .totalPriceWithTax(totalPriceWithTax) +// .taxAmount(taxAmount) +// .totalPriceWithoutTax(totalPriceWithTax.subtract(taxAmount)) +// .build(); +// payableBillService.insertOmsPayableBill(payableBill); + + inventoryInfoList.forEach(item->{ + item.setInnerCode(omsInventoryInner.getInnerCode()); + item.setCreateBy(currentUserId); +// item.setPayableBillCode(payableBill.getPayableBillCode()); + item.setCreateTime(nowDate); + if (StringUtils.isEmpty(item.getInventoryStatus())) { + item.setInventoryStatus(InventoryInfo.InventoryStatusEnum.INNER.getCode()); + } + }); inventoryInfoService.saveBatch(inventoryInfoList); productInfoService.updateAvailableCount(omsInventoryInner.getQuantity(),omsInventoryInner.getProductCode()); return omsInventoryInnerMapper.insertOmsInventoryInner(omsInventoryInner); diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsInvoiceReceiptBillServiceImpl.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsInvoiceReceiptBillServiceImpl.java new file mode 100644 index 00000000..2dbb8cf0 --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsInvoiceReceiptBillServiceImpl.java @@ -0,0 +1,97 @@ +package com.ruoyi.sip.service.impl; + +import java.util.List; +import com.ruoyi.common.utils.DateUtils; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import com.ruoyi.sip.mapper.OmsInvoiceReceiptBillMapper; +import com.ruoyi.sip.domain.OmsInvoiceReceiptBill; +import com.ruoyi.sip.service.IOmsInvoiceReceiptBillService; +import com.ruoyi.common.core.text.Convert; + +/** + * 采购收票单Service业务层处理 + * + * @author ruoyi + * @date 2025-10-22 + */ +@Service +public class OmsInvoiceReceiptBillServiceImpl implements IOmsInvoiceReceiptBillService +{ + @Autowired + private OmsInvoiceReceiptBillMapper omsInvoiceReceiptBillMapper; + + /** + * 查询采购收票单 + * + * @param id 采购收票单主键 + * @return 采购收票单 + */ + @Override + public OmsInvoiceReceiptBill selectOmsInvoiceReceiptBillById(Long id) + { + return omsInvoiceReceiptBillMapper.selectOmsInvoiceReceiptBillById(id); + } + + /** + * 查询采购收票单列表 + * + * @param omsInvoiceReceiptBill 采购收票单 + * @return 采购收票单 + */ + @Override + public List selectOmsInvoiceReceiptBillList(OmsInvoiceReceiptBill omsInvoiceReceiptBill) + { + return omsInvoiceReceiptBillMapper.selectOmsInvoiceReceiptBillList(omsInvoiceReceiptBill); + } + + /** + * 新增采购收票单 + * + * @param omsInvoiceReceiptBill 采购收票单 + * @return 结果 + */ + @Override + public int insertOmsInvoiceReceiptBill(OmsInvoiceReceiptBill omsInvoiceReceiptBill) + { + omsInvoiceReceiptBill.setCreateTime(DateUtils.getNowDate()); + return omsInvoiceReceiptBillMapper.insertOmsInvoiceReceiptBill(omsInvoiceReceiptBill); + } + + /** + * 修改采购收票单 + * + * @param omsInvoiceReceiptBill 采购收票单 + * @return 结果 + */ + @Override + public int updateOmsInvoiceReceiptBill(OmsInvoiceReceiptBill omsInvoiceReceiptBill) + { + omsInvoiceReceiptBill.setUpdateTime(DateUtils.getNowDate()); + return omsInvoiceReceiptBillMapper.updateOmsInvoiceReceiptBill(omsInvoiceReceiptBill); + } + + /** + * 批量删除采购收票单 + * + * @param ids 需要删除的采购收票单主键 + * @return 结果 + */ + @Override + public int deleteOmsInvoiceReceiptBillByIds(String ids) + { + return omsInvoiceReceiptBillMapper.deleteOmsInvoiceReceiptBillByIds(Convert.toStrArray(ids)); + } + + /** + * 删除采购收票单信息 + * + * @param id 采购收票单主键 + * @return 结果 + */ + @Override + public int deleteOmsInvoiceReceiptBillById(Long id) + { + return omsInvoiceReceiptBillMapper.deleteOmsInvoiceReceiptBillById(id); + } +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsPayableBillServiceImpl.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsPayableBillServiceImpl.java new file mode 100644 index 00000000..0509768d --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsPayableBillServiceImpl.java @@ -0,0 +1,115 @@ +package com.ruoyi.sip.service.impl; + +import java.text.DateFormat; +import java.util.List; + +import cn.hutool.core.date.DateField; +import cn.hutool.core.date.DatePattern; +import cn.hutool.core.date.DateUtil; +import com.ruoyi.common.utils.DateUtils; +import com.ruoyi.common.utils.ShiroUtils; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import com.ruoyi.sip.mapper.OmsPayableBillMapper; +import com.ruoyi.sip.domain.OmsPayableBill; +import com.ruoyi.sip.service.IOmsPayableBillService; +import com.ruoyi.common.core.text.Convert; + +/** + * 采购应付单Service业务层处理 + * + * @author ruoyi + * @date 2025-10-22 + */ +@Service +public class OmsPayableBillServiceImpl implements IOmsPayableBillService { + @Autowired + private OmsPayableBillMapper omsPayableBillMapper; + + /** + * 查询采购应付单 + * + * @param id 采购应付单主键 + * @return 采购应付单 + */ + @Override + public OmsPayableBill selectOmsPayableBillById(Long id) { + return omsPayableBillMapper.selectOmsPayableBillById(id); + } + + /** + * 查询采购应付单列表 + * + * @param omsPayableBill 采购应付单 + * @return 采购应付单 + */ + @Override + public List selectOmsPayableBillList(OmsPayableBill omsPayableBill) { + return omsPayableBillMapper.selectOmsPayableBillList(omsPayableBill); + } + + /** + * 新增采购应付单 + * + * @param omsPayableBill 采购应付单 + * @return 结果 + */ + @Override + public int insertOmsPayableBill(OmsPayableBill omsPayableBill) { + //生成采购应付单编号 + omsPayableBill.setPayableBillCode(generatePayableBillCode()); + omsPayableBill.setCreateTime(DateUtils.getNowDate()); + omsPayableBill.setCreateBy(ShiroUtils.getUserId().toString()); + return omsPayableBillMapper.insertOmsPayableBill(omsPayableBill); + } + + /** + * 生成应付单编号 CYF+YYMMdd+当日序列号 + * @return 应付单编号 + */ + private String generatePayableBillCode() { + String prefix = "CYF"; + // 查询当天已有的最大序列号 + String codePrefix = prefix + DateUtil.format(DateUtil.date(), DatePattern.PURE_DATE_PATTERN); + int maxSequence = omsPayableBillMapper.selectMaxCodeByPrefix(codePrefix); + // 生成新的序列号 + int newSequence = maxSequence + 1; + // 序列号补零到4位 + String sequenceStr = String.format("%04d", newSequence); + return codePrefix + sequenceStr; + } + + /** + * 修改采购应付单 + * + * @param omsPayableBill 采购应付单 + * @return 结果 + */ + @Override + public int updateOmsPayableBill(OmsPayableBill omsPayableBill) { + omsPayableBill.setUpdateTime(DateUtils.getNowDate()); + return omsPayableBillMapper.updateOmsPayableBill(omsPayableBill); + } + + /** + * 批量删除采购应付单 + * + * @param ids 需要删除的采购应付单主键 + * @return 结果 + */ + @Override + public int deleteOmsPayableBillByIds(String ids) { + return omsPayableBillMapper.deleteOmsPayableBillByIds(Convert.toStrArray(ids)); + } + + /** + * 删除采购应付单信息 + * + * @param id 采购应付单主键 + * @return 结果 + */ + @Override + public int deleteOmsPayableBillById(Long id) { + return omsPayableBillMapper.deleteOmsPayableBillById(id); + } +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsPaymentBillServiceImpl.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsPaymentBillServiceImpl.java new file mode 100644 index 00000000..7dd816a0 --- /dev/null +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/OmsPaymentBillServiceImpl.java @@ -0,0 +1,97 @@ +package com.ruoyi.sip.service.impl; + +import java.util.List; +import com.ruoyi.common.utils.DateUtils; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.stereotype.Service; +import com.ruoyi.sip.mapper.OmsPaymentBillMapper; +import com.ruoyi.sip.domain.OmsPaymentBill; +import com.ruoyi.sip.service.IOmsPaymentBillService; +import com.ruoyi.common.core.text.Convert; + +/** + * 采购付款单Service业务层处理 + * + * @author ruoyi + * @date 2025-10-22 + */ +@Service +public class OmsPaymentBillServiceImpl implements IOmsPaymentBillService +{ + @Autowired + private OmsPaymentBillMapper omsPaymentBillMapper; + + /** + * 查询采购付款单 + * + * @param id 采购付款单主键 + * @return 采购付款单 + */ + @Override + public OmsPaymentBill selectOmsPaymentBillById(Long id) + { + return omsPaymentBillMapper.selectOmsPaymentBillById(id); + } + + /** + * 查询采购付款单列表 + * + * @param omsPaymentBill 采购付款单 + * @return 采购付款单 + */ + @Override + public List selectOmsPaymentBillList(OmsPaymentBill omsPaymentBill) + { + return omsPaymentBillMapper.selectOmsPaymentBillList(omsPaymentBill); + } + + /** + * 新增采购付款单 + * + * @param omsPaymentBill 采购付款单 + * @return 结果 + */ + @Override + public int insertOmsPaymentBill(OmsPaymentBill omsPaymentBill) + { + omsPaymentBill.setCreateTime(DateUtils.getNowDate()); + return omsPaymentBillMapper.insertOmsPaymentBill(omsPaymentBill); + } + + /** + * 修改采购付款单 + * + * @param omsPaymentBill 采购付款单 + * @return 结果 + */ + @Override + public int updateOmsPaymentBill(OmsPaymentBill omsPaymentBill) + { + omsPaymentBill.setUpdateTime(DateUtils.getNowDate()); + return omsPaymentBillMapper.updateOmsPaymentBill(omsPaymentBill); + } + + /** + * 批量删除采购付款单 + * + * @param ids 需要删除的采购付款单主键 + * @return 结果 + */ + @Override + public int deleteOmsPaymentBillByIds(String ids) + { + return omsPaymentBillMapper.deleteOmsPaymentBillByIds(Convert.toStrArray(ids)); + } + + /** + * 删除采购付款单信息 + * + * @param id 采购付款单主键 + * @return 结果 + */ + @Override + public int deleteOmsPaymentBillById(Long id) + { + return omsPaymentBillMapper.deleteOmsPaymentBillById(id); + } +} diff --git a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/ProjectOrderInfoServiceImpl.java b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/ProjectOrderInfoServiceImpl.java index 1f37d58f..e8a8d543 100644 --- a/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/ProjectOrderInfoServiceImpl.java +++ b/ruoyi-sip/src/main/java/com/ruoyi/sip/service/impl/ProjectOrderInfoServiceImpl.java @@ -1281,13 +1281,25 @@ public class ProjectOrderInfoServiceImpl implements IProjectOrderInfoService, To emailList.addAll(partnerInfos.stream().map(PartnerInfo::getContactEmail).filter(StringUtils::isNotEmpty).collect(Collectors.toList())); } // 发送邮件 - List cssMailList = new ArrayList<>(CSS_EMAIL_LIST); + List cssMailList = new ArrayList<>(); + if (ProjectOrderInfo.OrderChannelEnum.DIRECT_SIGNING.getCode().equals(dbProjectOrderInfo.getOrderChannel())) { + //直签 + cssMailList.add("xuxinyu@unisinsight.com"); + } else { + //总代 + cssMailList.addAll(CSS_EMAIL_LIST); + cssMailList.add("jiao.sumei@unisinsight.com"); + } + //查询商务邮件 - List sysUsers = userService.listByRoleId(businessRoleId); - cssMailList.addAll(sysUsers.stream() - .map(SysUser::getEmail) - .filter(StringUtils::isNotEmpty) - .collect(Collectors.toList())); +// List sysUsers = userService.listByRoleId(businessRoleId); +// cssMailList.addAll(sysUsers.stream() +// .map(SysUser::getEmail) +// .filter(StringUtils::isNotEmpty) +// .collect(Collectors.toList())); + + + this.sendPartnerMail(emailList.stream().distinct().collect(Collectors.toList()), dbProjectOrderInfo,cssMailList); } @@ -1337,16 +1349,9 @@ public class ProjectOrderInfoServiceImpl implements IProjectOrderInfoService, To } String templateTile="{}-紫光汇智云桌面-{}-进供货执行通知"; String title = StringUtils.format(templateTile, projectOrderInfo.getOrderCode(), projectOrderInfo.getProjectName()); - - String activeProfile = SpringUtils.getActiveProfile(); - if ("dev".equals(activeProfile)){ - //开发环境不抄送领导 - TemplateMailUtil.sendTemplateMail(toEmail,title, - TemplateMailUtil.MailTemplate.ORDER_PARTNER,Dict.create()); - }else{ - TemplateMailUtil.sendTemplateMail(toEmail,title, + TemplateMailUtil.sendTemplateMail(toEmail,title, TemplateMailUtil.MailTemplate.ORDER_PARTNER,Dict.create(),toCssEmail); - } + } diff --git a/ruoyi-sip/src/main/resources/mapper/finance/OmsInvoiceReceiptBillMapper.xml b/ruoyi-sip/src/main/resources/mapper/finance/OmsInvoiceReceiptBillMapper.xml new file mode 100644 index 00000000..7f877297 --- /dev/null +++ b/ruoyi-sip/src/main/resources/mapper/finance/OmsInvoiceReceiptBillMapper.xml @@ -0,0 +1,106 @@ + + + + + + + + + + + + + + + + + + + + + + select id, invoice_receipt_bill_code, vendor_code, order_code, total_price_with_tax, total_price_without_tax, tax_amount, create_by, create_time, update_by, update_time, remark, del_flag from oms_invoice_receipt_bill + + + + + + + + insert into oms_invoice_receipt_bill + + invoice_receipt_bill_code, + vendor_code, + order_code, + total_price_with_tax, + total_price_without_tax, + tax_amount, + create_by, + create_time, + update_by, + update_time, + remark, + del_flag, + + + #{invoiceReceiptBillCode}, + #{vendorCode}, + #{orderCode}, + #{totalPriceWithTax}, + #{totalPriceWithoutTax}, + #{taxAmount}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{remark}, + #{delFlag}, + + + + + update oms_invoice_receipt_bill + + invoice_receipt_bill_code = #{invoiceReceiptBillCode}, + vendor_code = #{vendorCode}, + order_code = #{orderCode}, + total_price_with_tax = #{totalPriceWithTax}, + total_price_without_tax = #{totalPriceWithoutTax}, + tax_amount = #{taxAmount}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + remark = #{remark}, + del_flag = #{delFlag}, + + where id = #{id} + + + + delete from oms_invoice_receipt_bill where id = #{id} + + + + delete from oms_invoice_receipt_bill where id in + + #{id} + + + + \ No newline at end of file diff --git a/ruoyi-sip/src/main/resources/mapper/finance/OmsPayableBillMapper.xml b/ruoyi-sip/src/main/resources/mapper/finance/OmsPayableBillMapper.xml new file mode 100644 index 00000000..c5171b65 --- /dev/null +++ b/ruoyi-sip/src/main/resources/mapper/finance/OmsPayableBillMapper.xml @@ -0,0 +1,136 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + select id, payable_bill_code, estimated_payment_time, vendor_code, order_code, inventory_code, product_type, total_price_with_tax, total_price_without_tax, tax_amount, payment_bill_id, invoice_receipt_bill_id, create_by, create_time, update_by, update_time, remark, del_flag from oms_payable_bill + + + + + + + + + insert into oms_payable_bill + + payable_bill_code, + estimated_payment_time, + vendor_code, + order_code, + inventory_code, + product_type, + total_price_with_tax, + total_price_without_tax, + tax_amount, + payment_bill_id, + invoice_receipt_bill_id, + create_by, + create_time, + update_by, + update_time, + remark, + del_flag, + + + #{payableBillCode}, + #{estimatedPaymentTime}, + #{vendorCode}, + #{orderCode}, + #{inventoryCode}, + #{productType}, + #{totalPriceWithTax}, + #{totalPriceWithoutTax}, + #{taxAmount}, + #{paymentBillId}, + #{invoiceReceiptBillId}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{remark}, + #{delFlag}, + + + + + update oms_payable_bill + + payable_bill_code = #{payableBillCode}, + estimated_payment_time = #{estimatedPaymentTime}, + vendor_code = #{vendorCode}, + order_code = #{orderCode}, + inventory_code = #{inventoryCode}, + product_type = #{productType}, + total_price_with_tax = #{totalPriceWithTax}, + total_price_without_tax = #{totalPriceWithoutTax}, + tax_amount = #{taxAmount}, + payment_bill_id = #{paymentBillId}, + invoice_receipt_bill_id = #{invoiceReceiptBillId}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + remark = #{remark}, + del_flag = #{delFlag}, + + where id = #{id} + + + + delete from oms_payable_bill where id = #{id} + + + + delete from oms_payable_bill where id in + + #{id} + + + + \ No newline at end of file diff --git a/ruoyi-sip/src/main/resources/mapper/finance/OmsPaymentBillMapper.xml b/ruoyi-sip/src/main/resources/mapper/finance/OmsPaymentBillMapper.xml new file mode 100644 index 00000000..c39f5688 --- /dev/null +++ b/ruoyi-sip/src/main/resources/mapper/finance/OmsPaymentBillMapper.xml @@ -0,0 +1,116 @@ + + + + + + + + + + + + + + + + + + + + + + + + select id, payment_bill_code, payment_bill_type, payment_time, vendor_code, order_code, total_price_with_tax, total_price_without_tax, tax_amount, create_by, create_time, update_by, update_time, remark, del_flag from oms_payment_bill + + + + + + + + insert into oms_payment_bill + + payment_bill_code, + payment_bill_type, + payment_time, + vendor_code, + order_code, + total_price_with_tax, + total_price_without_tax, + tax_amount, + create_by, + create_time, + update_by, + update_time, + remark, + del_flag, + + + #{paymentBillCode}, + #{paymentBillType}, + #{paymentTime}, + #{vendorCode}, + #{orderCode}, + #{totalPriceWithTax}, + #{totalPriceWithoutTax}, + #{taxAmount}, + #{createBy}, + #{createTime}, + #{updateBy}, + #{updateTime}, + #{remark}, + #{delFlag}, + + + + + update oms_payment_bill + + payment_bill_code = #{paymentBillCode}, + payment_bill_type = #{paymentBillType}, + payment_time = #{paymentTime}, + vendor_code = #{vendorCode}, + order_code = #{orderCode}, + total_price_with_tax = #{totalPriceWithTax}, + total_price_without_tax = #{totalPriceWithoutTax}, + tax_amount = #{taxAmount}, + create_by = #{createBy}, + create_time = #{createTime}, + update_by = #{updateBy}, + update_time = #{updateTime}, + remark = #{remark}, + del_flag = #{delFlag}, + + where id = #{id} + + + + delete from oms_payment_bill where id = #{id} + + + + delete from oms_payment_bill where id in + + #{id} + + + + \ No newline at end of file diff --git a/ruoyi-sip/src/main/resources/mapper/inventory/InventoryInfoMapper.xml b/ruoyi-sip/src/main/resources/mapper/inventory/InventoryInfoMapper.xml index e2692637..2bb959d6 100644 --- a/ruoyi-sip/src/main/resources/mapper/inventory/InventoryInfoMapper.xml +++ b/ruoyi-sip/src/main/resources/mapper/inventory/InventoryInfoMapper.xml @@ -115,9 +115,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - insert into oms_inventory_info (product_code, product_sn, inventory_status, inner_code, outer_code, warehouse_id, inner_price, outer_price, create_by, create_time, update_by, update_time) values + insert into oms_inventory_info (product_code, product_sn, inventory_status, inner_code, outer_code + , warehouse_id, inner_price, outer_price, create_by, create_time, update_by, update_time,payable_bill_code) values - (#{item.productCode}, #{item.productSn}, #{item.inventoryStatus}, #{item.innerCode}, #{item.outerCode}, #{item.warehouseId}, #{item.innerPrice}, #{item.outerPrice}, #{item.createBy}, #{item.createTime}, #{item.updateBy}, #{item.updateTime}) + (#{item.productCode}, #{item.productSn}, #{item.inventoryStatus}, #{item.innerCode}, #{item.outerCode} + , #{item.warehouseId}, #{item.innerPrice}, #{item.outerPrice}, #{item.createBy}, #{item.createTime}, #{item.updateBy}, #{item.updateTime},#{item.payableBillCode}) ON DUPLICATE KEY UPDATE inventory_status = VALUES(inventory_status),