From 711c4737496f78ad10855397dcca170c77af8f22 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B1=88=E5=B1=95=E8=88=AA?= <2426745133@qq.com> Date: Mon, 1 Sep 2025 17:08:21 +0800 Subject: [PATCH] =?UTF-8?q?09-01-=E4=BE=9B=E5=BA=94=E5=95=86=E5=85=A5?= =?UTF-8?q?=E5=BA=93=E6=96=B0=E5=A2=9E=E5=AF=BC=E5=85=A5=EF=BC=8C=E4=BF=AE?= =?UTF-8?q?=E6=94=B9=E5=AD=97=E6=AE=B5;=E7=89=A9=E8=B5=84=E8=AE=BE?= =?UTF-8?q?=E5=A4=87=E6=B8=85=E5=8D=95=E6=96=B0=E5=A2=9E=E6=8C=89=E8=AE=BE?= =?UTF-8?q?=E5=A4=87=E5=90=8D=E7=A7=B0=E6=9F=A5=E8=AF=A2=EF=BC=8C=E6=96=B0?= =?UTF-8?q?=E5=A2=9E=E7=A8=8E=E7=8E=87=E5=AD=97=E6=AE=B5.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../test/java/org/dromara/test/DemoTest.java | 13 ++++ .../TenderSupplierInputController.java | 22 ++++++ .../domain/BusBillofquantitiesLimitList.java | 5 ++ .../tender/domain/TenderSupplierInput.java | 48 +++++++++++-- .../bo/BusBillofquantitiesLimitListBo.java | 5 ++ .../domain/bo/TenderSupplierInputBo.java | 44 +++++++++++- .../vo/BusBillofquantitiesLimitListVo.java | 6 ++ .../domain/vo/TenderSupplierInputVo.java | 71 ++++++++++++++++--- ...sBillofquantitiesLimitListServiceImpl.java | 2 +- .../impl/TenderSupplierInputServiceImpl.java | 2 +- .../BusBillofquantitiesLimitListMapper.xml | 6 ++ 11 files changed, 206 insertions(+), 18 deletions(-) diff --git a/xinnengyuan/ruoyi-admin/src/test/java/org/dromara/test/DemoTest.java b/xinnengyuan/ruoyi-admin/src/test/java/org/dromara/test/DemoTest.java index 627b732d..c1b034dd 100644 --- a/xinnengyuan/ruoyi-admin/src/test/java/org/dromara/test/DemoTest.java +++ b/xinnengyuan/ruoyi-admin/src/test/java/org/dromara/test/DemoTest.java @@ -3,6 +3,7 @@ package org.dromara.test; import cn.hutool.core.io.FileUtil; import jakarta.annotation.Resource; import lombok.extern.slf4j.Slf4j; +import org.dromara.common.excel.utils.ExcelUtil; import org.dromara.design.service.IDesTechnicalStandardService; import org.dromara.facility.domain.FacMatrix; import org.dromara.facility.service.IFacMatrixService; @@ -11,7 +12,11 @@ import org.dromara.progress.service.IPgsProgressCategoryService; import org.dromara.progress.service.IPgsProgressCategoryTemplateService; import org.dromara.project.service.IBusProjectService; import org.dromara.system.service.ISysDeptService; +import org.dromara.tender.domain.bo.TenderSupplierInputBo; +import org.dromara.tender.domain.vo.TenderSupplierInputVo; +import org.dromara.tender.service.impl.TenderSupplierInputServiceImpl; import org.junit.jupiter.api.Test; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; import java.util.Date; @@ -45,6 +50,8 @@ public class DemoTest { @Resource private ISysDeptService deptService; + @Autowired + private TenderSupplierInputServiceImpl tenderSupplierInputService; @Test void test() { @@ -99,4 +106,10 @@ public class DemoTest { deptService.selectProjectIdById(100L); deptService.selectProjectIdById(1937478258803171329L); }*/ + + @Test + void tenderExport(){ + + } + } diff --git a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/controller/TenderSupplierInputController.java b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/controller/TenderSupplierInputController.java index 7305224e..69e6a897 100644 --- a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/controller/TenderSupplierInputController.java +++ b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/controller/TenderSupplierInputController.java @@ -1,5 +1,7 @@ package org.dromara.tender.controller; +import java.io.IOException; +import java.util.ArrayList; import java.util.List; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; @@ -12,6 +14,8 @@ import org.dromara.cailiaoshebei.controller.constant; import org.dromara.cailiaoshebei.domain.BusCailiaoshebeiPici; import org.dromara.common.core.domain.event.ProcessEvent; import org.dromara.system.service.ISysOssService; +import org.dromara.tender.domain.TenderSupplierInput; +import org.springframework.beans.BeanUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.*; import org.springframework.validation.annotation.Validated; @@ -74,6 +78,24 @@ public class TenderSupplierInputController extends BaseController { ExcelUtil.exportExcel(list, "供应商入库", TenderSupplierInputVo.class, response); } + /** + * 导入供应商入库 入库资料文件只有导入后修改进行上传 + */ + @SaCheckPermission("supplierInput:supplierInput:import") + @Log(title = "供应商入库", businessType = BusinessType.IMPORT) + @PostMapping("/import") + public R importData(@RequestParam("file")MultipartFile file) throws IOException { + List tenderSupplierInputVos = ExcelUtil.importExcel(file.getInputStream(), TenderSupplierInputVo.class); + List tenderSupplierInputs = new ArrayList<>(); + + for (TenderSupplierInputVo tenderSupplierInputVo : tenderSupplierInputVos) { + TenderSupplierInput newTenderSupplierInput = new TenderSupplierInput(); + BeanUtils.copyProperties(tenderSupplierInputVo, newTenderSupplierInput); + tenderSupplierInputs.add(newTenderSupplierInput); + } + return toAjax(tenderSupplierInputService.saveOrUpdateBatch(tenderSupplierInputs)); + } + /** * 获取供应商入库详细信息 * diff --git a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/BusBillofquantitiesLimitList.java b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/BusBillofquantitiesLimitList.java index ef6081b3..ecae45db 100644 --- a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/BusBillofquantitiesLimitList.java +++ b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/BusBillofquantitiesLimitList.java @@ -90,6 +90,11 @@ public class BusBillofquantitiesLimitList extends BaseEntity { @TableField("unit_price") private BigDecimal unitPrice; + /** + * 税率 + */ + private int taxRate; + /** * 总价 */ diff --git a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/TenderSupplierInput.java b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/TenderSupplierInput.java index 2da98db7..33451dde 100644 --- a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/TenderSupplierInput.java +++ b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/TenderSupplierInput.java @@ -134,14 +134,54 @@ public class TenderSupplierInput extends BaseEntity { private String safeCertificateValidity; /** - * 注册注册人员的数量 + * 注册注册人员的数量 一级建造 二级建造 注册造价工程师 其他 */ - private String registeredNumber; +// private String registeredNumber; /** - * 职称人员数量 + * 注册造价工程师数量 */ - private String personnelNumber; + private Long registeredEngineerNumber; + + /** + * 一级建造数量 + */ + private Long firstBuildingNumber; + + /** + * 二级建造数量 + */ + private Long secondBuildingNumber; + + /** + * 其他建造师数量 + */ + private Long otherBuildingNumber; + + /** + * 职称人员数量 高级工程师 工程师数量 助理工程师 其他人员数量 + */ +// private String personnelNumber; + + /** + * 高级工程师数量 + */ + private Long seniorEngineerNumber; + + /** + * 工程师数量 + */ + private Long engineerNumber; + + /** + * 助理工程师数量 + */ + private Long assistantEngineerNumber; + + /** + * 其他人员数量 + */ + private Long otherPersonnelNumber; /** * 存储文件ID diff --git a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/bo/BusBillofquantitiesLimitListBo.java b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/bo/BusBillofquantitiesLimitListBo.java index e803962b..7dd6a238 100644 --- a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/bo/BusBillofquantitiesLimitListBo.java +++ b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/bo/BusBillofquantitiesLimitListBo.java @@ -90,6 +90,11 @@ public class BusBillofquantitiesLimitListBo extends BaseEntity { */ private BigDecimal unitPrice; + /** + * 税率 + */ + private int taxRate; + /** * 总价 */ diff --git a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/bo/TenderSupplierInputBo.java b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/bo/TenderSupplierInputBo.java index e5c7f5f9..92789e41 100644 --- a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/bo/TenderSupplierInputBo.java +++ b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/bo/TenderSupplierInputBo.java @@ -139,12 +139,52 @@ public class TenderSupplierInputBo extends BaseEntity { /** * 注册注册人员的数量 */ - private String registeredNumber; +// private String registeredNumber; + + /** + * 注册造价工程师数量 + */ + private Long registeredEngineerNumber; + + /** + * 一级建造数量 + */ + private Long firstBuildingNumber; + + /** + * 二级建造数量 + */ + private Long secondBuildingNumber; + + /** + * 其他建造师数量 + */ + private Long otherBuildingNumber; /** * 职称人员数量 */ - private String personnelNumber; +// private String personnelNumber; + + /** + * 高级工程师数量 + */ + private Long seniorEngineerNumber; + + /** + * 工程师数量 + */ + private Long engineerNumber; + + /** + * 助理工程师数量 + */ + private Long assistantEngineerNumber; + + /** + * 其他人员数量 + */ + private Long otherPersonnelNumber; /** * 存储文件ID diff --git a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/vo/BusBillofquantitiesLimitListVo.java b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/vo/BusBillofquantitiesLimitListVo.java index dd6a4185..52d3088f 100644 --- a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/vo/BusBillofquantitiesLimitListVo.java +++ b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/vo/BusBillofquantitiesLimitListVo.java @@ -115,6 +115,12 @@ public class BusBillofquantitiesLimitListVo implements Serializable { @ExcelProperty(value = "单价") private BigDecimal unitPrice; + /** + * 税率 + */ + @ExcelProperty(value = "税率") + private int taxRate; + /** * 总价 */ diff --git a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/vo/TenderSupplierInputVo.java b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/vo/TenderSupplierInputVo.java index ae201c5e..6ffefbab 100644 --- a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/vo/TenderSupplierInputVo.java +++ b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/domain/vo/TenderSupplierInputVo.java @@ -33,7 +33,7 @@ public class TenderSupplierInputVo implements Serializable { /** * */ - @ExcelProperty(value = "") + @ExcelProperty(value = "序号") private Long id; /** @@ -139,46 +139,97 @@ public class TenderSupplierInputVo implements Serializable { @ExcelProperty(value = "近三年营业额") private String pastThreeYears; + + //除劳务类型外都可为空 + /** * 安全生产许可证编号 */ - @ExcelProperty(value = "安全生产许可证编号") + @ExcelProperty(value = "安全生产许可证编号(除劳务类型外都可为空)") private String safeCode; /** * 安全生产许可证发证日期 */ - @ExcelProperty(value = "安全生产许可证发证日期") + @ExcelProperty(value = "安全生产许可证发证日期(除劳务类型外都可为空)") private String safeCodeData; /** * 证书有效期 */ - @ExcelProperty(value = "证书有效期") + @ExcelProperty(value = "证书有效期(除劳务类型外都可为空)") private String safeCertificateValidity; /** * 注册注册人员的数量 */ - @ExcelProperty(value = "注册注册人员的数量") - private String registeredNumber; +// @ExcelProperty(value = "注册注册人员的数量(除劳务类型外都可为空)") +// private String registeredNumber; + + /** + * 注册造价工程师数量 + */ + @ExcelProperty(value = "注册造价工程师数量(除劳务类型外都可为空)") + private Long registeredEngineerNumber; + + /** + * 一级建造数量 + */ + @ExcelProperty(value = "一级建造数量(除劳务类型外都可为空)") + private Long firstBuildingNumber; + + /** + * 二级建造数量 + */ + @ExcelProperty(value = "二级建造数量(除劳务类型外都可为空)") + private Long secondBuildingNumber; + + /** + * 其他建造师数量 + */ + @ExcelProperty(value = "其他建造师数量(除劳务类型外都可为空)") + private Long otherBuildingNumber; /** * 职称人员数量 */ - @ExcelProperty(value = "职称人员数量") - private String personnelNumber; +// @ExcelProperty(value = "职称人员数量(除劳务类型外都可为空)") +// private String personnelNumber; + + /** + * 高级工程师数量 + */ + @ExcelProperty(value = "高级工程师数量(除劳务类型外都可为空)") + private Long seniorEngineerNumber; + + /** + * 工程师数量 + */ + @ExcelProperty(value = "工程师数量(除劳务类型外都可为空)") + private Long engineerNumber; + + /** + * 助理工程师数量 + */ + @ExcelProperty(value = "助理工程师数量(除劳务类型外都可为空)") + private Long assistantEngineerNumber; + + /** + * 其他人员数量 + */ + @ExcelProperty(value = "其他人员数量(除劳务类型外都可为空)") + private Long otherPersonnelNumber; /** * 存储文件ID */ - @ExcelProperty(value = "存储文件ID") + //@ExcelProperty(value = "存储文件ID") private Long fileId; /** * 入库资料 */ - @ExcelProperty(value = "入库资料") + //@ExcelProperty(value = "入库资料") private String inputFile; /** diff --git a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/service/impl/BusBillofquantitiesLimitListServiceImpl.java b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/service/impl/BusBillofquantitiesLimitListServiceImpl.java index b12f5e49..9db81e28 100644 --- a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/service/impl/BusBillofquantitiesLimitListServiceImpl.java +++ b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/service/impl/BusBillofquantitiesLimitListServiceImpl.java @@ -185,7 +185,7 @@ public class BusBillofquantitiesLimitListServiceImpl extends ServiceImpl getTree(BusBillofquantitiesLimitListBo bo) { //获取所有数据 - List listVoList = new ArrayList<>(); + List listVoList; if (bo.getType().equals(LimitListTypeEnum.COMPANY.getCode())){ listVoList = baseMapper.selectByBoByType(bo); }else { diff --git a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/service/impl/TenderSupplierInputServiceImpl.java b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/service/impl/TenderSupplierInputServiceImpl.java index 50dcdf25..6ec73ef9 100644 --- a/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/service/impl/TenderSupplierInputServiceImpl.java +++ b/xinnengyuan/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/tender/service/impl/TenderSupplierInputServiceImpl.java @@ -92,7 +92,7 @@ public class TenderSupplierInputServiceImpl extends ServiceImpl AND bbll.sheet = #{bo.sheet} + + AND bbll.name LIKE CONCAT('%', #{bo.name}, '%') + GROUP BY bbll.id ORDER BY bbll.sid ASC @@ -150,6 +153,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" AND bbll.sheet = #{bo.sheet} + + AND bbll.name LIKE CONCAT('%', #{bo.name}, '%') + GROUP BY bbll.id ORDER BY bbll.sid ASC