yuansh hace 10 meses
padre
commit
71ad14781d
Se han modificado 100 ficheros con 6186 adiciones y 224 borrados
  1. 2 2
      jeecg-boot-base-core/src/main/java/org/jeecg/config/Swagger2Config.java
  2. 2 1
      jeecg-boot-base-core/src/main/java/org/jeecg/config/mybatis/MybatisPlusSaasConfig.java
  3. 1 1
      jeecg-module-system/jeecg-system-start/src/main/java/org/jeecg/JeecgSystemApplication.java
  4. 55 4
      srm-module-code/src/main/java/org/jeecg/modules/purCode/controller/PurInquiryFormController.java
  5. 288 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/controller/PurOrderController.java
  6. 180 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/controller/PurOrderFilesController.java
  7. 288 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/controller/PurOrderHisController.java
  8. 84 19
      srm-module-code/src/main/java/org/jeecg/modules/purCode/controller/PurPurchaseQuotationController.java
  9. 1 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/controller/PurQuotationSelectionController.java
  10. 12 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurInquiryForm.java
  11. 3 3
      srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurInquiryFormProduct.java
  12. 191 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrder.java
  13. 85 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrderFiles.java
  14. 195 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrderHis.java
  15. 153 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrderProduct.java
  16. 161 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrderProductHis.java
  17. 87 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrderShip.java
  18. 95 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrderShipHis.java
  19. 37 36
      srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurPurchaseQuotation.java
  20. 5 5
      srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurPurchaseQuotationProduct.java
  21. 1 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurQuotationSelection.java
  22. 1 1
      srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurQuotationSelectionProduct.java
  23. 7 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurInquiryFormProductMapper.java
  24. 17 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderFilesMapper.java
  25. 17 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderHisMapper.java
  26. 17 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderMapper.java
  27. 6 6
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderProductHisMapper.java
  28. 31 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderProductMapper.java
  29. 31 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderShipHisMapper.java
  30. 31 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderShipMapper.java
  31. 41 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurPurchaseQuotationProductMapper.java
  32. 36 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurInquiryFormProductMapper.xml
  33. 5 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderFilesMapper.xml
  34. 5 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderHisMapper.xml
  35. 5 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderMapper.xml
  36. 4 4
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderProductHisMapper.xml
  37. 16 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderProductMapper.xml
  38. 16 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderShipHisMapper.xml
  39. 16 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderShipMapper.xml
  40. 81 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurPurchaseQuotationProductMapper.xml
  41. 8 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurInquiryFormProductService.java
  42. 14 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderFilesService.java
  43. 51 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderHisService.java
  44. 22 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderProductHisService.java
  45. 22 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderProductService.java
  46. 51 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderService.java
  47. 22 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderShipHisService.java
  48. 22 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderShipService.java
  49. 0 22
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurPurchaseInquiryProductService.java
  50. 30 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurPurchaseQuotationProductService.java
  51. 5 5
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurPurchaseQuotationService.java
  52. 13 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurInquiryFormProductServiceImpl.java
  53. 4 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurInquiryFormServiceImpl.java
  54. 19 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderFilesServiceImpl.java
  55. 98 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderHisServiceImpl.java
  56. 27 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderProductHisServiceImpl.java
  57. 27 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderProductServiceImpl.java
  58. 98 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderServiceImpl.java
  59. 27 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderShipHisServiceImpl.java
  60. 27 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderShipServiceImpl.java
  61. 0 27
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurPurchaseInquiryProductServiceImpl.java
  62. 47 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurPurchaseQuotationProductServiceImpl.java
  63. 18 14
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurPurchaseQuotationServiceImpl.java
  64. 4 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurQuotationSelectionServiceImpl.java
  65. 7 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/vo/PurInquiryFormPage.java
  66. 199 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/vo/PurOrderHisPage.java
  67. 195 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/vo/PurOrderPage.java
  68. 73 73
      srm-module-code/src/main/java/org/jeecg/modules/purCode/vo/PurPurchaseQuotationPage.java
  69. 238 0
      srm-module-code/src/main/java/org/jeecg/modules/purCode/vo/SupplierQuotationDetails.java
  70. 721 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/controller/SaleOrderController.java
  71. 180 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/controller/SaleOrderFilesController.java
  72. 288 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/controller/SaleOrderHisController.java
  73. 22 1
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/controller/SaleQuotationController.java
  74. 1 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleContract.java
  75. 4 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleInquiryForm.java
  76. 229 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrder.java
  77. 83 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrderFiles.java
  78. 231 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrderHis.java
  79. 154 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrderProduct.java
  80. 162 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrderProductHis.java
  81. 87 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrderShip.java
  82. 95 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrderShipHis.java
  83. 2 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleQuotation.java
  84. 1 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleQuotationHis.java
  85. 1 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleQuotationProduct.java
  86. 1 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleQuotationProductHis.java
  87. 17 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderFilesMapper.java
  88. 17 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderHisMapper.java
  89. 17 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderMapper.java
  90. 31 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderProductHisMapper.java
  91. 31 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderProductMapper.java
  92. 31 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderShipHisMapper.java
  93. 31 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderShipMapper.java
  94. 9 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleQuotationProductMapper.java
  95. 5 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/xml/SaleOrderFilesMapper.xml
  96. 5 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/xml/SaleOrderHisMapper.xml
  97. 5 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/xml/SaleOrderMapper.xml
  98. 16 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/xml/SaleOrderProductHisMapper.xml
  99. 16 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/xml/SaleOrderProductMapper.xml
  100. 16 0
      srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/xml/SaleOrderShipHisMapper.xml

+ 2 - 2
jeecg-boot-base-core/src/main/java/org/jeecg/config/Swagger2Config.java

@@ -65,8 +65,8 @@ public class Swagger2Config implements WebMvcConfigurer {
                 .apiInfo(apiInfo())
                 .select()
                 //此包路径下的类,才生成接口文档
-//                .apis(RequestHandlerSelectors.basePackage("org.jeecg"))
-                .apis(RequestHandlerSelectors.basePackage("com.cuidian"))
+                .apis(RequestHandlerSelectors.basePackage("org.jeecg"))
+//                .apis(RequestHandlerSelectors.basePackage("com.cuidian"))
                 //加了ApiOperation注解的类,才生成接口文档
                 .apis(RequestHandlerSelectors.withClassAnnotation(RestController.class))
                 .apis(RequestHandlerSelectors.withMethodAnnotation(ApiOperation.class))

+ 2 - 1
jeecg-boot-base-core/src/main/java/org/jeecg/config/mybatis/MybatisPlusSaasConfig.java

@@ -30,7 +30,8 @@ import net.sf.jsqlparser.expression.LongValue;
  *
  */
 @Configuration
-@MapperScan(value={"org.jeecg.**.mapper*","com.cuidian.**.mapper*"})
+//@MapperScan(value={"org.jeecg.**.mapper*","com.cuidian.**.mapper*"})
+@MapperScan(value={"org.jeecg.**.mapper*"})
 public class MybatisPlusSaasConfig {
 
     /**

+ 1 - 1
jeecg-module-system/jeecg-system-start/src/main/java/org/jeecg/JeecgSystemApplication.java

@@ -20,7 +20,7 @@ import java.net.UnknownHostException;
 @Slf4j
 @SpringBootApplication
 //@EnableAutoConfiguration(exclude={MongoAutoConfiguration.class})
-@ComponentScan(basePackages = {"com.cuidian","org.jeecg"})
+//@ComponentScan(basePackages = {"com.cuidian","org.jeecg"})
 public class JeecgSystemApplication extends SpringBootServletInitializer {
 
     @Override

+ 55 - 4
srm-module-code/src/main/java/org/jeecg/modules/purCode/controller/PurInquiryFormController.java

@@ -15,6 +15,7 @@ import javax.servlet.http.HttpServletResponse;
 
 import org.apache.commons.lang.StringUtils;
 import org.jeecg.modules.baseCode.service.ISerialPatternService;
+import org.jeecg.modules.saleCode.vo.SaleInquiryFormAlert;
 import org.jeecgframework.poi.excel.ExcelImportUtil;
 import org.jeecgframework.poi.excel.def.NormalExcelConstants;
 import org.jeecgframework.poi.excel.entity.ExportParams;
@@ -90,8 +91,29 @@ public class PurInquiryFormController {
 		IPage<PurInquiryForm> pageList = purInquiryFormService.page(page, queryWrapper);
 		return Result.OK(pageList);
 	}
-	
-	/**
+
+	 /**
+	  * 用于采购报价单 新增时弹框
+	  *
+	  * @param saleInquiryForm
+	  * @param pageNo
+	  * @param pageSize
+	  * @param req
+	  * @return
+	  */
+	 @ApiOperation(value = "采购询价单-弹框分页列表查询", notes = "采购询价单-弹框分页列表查询")
+	 @GetMapping(value = "/alertPurInquiryList")
+	 public Result<IPage<SaleInquiryFormAlert>> alertPurInquiryList(SaleInquiryFormAlert saleInquiryForm,
+																	 @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
+																	 @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
+																	 HttpServletRequest req) {
+		 QueryWrapper<SaleInquiryFormAlert> queryWrapper = QueryGenerator.initQueryWrapper(saleInquiryForm, req.getParameterMap());
+		 Page<SaleInquiryFormAlert> page = new Page<SaleInquiryFormAlert>(pageNo, pageSize);
+		 IPage<SaleInquiryFormAlert> pageList = purInquiryFormProductService.alertPurInquiryList(page, queryWrapper);
+		 return Result.OK(pageList);
+	 }
+
+	 /**
 	 *   添加
 	 *
 	 * @param purInquiryFormPage
@@ -125,7 +147,7 @@ public class PurInquiryFormController {
 			purInquiryForm.setBillCode(result.getMessage());
 		}
 
-
+		purInquiryForm.setSubmit("0");
 		purInquiryFormService.saveMain(purInquiryForm, purInquiryFormPage.getPurInquiryFormShipList(),purInquiryFormPage.getPurInquiryFormProductList());
 		return Result.OK("添加成功!");
 	}
@@ -174,7 +196,36 @@ public class PurInquiryFormController {
 		purInquiryFormService.delMain(id);
 		return Result.OK("删除成功!");
 	}
-	
+
+	/**
+	 *  报价选定,通过项目查询船明细
+	 */
+	@GetMapping(value = "/getPurInquiryFormByProject")
+	public PurInquiryFormPage getShipByProject(@RequestParam(name="projectId",required=true) String projectId) {
+
+		QueryWrapper<PurInquiryForm> queryWrapper = new QueryWrapper();
+		queryWrapper.eq("inquiry_project",projectId);
+		queryWrapper.eq("del_flag","0");
+		queryWrapper.eq("submit","1");
+		List<PurInquiryForm> list = purInquiryFormService.list(queryWrapper);
+
+		if(list.size() > 0){
+			PurInquiryFormPage page = new PurInquiryFormPage();
+			BeanUtils.copyProperties(list.get(0), page);
+
+			List<PurInquiryFormShip> purInquiryFormShipList = purInquiryFormShipService.selectByMainId(list.get(0).getId());
+
+			List<PurInquiryFormProduct> purInquiryFormProductList = purInquiryFormProductService.selectByMainId(list.get(0).getId());
+
+			page.setPurInquiryFormProductList(purInquiryFormProductList);
+			page.setPurInquiryFormShipList(purInquiryFormShipList);
+			return page;
+
+		}else{
+			return null;
+		}
+	}
+
 	/**
 	 *  批量删除
 	 *

+ 288 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/controller/PurOrderController.java

@@ -0,0 +1,288 @@
+package org.jeecg.modules.purCode.controller;
+
+import java.io.UnsupportedEncodingException;
+import java.io.IOException;
+import java.net.URLDecoder;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+import java.util.Map;
+import java.util.stream.Collectors;
+import java.util.HashMap;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+
+import org.jeecgframework.poi.excel.ExcelImportUtil;
+import org.jeecgframework.poi.excel.def.NormalExcelConstants;
+import org.jeecgframework.poi.excel.entity.ExportParams;
+import org.jeecgframework.poi.excel.entity.ImportParams;
+import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
+import org.jeecg.common.system.vo.LoginUser;
+import org.apache.shiro.SecurityUtils;
+import org.jeecg.common.api.vo.Result;
+import org.jeecg.common.system.query.QueryGenerator;
+import org.jeecg.common.system.query.QueryRuleEnum;
+import org.jeecg.common.util.oConvertUtils;
+import org.jeecg.modules.purCode.entity.PurOrderShip;
+import org.jeecg.modules.purCode.entity.PurOrderProduct;
+import org.jeecg.modules.purCode.entity.PurOrder;
+import org.jeecg.modules.purCode.vo.PurOrderPage;
+import org.jeecg.modules.purCode.service.IPurOrderService;
+import org.jeecg.modules.purCode.service.IPurOrderShipService;
+import org.jeecg.modules.purCode.service.IPurOrderProductService;
+import org.springframework.beans.BeanUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+import org.springframework.web.servlet.ModelAndView;
+import org.springframework.web.multipart.MultipartFile;
+import org.springframework.web.multipart.MultipartHttpServletRequest;
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import lombok.extern.slf4j.Slf4j;
+import com.alibaba.fastjson.JSON;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.jeecg.common.aspect.annotation.AutoLog;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+
+
+ /**
+ * @Description: 采购订单
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Api(tags="采购订单")
+@RestController
+@RequestMapping("/purCode/purOrder")
+@Slf4j
+public class PurOrderController {
+	@Autowired
+	private IPurOrderService purOrderService;
+	@Autowired
+	private IPurOrderShipService purOrderShipService;
+	@Autowired
+	private IPurOrderProductService purOrderProductService;
+	
+	/**
+	 * 分页列表查询
+	 *
+	 * @param purOrder
+	 * @param pageNo
+	 * @param pageSize
+	 * @param req
+	 * @return
+	 */
+	//@AutoLog(value = "采购订单-分页列表查询")
+	@ApiOperation(value="采购订单-分页列表查询", notes="采购订单-分页列表查询")
+	@GetMapping(value = "/list")
+	public Result<IPage<PurOrder>> queryPageList(PurOrder purOrder,
+								   @RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
+								   @RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
+								   HttpServletRequest req) {
+        QueryWrapper<PurOrder> queryWrapper = QueryGenerator.initQueryWrapper(purOrder, req.getParameterMap());
+		Page<PurOrder> page = new Page<PurOrder>(pageNo, pageSize);
+		IPage<PurOrder> pageList = purOrderService.page(page, queryWrapper);
+		return Result.OK(pageList);
+	}
+	
+	/**
+	 *   添加
+	 *
+	 * @param purOrderPage
+	 * @return
+	 */
+	@AutoLog(value = "采购订单-添加")
+	@ApiOperation(value="采购订单-添加", notes="采购订单-添加")
+    @RequiresPermissions("purCode:pur_order:add")
+	@PostMapping(value = "/add")
+	public Result<String> add(@RequestBody PurOrderPage purOrderPage) {
+		PurOrder purOrder = new PurOrder();
+		BeanUtils.copyProperties(purOrderPage, purOrder);
+		purOrderService.saveMain(purOrder, purOrderPage.getPurOrderShipList(),purOrderPage.getPurOrderProductList());
+		return Result.OK("添加成功!");
+	}
+	
+	/**
+	 *  编辑
+	 *
+	 * @param purOrderPage
+	 * @return
+	 */
+	@AutoLog(value = "采购订单-编辑")
+	@ApiOperation(value="采购订单-编辑", notes="采购订单-编辑")
+    @RequiresPermissions("purCode:pur_order:edit")
+	@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
+	public Result<String> edit(@RequestBody PurOrderPage purOrderPage) {
+		PurOrder purOrder = new PurOrder();
+		BeanUtils.copyProperties(purOrderPage, purOrder);
+		PurOrder purOrderEntity = purOrderService.getById(purOrder.getId());
+		if(purOrderEntity==null) {
+			return Result.error("未找到对应数据");
+		}
+		purOrderService.updateMain(purOrder, purOrderPage.getPurOrderShipList(),purOrderPage.getPurOrderProductList());
+		return Result.OK("编辑成功!");
+	}
+	
+	/**
+	 *   通过id删除
+	 *
+	 * @param id
+	 * @return
+	 */
+	@AutoLog(value = "采购订单-通过id删除")
+	@ApiOperation(value="采购订单-通过id删除", notes="采购订单-通过id删除")
+    @RequiresPermissions("purCode:pur_order:delete")
+	@DeleteMapping(value = "/delete")
+	public Result<String> delete(@RequestParam(name="id",required=true) String id) {
+		purOrderService.delMain(id);
+		return Result.OK("删除成功!");
+	}
+	
+	/**
+	 *  批量删除
+	 *
+	 * @param ids
+	 * @return
+	 */
+	@AutoLog(value = "采购订单-批量删除")
+	@ApiOperation(value="采购订单-批量删除", notes="采购订单-批量删除")
+    @RequiresPermissions("purCode:pur_order:deleteBatch")
+	@DeleteMapping(value = "/deleteBatch")
+	public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
+		this.purOrderService.delBatchMain(Arrays.asList(ids.split(",")));
+		return Result.OK("批量删除成功!");
+	}
+	
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "采购订单-通过id查询")
+	@ApiOperation(value="采购订单-通过id查询", notes="采购订单-通过id查询")
+	@GetMapping(value = "/queryById")
+	public Result<PurOrder> queryById(@RequestParam(name="id",required=true) String id) {
+		PurOrder purOrder = purOrderService.getById(id);
+		if(purOrder==null) {
+			return Result.error("未找到对应数据");
+		}
+		return Result.OK(purOrder);
+
+	}
+	
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "采购订单子表 - 船明细通过主表ID查询")
+	@ApiOperation(value="采购订单子表 - 船明细主表ID查询", notes="采购订单子表 - 船明细-通主表ID查询")
+	@GetMapping(value = "/queryPurOrderShipByMainId")
+	public Result<List<PurOrderShip>> queryPurOrderShipListByMainId(@RequestParam(name="id",required=true) String id) {
+		List<PurOrderShip> purOrderShipList = purOrderShipService.selectByMainId(id);
+		return Result.OK(purOrderShipList);
+	}
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "采购订单子表 - 产品明细通过主表ID查询")
+	@ApiOperation(value="采购订单子表 - 产品明细主表ID查询", notes="采购订单子表 - 产品明细-通主表ID查询")
+	@GetMapping(value = "/queryPurOrderProductByMainId")
+	public Result<List<PurOrderProduct>> queryPurOrderProductListByMainId(@RequestParam(name="id",required=true) String id) {
+		List<PurOrderProduct> purOrderProductList = purOrderProductService.selectByMainId(id);
+		return Result.OK(purOrderProductList);
+	}
+
+    /**
+    * 导出excel
+    *
+    * @param request
+    * @param purOrder
+    */
+    @RequiresPermissions("purCode:pur_order:exportXls")
+    @RequestMapping(value = "/exportXls")
+    public ModelAndView exportXls(HttpServletRequest request, PurOrder purOrder) {
+      // Step.1 组装查询条件查询数据
+      QueryWrapper<PurOrder> queryWrapper = QueryGenerator.initQueryWrapper(purOrder, request.getParameterMap());
+      LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
+
+      //配置选中数据查询条件
+      String selections = request.getParameter("selections");
+      if(oConvertUtils.isNotEmpty(selections)) {
+         List<String> selectionList = Arrays.asList(selections.split(","));
+         queryWrapper.in("id",selectionList);
+      }
+      //Step.2 获取导出数据
+      List<PurOrder> purOrderList = purOrderService.list(queryWrapper);
+
+      // Step.3 组装pageList
+      List<PurOrderPage> pageList = new ArrayList<PurOrderPage>();
+      for (PurOrder main : purOrderList) {
+          PurOrderPage vo = new PurOrderPage();
+          BeanUtils.copyProperties(main, vo);
+          List<PurOrderShip> purOrderShipList = purOrderShipService.selectByMainId(main.getId());
+          vo.setPurOrderShipList(purOrderShipList);
+          List<PurOrderProduct> purOrderProductList = purOrderProductService.selectByMainId(main.getId());
+          vo.setPurOrderProductList(purOrderProductList);
+          pageList.add(vo);
+      }
+
+      // Step.4 AutoPoi 导出Excel
+      ModelAndView mv = new ModelAndView(new JeecgEntityExcelView());
+      mv.addObject(NormalExcelConstants.FILE_NAME, "采购订单列表");
+      mv.addObject(NormalExcelConstants.CLASS, PurOrderPage.class);
+      mv.addObject(NormalExcelConstants.PARAMS, new ExportParams("采购订单数据", "导出人:"+sysUser.getRealname(), "采购订单"));
+      mv.addObject(NormalExcelConstants.DATA_LIST, pageList);
+      return mv;
+    }
+
+    /**
+    * 通过excel导入数据
+    *
+    * @param request
+    * @param response
+    * @return
+    */
+    @RequiresPermissions("purCode:pur_order:importExcel")
+    @RequestMapping(value = "/importExcel", method = RequestMethod.POST)
+    public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
+      MultipartHttpServletRequest multipartRequest = (MultipartHttpServletRequest) request;
+      Map<String, MultipartFile> fileMap = multipartRequest.getFileMap();
+      for (Map.Entry<String, MultipartFile> entity : fileMap.entrySet()) {
+          // 获取上传文件对象
+          MultipartFile file = entity.getValue();
+          ImportParams params = new ImportParams();
+          params.setTitleRows(2);
+          params.setHeadRows(1);
+          params.setNeedSave(true);
+          try {
+              List<PurOrderPage> list = ExcelImportUtil.importExcel(file.getInputStream(), PurOrderPage.class, params);
+              for (PurOrderPage page : list) {
+                  PurOrder po = new PurOrder();
+                  BeanUtils.copyProperties(page, po);
+                  purOrderService.saveMain(po, page.getPurOrderShipList(),page.getPurOrderProductList());
+              }
+              return Result.OK("文件导入成功!数据行数:" + list.size());
+          } catch (Exception e) {
+              log.error(e.getMessage(),e);
+              return Result.error("文件导入失败:"+e.getMessage());
+          } finally {
+              try {
+                  file.getInputStream().close();
+              } catch (IOException e) {
+                  e.printStackTrace();
+              }
+          }
+      }
+      return Result.OK("文件导入失败!");
+    }
+
+}

+ 180 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/controller/PurOrderFilesController.java

@@ -0,0 +1,180 @@
+package org.jeecg.modules.purCode.controller;
+
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.stream.Collectors;
+import java.io.IOException;
+import java.io.UnsupportedEncodingException;
+import java.net.URLDecoder;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import org.jeecg.common.api.vo.Result;
+import org.jeecg.common.system.query.QueryGenerator;
+import org.jeecg.common.system.query.QueryRuleEnum;
+import org.jeecg.common.util.oConvertUtils;
+import org.jeecg.modules.purCode.entity.PurOrderFiles;
+import org.jeecg.modules.purCode.service.IPurOrderFilesService;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import lombok.extern.slf4j.Slf4j;
+
+import org.jeecgframework.poi.excel.ExcelImportUtil;
+import org.jeecgframework.poi.excel.def.NormalExcelConstants;
+import org.jeecgframework.poi.excel.entity.ExportParams;
+import org.jeecgframework.poi.excel.entity.ImportParams;
+import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
+import org.jeecg.common.system.base.controller.JeecgController;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+import org.springframework.web.multipart.MultipartFile;
+import org.springframework.web.multipart.MultipartHttpServletRequest;
+import org.springframework.web.servlet.ModelAndView;
+import com.alibaba.fastjson.JSON;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.jeecg.common.aspect.annotation.AutoLog;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+
+ /**
+ * @Description: 采购订单子表 - 文件
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Api(tags="采购订单子表 - 文件")
+@RestController
+@RequestMapping("/purCode/purOrderFiles")
+@Slf4j
+public class PurOrderFilesController extends JeecgController<PurOrderFiles, IPurOrderFilesService> {
+	@Autowired
+	private IPurOrderFilesService purOrderFilesService;
+	
+	/**
+	 * 分页列表查询
+	 *
+	 * @param purOrderFiles
+	 * @param pageNo
+	 * @param pageSize
+	 * @param req
+	 * @return
+	 */
+	//@AutoLog(value = "采购订单子表 - 文件-分页列表查询")
+	@ApiOperation(value="采购订单子表 - 文件-分页列表查询", notes="采购订单子表 - 文件-分页列表查询")
+	@GetMapping(value = "/list")
+	public Result<IPage<PurOrderFiles>> queryPageList(PurOrderFiles purOrderFiles,
+								   @RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
+								   @RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
+								   HttpServletRequest req) {
+        QueryWrapper<PurOrderFiles> queryWrapper = QueryGenerator.initQueryWrapper(purOrderFiles, req.getParameterMap());
+		Page<PurOrderFiles> page = new Page<PurOrderFiles>(pageNo, pageSize);
+		IPage<PurOrderFiles> pageList = purOrderFilesService.page(page, queryWrapper);
+		return Result.OK(pageList);
+	}
+	
+	/**
+	 *   添加
+	 *
+	 * @param purOrderFiles
+	 * @return
+	 */
+	@AutoLog(value = "采购订单子表 - 文件-添加")
+	@ApiOperation(value="采购订单子表 - 文件-添加", notes="采购订单子表 - 文件-添加")
+	@RequiresPermissions("purCode:pur_order_files:add")
+	@PostMapping(value = "/add")
+	public Result<String> add(@RequestBody PurOrderFiles purOrderFiles) {
+		purOrderFilesService.save(purOrderFiles);
+		return Result.OK("添加成功!");
+	}
+	
+	/**
+	 *  编辑
+	 *
+	 * @param purOrderFiles
+	 * @return
+	 */
+	@AutoLog(value = "采购订单子表 - 文件-编辑")
+	@ApiOperation(value="采购订单子表 - 文件-编辑", notes="采购订单子表 - 文件-编辑")
+	@RequiresPermissions("purCode:pur_order_files:edit")
+	@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
+	public Result<String> edit(@RequestBody PurOrderFiles purOrderFiles) {
+		purOrderFilesService.updateById(purOrderFiles);
+		return Result.OK("编辑成功!");
+	}
+	
+	/**
+	 *   通过id删除
+	 *
+	 * @param id
+	 * @return
+	 */
+	@AutoLog(value = "采购订单子表 - 文件-通过id删除")
+	@ApiOperation(value="采购订单子表 - 文件-通过id删除", notes="采购订单子表 - 文件-通过id删除")
+	@RequiresPermissions("purCode:pur_order_files:delete")
+	@DeleteMapping(value = "/delete")
+	public Result<String> delete(@RequestParam(name="id",required=true) String id) {
+		purOrderFilesService.removeById(id);
+		return Result.OK("删除成功!");
+	}
+	
+	/**
+	 *  批量删除
+	 *
+	 * @param ids
+	 * @return
+	 */
+	@AutoLog(value = "采购订单子表 - 文件-批量删除")
+	@ApiOperation(value="采购订单子表 - 文件-批量删除", notes="采购订单子表 - 文件-批量删除")
+	@RequiresPermissions("purCode:pur_order_files:deleteBatch")
+	@DeleteMapping(value = "/deleteBatch")
+	public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
+		this.purOrderFilesService.removeByIds(Arrays.asList(ids.split(",")));
+		return Result.OK("批量删除成功!");
+	}
+	
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "采购订单子表 - 文件-通过id查询")
+	@ApiOperation(value="采购订单子表 - 文件-通过id查询", notes="采购订单子表 - 文件-通过id查询")
+	@GetMapping(value = "/queryById")
+	public Result<PurOrderFiles> queryById(@RequestParam(name="id",required=true) String id) {
+		PurOrderFiles purOrderFiles = purOrderFilesService.getById(id);
+		if(purOrderFiles==null) {
+			return Result.error("未找到对应数据");
+		}
+		return Result.OK(purOrderFiles);
+	}
+
+    /**
+    * 导出excel
+    *
+    * @param request
+    * @param purOrderFiles
+    */
+    @RequiresPermissions("purCode:pur_order_files:exportXls")
+    @RequestMapping(value = "/exportXls")
+    public ModelAndView exportXls(HttpServletRequest request, PurOrderFiles purOrderFiles) {
+        return super.exportXls(request, purOrderFiles, PurOrderFiles.class, "采购订单子表 - 文件");
+    }
+
+    /**
+      * 通过excel导入数据
+    *
+    * @param request
+    * @param response
+    * @return
+    */
+    @RequiresPermissions("purCode:pur_order_files:importExcel")
+    @RequestMapping(value = "/importExcel", method = RequestMethod.POST)
+    public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
+        return super.importExcel(request, response, PurOrderFiles.class);
+    }
+
+}

+ 288 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/controller/PurOrderHisController.java

@@ -0,0 +1,288 @@
+package org.jeecg.modules.purCode.controller;
+
+import java.io.UnsupportedEncodingException;
+import java.io.IOException;
+import java.net.URLDecoder;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+import java.util.Map;
+import java.util.stream.Collectors;
+import java.util.HashMap;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+
+import org.jeecgframework.poi.excel.ExcelImportUtil;
+import org.jeecgframework.poi.excel.def.NormalExcelConstants;
+import org.jeecgframework.poi.excel.entity.ExportParams;
+import org.jeecgframework.poi.excel.entity.ImportParams;
+import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
+import org.jeecg.common.system.vo.LoginUser;
+import org.apache.shiro.SecurityUtils;
+import org.jeecg.common.api.vo.Result;
+import org.jeecg.common.system.query.QueryGenerator;
+import org.jeecg.common.system.query.QueryRuleEnum;
+import org.jeecg.common.util.oConvertUtils;
+import org.jeecg.modules.purCode.entity.PurOrderShipHis;
+import org.jeecg.modules.purCode.entity.PurOrderProductHis;
+import org.jeecg.modules.purCode.entity.PurOrderHis;
+import org.jeecg.modules.purCode.vo.PurOrderHisPage;
+import org.jeecg.modules.purCode.service.IPurOrderHisService;
+import org.jeecg.modules.purCode.service.IPurOrderShipHisService;
+import org.jeecg.modules.purCode.service.IPurOrderProductHisService;
+import org.springframework.beans.BeanUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+import org.springframework.web.servlet.ModelAndView;
+import org.springframework.web.multipart.MultipartFile;
+import org.springframework.web.multipart.MultipartHttpServletRequest;
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import lombok.extern.slf4j.Slf4j;
+import com.alibaba.fastjson.JSON;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.jeecg.common.aspect.annotation.AutoLog;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+
+
+ /**
+ * @Description: 采购订单(历史)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Api(tags="采购订单(历史)")
+@RestController
+@RequestMapping("/purCode/purOrderHis")
+@Slf4j
+public class PurOrderHisController {
+	@Autowired
+	private IPurOrderHisService purOrderHisService;
+	@Autowired
+	private IPurOrderShipHisService purOrderShipHisService;
+	@Autowired
+	private IPurOrderProductHisService purOrderProductHisService;
+	
+	/**
+	 * 分页列表查询
+	 *
+	 * @param purOrderHis
+	 * @param pageNo
+	 * @param pageSize
+	 * @param req
+	 * @return
+	 */
+	//@AutoLog(value = "采购订单(历史)-分页列表查询")
+	@ApiOperation(value="采购订单(历史)-分页列表查询", notes="采购订单(历史)-分页列表查询")
+	@GetMapping(value = "/list")
+	public Result<IPage<PurOrderHis>> queryPageList(PurOrderHis purOrderHis,
+								   @RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
+								   @RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
+								   HttpServletRequest req) {
+        QueryWrapper<PurOrderHis> queryWrapper = QueryGenerator.initQueryWrapper(purOrderHis, req.getParameterMap());
+		Page<PurOrderHis> page = new Page<PurOrderHis>(pageNo, pageSize);
+		IPage<PurOrderHis> pageList = purOrderHisService.page(page, queryWrapper);
+		return Result.OK(pageList);
+	}
+	
+	/**
+	 *   添加
+	 *
+	 * @param purOrderHisPage
+	 * @return
+	 */
+	@AutoLog(value = "采购订单(历史)-添加")
+	@ApiOperation(value="采购订单(历史)-添加", notes="采购订单(历史)-添加")
+    @RequiresPermissions("purCode:pur_order_his:add")
+	@PostMapping(value = "/add")
+	public Result<String> add(@RequestBody PurOrderHisPage purOrderHisPage) {
+		PurOrderHis purOrderHis = new PurOrderHis();
+		BeanUtils.copyProperties(purOrderHisPage, purOrderHis);
+		purOrderHisService.saveMain(purOrderHis, purOrderHisPage.getPurOrderShipHisList(),purOrderHisPage.getPurOrderProductHisList());
+		return Result.OK("添加成功!");
+	}
+	
+	/**
+	 *  编辑
+	 *
+	 * @param purOrderHisPage
+	 * @return
+	 */
+	@AutoLog(value = "采购订单(历史)-编辑")
+	@ApiOperation(value="采购订单(历史)-编辑", notes="采购订单(历史)-编辑")
+    @RequiresPermissions("purCode:pur_order_his:edit")
+	@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
+	public Result<String> edit(@RequestBody PurOrderHisPage purOrderHisPage) {
+		PurOrderHis purOrderHis = new PurOrderHis();
+		BeanUtils.copyProperties(purOrderHisPage, purOrderHis);
+		PurOrderHis purOrderHisEntity = purOrderHisService.getById(purOrderHis.getId());
+		if(purOrderHisEntity==null) {
+			return Result.error("未找到对应数据");
+		}
+		purOrderHisService.updateMain(purOrderHis, purOrderHisPage.getPurOrderShipHisList(),purOrderHisPage.getPurOrderProductHisList());
+		return Result.OK("编辑成功!");
+	}
+	
+	/**
+	 *   通过id删除
+	 *
+	 * @param id
+	 * @return
+	 */
+	@AutoLog(value = "采购订单(历史)-通过id删除")
+	@ApiOperation(value="采购订单(历史)-通过id删除", notes="采购订单(历史)-通过id删除")
+    @RequiresPermissions("purCode:pur_order_his:delete")
+	@DeleteMapping(value = "/delete")
+	public Result<String> delete(@RequestParam(name="id",required=true) String id) {
+		purOrderHisService.delMain(id);
+		return Result.OK("删除成功!");
+	}
+	
+	/**
+	 *  批量删除
+	 *
+	 * @param ids
+	 * @return
+	 */
+	@AutoLog(value = "采购订单(历史)-批量删除")
+	@ApiOperation(value="采购订单(历史)-批量删除", notes="采购订单(历史)-批量删除")
+    @RequiresPermissions("purCode:pur_order_his:deleteBatch")
+	@DeleteMapping(value = "/deleteBatch")
+	public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
+		this.purOrderHisService.delBatchMain(Arrays.asList(ids.split(",")));
+		return Result.OK("批量删除成功!");
+	}
+	
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "采购订单(历史)-通过id查询")
+	@ApiOperation(value="采购订单(历史)-通过id查询", notes="采购订单(历史)-通过id查询")
+	@GetMapping(value = "/queryById")
+	public Result<PurOrderHis> queryById(@RequestParam(name="id",required=true) String id) {
+		PurOrderHis purOrderHis = purOrderHisService.getById(id);
+		if(purOrderHis==null) {
+			return Result.error("未找到对应数据");
+		}
+		return Result.OK(purOrderHis);
+
+	}
+	
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "采购订单子表 - 船明细(历史)通过主表ID查询")
+	@ApiOperation(value="采购订单子表 - 船明细(历史)主表ID查询", notes="采购订单子表 - 船明细(历史)-通主表ID查询")
+	@GetMapping(value = "/queryPurOrderShipHisByMainId")
+	public Result<List<PurOrderShipHis>> queryPurOrderShipHisListByMainId(@RequestParam(name="id",required=true) String id) {
+		List<PurOrderShipHis> purOrderShipHisList = purOrderShipHisService.selectByMainId(id);
+		return Result.OK(purOrderShipHisList);
+	}
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "采购订单子表 - 产品明细(历史)通过主表ID查询")
+	@ApiOperation(value="采购订单子表 - 产品明细(历史)主表ID查询", notes="采购订单子表 - 产品明细(历史)-通主表ID查询")
+	@GetMapping(value = "/queryPurOrderProductHisByMainId")
+	public Result<List<PurOrderProductHis>> queryPurOrderProductHisListByMainId(@RequestParam(name="id",required=true) String id) {
+		List<PurOrderProductHis> purOrderProductHisList = purOrderProductHisService.selectByMainId(id);
+		return Result.OK(purOrderProductHisList);
+	}
+
+    /**
+    * 导出excel
+    *
+    * @param request
+    * @param purOrderHis
+    */
+    @RequiresPermissions("purCode:pur_order_his:exportXls")
+    @RequestMapping(value = "/exportXls")
+    public ModelAndView exportXls(HttpServletRequest request, PurOrderHis purOrderHis) {
+      // Step.1 组装查询条件查询数据
+      QueryWrapper<PurOrderHis> queryWrapper = QueryGenerator.initQueryWrapper(purOrderHis, request.getParameterMap());
+      LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
+
+      //配置选中数据查询条件
+      String selections = request.getParameter("selections");
+      if(oConvertUtils.isNotEmpty(selections)) {
+         List<String> selectionList = Arrays.asList(selections.split(","));
+         queryWrapper.in("id",selectionList);
+      }
+      //Step.2 获取导出数据
+      List<PurOrderHis> purOrderHisList = purOrderHisService.list(queryWrapper);
+
+      // Step.3 组装pageList
+      List<PurOrderHisPage> pageList = new ArrayList<PurOrderHisPage>();
+      for (PurOrderHis main : purOrderHisList) {
+          PurOrderHisPage vo = new PurOrderHisPage();
+          BeanUtils.copyProperties(main, vo);
+          List<PurOrderShipHis> purOrderShipHisList = purOrderShipHisService.selectByMainId(main.getId());
+          vo.setPurOrderShipHisList(purOrderShipHisList);
+          List<PurOrderProductHis> purOrderProductHisList = purOrderProductHisService.selectByMainId(main.getId());
+          vo.setPurOrderProductHisList(purOrderProductHisList);
+          pageList.add(vo);
+      }
+
+      // Step.4 AutoPoi 导出Excel
+      ModelAndView mv = new ModelAndView(new JeecgEntityExcelView());
+      mv.addObject(NormalExcelConstants.FILE_NAME, "采购订单(历史)列表");
+      mv.addObject(NormalExcelConstants.CLASS, PurOrderHisPage.class);
+      mv.addObject(NormalExcelConstants.PARAMS, new ExportParams("采购订单(历史)数据", "导出人:"+sysUser.getRealname(), "采购订单(历史)"));
+      mv.addObject(NormalExcelConstants.DATA_LIST, pageList);
+      return mv;
+    }
+
+    /**
+    * 通过excel导入数据
+    *
+    * @param request
+    * @param response
+    * @return
+    */
+    @RequiresPermissions("purCode:pur_order_his:importExcel")
+    @RequestMapping(value = "/importExcel", method = RequestMethod.POST)
+    public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
+      MultipartHttpServletRequest multipartRequest = (MultipartHttpServletRequest) request;
+      Map<String, MultipartFile> fileMap = multipartRequest.getFileMap();
+      for (Map.Entry<String, MultipartFile> entity : fileMap.entrySet()) {
+          // 获取上传文件对象
+          MultipartFile file = entity.getValue();
+          ImportParams params = new ImportParams();
+          params.setTitleRows(2);
+          params.setHeadRows(1);
+          params.setNeedSave(true);
+          try {
+              List<PurOrderHisPage> list = ExcelImportUtil.importExcel(file.getInputStream(), PurOrderHisPage.class, params);
+              for (PurOrderHisPage page : list) {
+                  PurOrderHis po = new PurOrderHis();
+                  BeanUtils.copyProperties(page, po);
+                  purOrderHisService.saveMain(po, page.getPurOrderShipHisList(),page.getPurOrderProductHisList());
+              }
+              return Result.OK("文件导入成功!数据行数:" + list.size());
+          } catch (Exception e) {
+              log.error(e.getMessage(),e);
+              return Result.error("文件导入失败:"+e.getMessage());
+          } finally {
+              try {
+                  file.getInputStream().close();
+              } catch (IOException e) {
+                  e.printStackTrace();
+              }
+          }
+      }
+      return Result.OK("文件导入失败!");
+    }
+
+}

+ 84 - 19
srm-module-code/src/main/java/org/jeecg/modules/purCode/controller/PurPurchaseQuotationController.java

@@ -1,14 +1,10 @@
 package org.jeecg.modules.purCode.controller;
 
-import java.io.UnsupportedEncodingException;
 import java.io.IOException;
-import java.net.URLDecoder;
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.List;
 import java.util.Map;
-import java.util.stream.Collectors;
-import java.util.HashMap;
 
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
@@ -16,6 +12,8 @@ import javax.servlet.http.HttpServletResponse;
 import org.apache.commons.lang.StringUtils;
 import org.jeecg.modules.baseCode.service.ISerialPatternService;
 import org.jeecg.modules.purCode.entity.PurPurchaseQuotation;
+import org.jeecg.modules.purCode.vo.SupplierQuotationDetails;
+import org.jeecg.modules.saleCode.vo.SaleInquiryFormAlert;
 import org.jeecgframework.poi.excel.ExcelImportUtil;
 import org.jeecgframework.poi.excel.def.NormalExcelConstants;
 import org.jeecgframework.poi.excel.entity.ExportParams;
@@ -25,14 +23,13 @@ import org.jeecg.common.system.vo.LoginUser;
 import org.apache.shiro.SecurityUtils;
 import org.jeecg.common.api.vo.Result;
 import org.jeecg.common.system.query.QueryGenerator;
-import org.jeecg.common.system.query.QueryRuleEnum;
 import org.jeecg.common.util.oConvertUtils;
 import org.jeecg.modules.purCode.entity.PurPurchaseQuotationShip;
-import org.jeecg.modules.purCode.entity.PurPurchaseInquiryProduct;
+import org.jeecg.modules.purCode.entity.PurPurchaseQuotationProduct;
 import org.jeecg.modules.purCode.vo.PurPurchaseQuotationPage;
 import org.jeecg.modules.purCode.service.IPurPurchaseQuotationService;
 import org.jeecg.modules.purCode.service.IPurPurchaseQuotationShipService;
-import org.jeecg.modules.purCode.service.IPurPurchaseInquiryProductService;
+import org.jeecg.modules.purCode.service.IPurPurchaseQuotationProductService;
 import org.springframework.beans.BeanUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.web.bind.annotation.*;
@@ -43,7 +40,6 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import lombok.extern.slf4j.Slf4j;
-import com.alibaba.fastjson.JSON;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
 import org.jeecg.common.aspect.annotation.AutoLog;
@@ -66,7 +62,7 @@ public class PurPurchaseQuotationController {
 	@Autowired
 	private IPurPurchaseQuotationShipService purPurchaseQuotationShipService;
 	@Autowired
-	private IPurPurchaseInquiryProductService purPurchaseInquiryProductService;
+	private IPurPurchaseQuotationProductService purPurchaseInquiryProductService;
 	 @Autowired
 	 private ISerialPatternService serialPatternService;
 	/**
@@ -90,8 +86,76 @@ public class PurPurchaseQuotationController {
 		IPage<PurPurchaseQuotation> pageList = purPurchaseQuotationService.page(page, queryWrapper);
 		return Result.OK(pageList);
 	}
-	
-	/**
+
+	 /**
+	  * 供应商报价明细
+	  *
+	  * @param pageNo
+	  * @param pageSize
+	  * @param req
+	  * @return
+	  */
+	 @ApiOperation(value = "供应商报价明细", notes = "供应商报价明细")
+	 @GetMapping(value = "/supplierQuotationDetails")
+	 public Result<IPage<SupplierQuotationDetails>> supplierQuotationDetails(@RequestParam(name = "quotationProject") String quotationProject,
+																	@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
+																	@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
+																	HttpServletRequest req) {
+		 SupplierQuotationDetails saleInquiryForm = new SupplierQuotationDetails();
+		 saleInquiryForm.setQuotationProject(quotationProject);
+
+		 QueryWrapper<SupplierQuotationDetails> queryWrapper = QueryGenerator.initQueryWrapper(saleInquiryForm, req.getParameterMap());
+		 Page<SupplierQuotationDetails> page = new Page<SupplierQuotationDetails>(-1,-1);
+		 IPage<SupplierQuotationDetails> pageList = purPurchaseInquiryProductService.supplierQuotationDetails(page, queryWrapper);
+		 return Result.OK(pageList);
+	 }
+
+	 /**
+	  * 供应商报价明细弹框
+	  *
+	  * @param pageNo
+	  * @param pageSize
+	  * @param req
+	  * @return
+	  */
+	 @ApiOperation(value = "供应商报价明细弹框", notes = "供应商报价明细弹框")
+	 @GetMapping(value = "/supplierQuotationDetails2")
+	 public Result<IPage<SupplierQuotationDetails>> supplierQuotationDetails2(SupplierQuotationDetails saleInquiryForm,
+																	@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
+																	@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
+																	HttpServletRequest req) {
+
+		 QueryWrapper<SupplierQuotationDetails> queryWrapper = QueryGenerator.initQueryWrapper(saleInquiryForm, req.getParameterMap());
+		 Page<SupplierQuotationDetails> page = new Page<SupplierQuotationDetails>(pageNo,pageSize);
+		 IPage<SupplierQuotationDetails> pageList = purPurchaseInquiryProductService.supplierQuotationDetails(page, queryWrapper);
+		 return Result.OK(pageList);
+	 }
+
+ /**
+	  * 供应商报价汇总金额
+	  *
+	  * @param pageNo
+	  * @param pageSize
+	  * @param req
+	  * @return
+	  */
+	 @ApiOperation(value = "供应商报价汇总金额", notes = "供应商报价汇总金额")
+	 @GetMapping(value = "/supplierQuotationTotal")
+	 public Result<IPage<SupplierQuotationDetails>> supplierQuotationTotal(@RequestParam(name = "quotationProject") String quotationProject,
+																	@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
+																	@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
+																	HttpServletRequest req) {
+		 SupplierQuotationDetails saleInquiryForm = new SupplierQuotationDetails();
+		 saleInquiryForm.setQuotationProject(quotationProject);
+
+		 QueryWrapper<SupplierQuotationDetails> queryWrapper = QueryGenerator.initQueryWrapper(saleInquiryForm, req.getParameterMap());
+		 Page<SupplierQuotationDetails> page = new Page<SupplierQuotationDetails>(-1,-1);
+		 IPage<SupplierQuotationDetails> pageList = purPurchaseInquiryProductService.supplierQuotationTotal(page, queryWrapper);
+		 return Result.OK(pageList);
+	 }
+
+
+	 /**
 	 *   添加
 	 *
 	 * @param purPurchaseQuotationPage
@@ -125,7 +189,8 @@ public class PurPurchaseQuotationController {
 			purPurchaseQuotation.setBillCode(result.getMessage());
 		}
 
-		purPurchaseQuotationService.saveMain(purPurchaseQuotation, purPurchaseQuotationPage.getPurPurchaseQuotationShipList(),purPurchaseQuotationPage.getPurPurchaseInquiryProductList());
+		purPurchaseQuotation.setSubmit("0");
+		purPurchaseQuotationService.saveMain(purPurchaseQuotation, purPurchaseQuotationPage.getPurPurchaseQuotationShipList(),purPurchaseQuotationPage.getPurPurchaseQuotationProductList());
 		return Result.OK("添加成功!");
 	}
 	
@@ -146,7 +211,7 @@ public class PurPurchaseQuotationController {
 		if(purPurchaseQuotationEntity==null) {
 			return Result.error("未找到对应数据");
 		}
-		purPurchaseQuotationService.updateMain(purPurchaseQuotation, purPurchaseQuotationPage.getPurPurchaseQuotationShipList(),purPurchaseQuotationPage.getPurPurchaseInquiryProductList());
+		purPurchaseQuotationService.updateMain(purPurchaseQuotation, purPurchaseQuotationPage.getPurPurchaseQuotationShipList(),purPurchaseQuotationPage.getPurPurchaseQuotationProductList());
 		return Result.OK("编辑成功!");
 	}
 	
@@ -333,9 +398,9 @@ public class PurPurchaseQuotationController {
 	//@AutoLog(value = "采购价单子表 - 产品明细通过主表ID查询")
 	@ApiOperation(value="采购价单子表 - 产品明细主表ID查询", notes="采购价单子表 - 产品明细-通主表ID查询")
 	@GetMapping(value = "/queryPurPurchaseInquiryProductByMainId")
-	public Result<List<PurPurchaseInquiryProduct>> queryPurPurchaseInquiryProductListByMainId(@RequestParam(name="id",required=true) String id) {
-		List<PurPurchaseInquiryProduct> purPurchaseInquiryProductList = purPurchaseInquiryProductService.selectByMainId(id);
-		return Result.OK(purPurchaseInquiryProductList);
+	public Result<List<PurPurchaseQuotationProduct>> queryPurPurchaseInquiryProductListByMainId(@RequestParam(name="id",required=true) String id) {
+		List<PurPurchaseQuotationProduct> purPurchaseQuotationProductList = purPurchaseInquiryProductService.selectByMainId(id);
+		return Result.OK(purPurchaseQuotationProductList);
 	}
 
     /**
@@ -367,8 +432,8 @@ public class PurPurchaseQuotationController {
           BeanUtils.copyProperties(main, vo);
           List<PurPurchaseQuotationShip> purPurchaseQuotationShipList = purPurchaseQuotationShipService.selectByMainId(main.getId());
           vo.setPurPurchaseQuotationShipList(purPurchaseQuotationShipList);
-          List<PurPurchaseInquiryProduct> purPurchaseInquiryProductList = purPurchaseInquiryProductService.selectByMainId(main.getId());
-          vo.setPurPurchaseInquiryProductList(purPurchaseInquiryProductList);
+          List<PurPurchaseQuotationProduct> purPurchaseQuotationProductList = purPurchaseInquiryProductService.selectByMainId(main.getId());
+          vo.setPurPurchaseQuotationProductList(purPurchaseQuotationProductList);
           pageList.add(vo);
       }
 
@@ -405,7 +470,7 @@ public class PurPurchaseQuotationController {
               for (PurPurchaseQuotationPage page : list) {
                   PurPurchaseQuotation po = new PurPurchaseQuotation();
                   BeanUtils.copyProperties(page, po);
-                  purPurchaseQuotationService.saveMain(po, page.getPurPurchaseQuotationShipList(),page.getPurPurchaseInquiryProductList());
+                  purPurchaseQuotationService.saveMain(po, page.getPurPurchaseQuotationShipList(),page.getPurPurchaseQuotationProductList());
               }
               return Result.OK("文件导入成功!数据行数:" + list.size());
           } catch (Exception e) {

+ 1 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/controller/PurQuotationSelectionController.java

@@ -126,6 +126,7 @@ public class PurQuotationSelectionController {
             }
             purQuotationSelection.setBillCode(result.getMessage());
         }
+        purQuotationSelection.setSubmit("0");
 
         purQuotationSelectionService.saveMain(purQuotationSelection, purQuotationSelectionPage.getPurQuotationSelectionShipList(), purQuotationSelectionPage.getPurQuotationSelectionProductList());
         return Result.OK("添加成功!");

+ 12 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurInquiryForm.java

@@ -52,6 +52,7 @@ public class PurInquiryForm implements Serializable {
 	/**状态(1-结束,0-询价中)*/
 	@Excel(name = "状态(1-结束,0-询价中)", width = 15)
     @ApiModelProperty(value = "状态(1-结束,0-询价中)")
+    @Dict(dicCode = "purchase_inquiry_status")
     private Integer status;
 	/**删除状态(0-正常,1-已删除)*/
 	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
@@ -61,6 +62,7 @@ public class PurInquiryForm implements Serializable {
 	/**提交(1是 0否)*/
 	@Excel(name = "提交(1是 0否)", width = 15)
     @ApiModelProperty(value = "提交(1是 0否)")
+    @Dict(dicCode = "yes_or_no")
     private String submit;
 	/**单据日期(bill date)*/
 	@Excel(name = "单据日期(bill date)", width = 15, format = "yyyy-MM-dd")
@@ -107,6 +109,7 @@ public class PurInquiryForm implements Serializable {
 	/**优先级(priority)*/
 	@Excel(name = "优先级(priority)", width = 15)
     @ApiModelProperty(value = "优先级(priority)")
+    @Dict(dicCode = "priority")
     private String priority;
 	/**产品分类(production class)*/
 	@Excel(name = "产品分类(production class)", width = 15)
@@ -124,6 +127,8 @@ public class PurInquiryForm implements Serializable {
 	@Excel(name = "付款条件(payment terms)", width = 15)
     @ApiModelProperty(value = "付款条件(payment terms)")
     private String paymentTerms;
+	//付款条件-二段信息
+    private String paymentTermsInfo;
 	/**交货地点(place of delivery)*/
 	@Excel(name = "交货地点(place of delivery)", width = 15)
     @ApiModelProperty(value = "交货地点(place of delivery)")
@@ -145,7 +150,9 @@ public class PurInquiryForm implements Serializable {
 	/**采购询价组(procurement inquiry team)*/
 	@Excel(name = "采购询价组(procurement inquiry team)", width = 15)
     @ApiModelProperty(value = "采购询价组(procurement inquiry team)")
+    @Dict(dictTable = "sys_depart", dicCode = "id", dicText = "depart_name")
     private String inquiryTeam;
+    private String inquiryTeamName;
 	/**附件(attachs)*/
 	@Excel(name = "附件(attachs)", width = 15)
     @ApiModelProperty(value = "附件(attachs)")
@@ -154,4 +161,9 @@ public class PurInquiryForm implements Serializable {
 	@Excel(name = "询价备注(inquiry notes)", width = 15)
     @ApiModelProperty(value = "询价备注(inquiry notes)")
     private String inquiryNotes;
+
+    //来源单号(销售询价单)
+    private String sourceCode;
+    //来源销售询价单文件
+    private String saleAttachs;
 }

+ 3 - 3
srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurInquiryFormProduct.java

@@ -61,9 +61,9 @@ public class PurInquiryFormProduct implements Serializable {
     @ApiModelProperty(value = "表头主键(采购询价单)")
     private String headId;
 	/**交期*/
-	@Excel(name = "交期", width = 20, format = "yyyy-MM-dd HH:mm:ss")
-	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
-    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	@Excel(name = "交期", width = 20, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
     @ApiModelProperty(value = "交期")
     private Date deliveryTime;
 	/**产品id*/

+ 191 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrder.java

@@ -0,0 +1,191 @@
+package org.jeecg.modules.purCode.entity;
+
+import java.io.Serializable;
+import java.io.UnsupportedEncodingException;
+import java.util.Date;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import org.jeecg.common.aspect.annotation.Dict;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+
+/**
+ * @Description: 采购订单
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@ApiModel(value="pur_order对象", description="采购订单")
+@Data
+@TableName("pur_order")
+public class PurOrder implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**客户确认(1-已确认,0-未确认)*/
+	@Excel(name = "客户确认(1-已确认,0-未确认)", width = 15)
+    @ApiModelProperty(value = "客户确认(1-已确认,0-未确认)")
+    private Integer status;
+	/**提交(submit)1是0否*/
+	@Excel(name = "提交(submit)1是0否", width = 15)
+    @ApiModelProperty(value = "提交(submit)1是0否")
+    private String submit;
+	/**关闭(close)1是0否*/
+	@Excel(name = "关闭(close)1是0否", width = 15)
+    @ApiModelProperty(value = "关闭(close)1是0否")
+    private String close;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+    @ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+	/**单据日期*/
+	@Excel(name = "单据日期", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "单据日期")
+    private Date billDate;
+	/**单据编码*/
+	@Excel(name = "单据编码", width = 15)
+    @ApiModelProperty(value = "单据编码")
+    private String billCode;
+	/**项目(project)*/
+	@Excel(name = "项目(project)", width = 15)
+    @ApiModelProperty(value = "项目(project)")
+    private String project;
+	/**项目名称*/
+	@Excel(name = "项目名称", width = 15)
+    @ApiModelProperty(value = "项目名称")
+    private String projectName;
+	/**供应商(supplier)*/
+	@Excel(name = "供应商(supplier)", width = 15)
+    @ApiModelProperty(value = "供应商(supplier)")
+    private String supplier;
+	/**供应商名称*/
+	@Excel(name = "供应商名称", width = 15)
+    @ApiModelProperty(value = "供应商名称")
+    private String supplierName;
+	/**业务类型(busyness type)*/
+	@Excel(name = "业务类型(busyness type)", width = 15)
+    @ApiModelProperty(value = "业务类型(busyness type)")
+    private String busynessType;
+	/**优先级(priority)*/
+	@Excel(name = "优先级(priority)", width = 15)
+    @ApiModelProperty(value = "优先级(priority)")
+    private String priority;
+	/**产品分类(production class)*/
+	@Excel(name = "产品分类(production class)", width = 15)
+    @ApiModelProperty(value = "产品分类(production class)")
+    private String productionClass;
+	/**机型(model)*/
+	@Excel(name = "机型(model)", width = 15)
+    @ApiModelProperty(value = "机型(model)")
+    private String model;
+	/**厂家(maker)*/
+	@Excel(name = "厂家(maker)", width = 15)
+    @ApiModelProperty(value = "厂家(maker)")
+    private String maker;
+	/**贸易条款(trade Terms)*/
+	@Excel(name = "贸易条款(trade Terms)", width = 15)
+    @ApiModelProperty(value = "贸易条款(trade Terms)")
+    private String tradeTerms;
+	/**是否出口(export)*/
+	@Excel(name = "是否出口(export)", width = 15)
+    @ApiModelProperty(value = "是否出口(export)")
+    private String isExport;
+	/**包装要求(packageb requirement)*/
+	@Excel(name = "包装要求(packageb requirement)", width = 15)
+    @ApiModelProperty(value = "包装要求(packageb requirement)")
+    private String packagebRequirement;
+	/**收件人(recipient)*/
+	@Excel(name = "收件人(recipient)", width = 15)
+    @ApiModelProperty(value = "收件人(recipient)")
+    private String recipient;
+	/**收件人电话(recipient tel)*/
+	@Excel(name = "收件人电话(recipient tel)", width = 15)
+    @ApiModelProperty(value = "收件人电话(recipient tel)")
+    private String recipientTel;
+	/**收件人地址(recipient address)*/
+	@Excel(name = "收件人地址(recipient address)", width = 15)
+    @ApiModelProperty(value = "收件人地址(recipient address)")
+    private String recipientAddress;
+	/**付款条件(payment terms)*/
+	@Excel(name = "付款条件(payment terms)", width = 15)
+    @ApiModelProperty(value = "付款条件(payment terms)")
+    private String paymentTerms;
+	/**发货方式(delivery)*/
+	@Excel(name = "发货方式(delivery)", width = 15)
+    @ApiModelProperty(value = "发货方式(delivery)")
+    private String delivery;
+	/**质保期(warranty period)/月*/
+	@Excel(name = "质保期(warranty period)/月", width = 15)
+    @ApiModelProperty(value = "质保期(warranty period)/月")
+    private String warrantyPeriod;
+	/**质保条款(warranty terms)*/
+	@Excel(name = "质保条款(warranty terms)", width = 15)
+    @ApiModelProperty(value = "质保条款(warranty terms)")
+    private String warrantyTerms;
+	/**汇率(exchange rate)*/
+	@Excel(name = "汇率(exchange rate)", width = 15)
+    @ApiModelProperty(value = "汇率(exchange rate)")
+    private java.math.BigDecimal exchangeRate;
+	/**采购员(purchaseman)*/
+	@Excel(name = "采购员(purchaseman)", width = 15)
+    @ApiModelProperty(value = "采购员(purchaseman)")
+    private String purchaseman;
+	/**采购部门(purchase department)*/
+	@Excel(name = "采购部门(purchase department)", width = 15)
+    @ApiModelProperty(value = "采购部门(purchase department)")
+    private String purchaseDepartment;
+	/**币种(currency)*/
+	@Excel(name = "币种(currency)", width = 15)
+    @ApiModelProperty(value = "币种(currency)")
+    private String currency;
+	/**备注(notes)*/
+	@Excel(name = "备注(notes)", width = 15)
+    @ApiModelProperty(value = "备注(notes)")
+    private String notes;
+	/**附件(attachs)*/
+	@Excel(name = "附件(attachs)", width = 15)
+    @ApiModelProperty(value = "附件(attachs)")
+    private String attachs;
+	/**版本号*/
+	@Excel(name = "版本号", width = 15)
+    @ApiModelProperty(value = "版本号")
+    private String version;
+	/**来源*/
+	@Excel(name = "来源", width = 15)
+    @ApiModelProperty(value = "来源")
+    private String sourceCode;
+	/**来源2*/
+	@Excel(name = "来源2", width = 15)
+    @ApiModelProperty(value = "来源2")
+    private String sourceCode2;
+}

+ 85 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrderFiles.java

@@ -0,0 +1,85 @@
+package org.jeecg.modules.purCode.entity;
+
+import java.io.Serializable;
+import java.io.UnsupportedEncodingException;
+import java.util.Date;
+import java.math.BigDecimal;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import org.jeecg.common.aspect.annotation.Dict;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.EqualsAndHashCode;
+import lombok.experimental.Accessors;
+
+/**
+ * @Description: 采购订单子表 - 文件
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Data
+@TableName("pur_order_files")
+@Accessors(chain = true)
+@EqualsAndHashCode(callSuper = false)
+@ApiModel(value="pur_order_files对象", description="采购订单子表 - 文件")
+public class PurOrderFiles implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**状态(1-启用,0-停用)*/
+	@Excel(name = "状态(1-启用,0-停用)", width = 15)
+    @ApiModelProperty(value = "状态(1-启用,0-停用)")
+    private Integer status;
+	/**附件(attachs)*/
+	@Excel(name = "附件(attachs)", width = 15)
+    @ApiModelProperty(value = "附件(attachs)")
+    private String attachs;
+	/**附件名称*/
+	@Excel(name = "附件名称", width = 15)
+    @ApiModelProperty(value = "附件名称")
+    private String name;
+	/**
+1扫描合同 2基础协议*/
+	@Excel(name = "
+1扫描合同 2基础协议", width = 15)
+    @ApiModelProperty(value = "
+1扫描合同 2基础协议")
+    private java.lang.String type;
+	/**采购订单主表主键*/
+	@Excel(name = "采购订单主表主键", width = 15)
+    @ApiModelProperty(value = "采购订单主表主键")
+    private java.lang.String headId;
+	/**删除标记*/
+	@Excel(name = "删除标记", width = 15)
+    @ApiModelProperty(value = "删除标记")
+    @TableLogic
+    private java.lang.Integer delFlag;
+}

+ 195 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrderHis.java

@@ -0,0 +1,195 @@
+package org.jeecg.modules.purCode.entity;
+
+import java.io.Serializable;
+import java.io.UnsupportedEncodingException;
+import java.util.Date;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import org.jeecg.common.aspect.annotation.Dict;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+
+/**
+ * @Description: 采购订单(历史)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@ApiModel(value="pur_order_his对象", description="采购订单(历史)")
+@Data
+@TableName("pur_order_his")
+public class PurOrderHis implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**历史主键*/
+	@Excel(name = "历史主键", width = 15)
+    @ApiModelProperty(value = "历史主键")
+    private String hisId;
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**客户确认(1-已确认,0-未确认)*/
+	@Excel(name = "客户确认(1-已确认,0-未确认)", width = 15)
+    @ApiModelProperty(value = "客户确认(1-已确认,0-未确认)")
+    private Integer status;
+	/**提交(submit)1是0否*/
+	@Excel(name = "提交(submit)1是0否", width = 15)
+    @ApiModelProperty(value = "提交(submit)1是0否")
+    private String submit;
+	/**关闭(close)1是0否*/
+	@Excel(name = "关闭(close)1是0否", width = 15)
+    @ApiModelProperty(value = "关闭(close)1是0否")
+    private String close;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+    @ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+	/**单据日期*/
+	@Excel(name = "单据日期", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "单据日期")
+    private Date billDate;
+	/**单据编码*/
+	@Excel(name = "单据编码", width = 15)
+    @ApiModelProperty(value = "单据编码")
+    private String billCode;
+	/**项目(project)*/
+	@Excel(name = "项目(project)", width = 15)
+    @ApiModelProperty(value = "项目(project)")
+    private String project;
+	/**项目名称*/
+	@Excel(name = "项目名称", width = 15)
+    @ApiModelProperty(value = "项目名称")
+    private String projectName;
+	/**供应商(supplier)*/
+	@Excel(name = "供应商(supplier)", width = 15)
+    @ApiModelProperty(value = "供应商(supplier)")
+    private String supplier;
+	/**供应商名称*/
+	@Excel(name = "供应商名称", width = 15)
+    @ApiModelProperty(value = "供应商名称")
+    private String supplierName;
+	/**业务类型(busyness type)*/
+	@Excel(name = "业务类型(busyness type)", width = 15)
+    @ApiModelProperty(value = "业务类型(busyness type)")
+    private String busynessType;
+	/**优先级(priority)*/
+	@Excel(name = "优先级(priority)", width = 15)
+    @ApiModelProperty(value = "优先级(priority)")
+    private String priority;
+	/**产品分类(production class)*/
+	@Excel(name = "产品分类(production class)", width = 15)
+    @ApiModelProperty(value = "产品分类(production class)")
+    private String productionClass;
+	/**机型(model)*/
+	@Excel(name = "机型(model)", width = 15)
+    @ApiModelProperty(value = "机型(model)")
+    private String model;
+	/**厂家(maker)*/
+	@Excel(name = "厂家(maker)", width = 15)
+    @ApiModelProperty(value = "厂家(maker)")
+    private String maker;
+	/**贸易条款(trade Terms)*/
+	@Excel(name = "贸易条款(trade Terms)", width = 15)
+    @ApiModelProperty(value = "贸易条款(trade Terms)")
+    private String tradeTerms;
+	/**是否出口(export)*/
+	@Excel(name = "是否出口(export)", width = 15)
+    @ApiModelProperty(value = "是否出口(export)")
+    private String isExport;
+	/**包装要求(packageb requirement)*/
+	@Excel(name = "包装要求(packageb requirement)", width = 15)
+    @ApiModelProperty(value = "包装要求(packageb requirement)")
+    private String packagebRequirement;
+	/**收件人(recipient)*/
+	@Excel(name = "收件人(recipient)", width = 15)
+    @ApiModelProperty(value = "收件人(recipient)")
+    private String recipient;
+	/**收件人电话(recipient tel)*/
+	@Excel(name = "收件人电话(recipient tel)", width = 15)
+    @ApiModelProperty(value = "收件人电话(recipient tel)")
+    private String recipientTel;
+	/**收件人地址(recipient address)*/
+	@Excel(name = "收件人地址(recipient address)", width = 15)
+    @ApiModelProperty(value = "收件人地址(recipient address)")
+    private String recipientAddress;
+	/**付款条件(payment terms)*/
+	@Excel(name = "付款条件(payment terms)", width = 15)
+    @ApiModelProperty(value = "付款条件(payment terms)")
+    private String paymentTerms;
+	/**发货方式(delivery)*/
+	@Excel(name = "发货方式(delivery)", width = 15)
+    @ApiModelProperty(value = "发货方式(delivery)")
+    private String delivery;
+	/**质保期(warranty period)/月*/
+	@Excel(name = "质保期(warranty period)/月", width = 15)
+    @ApiModelProperty(value = "质保期(warranty period)/月")
+    private String warrantyPeriod;
+	/**质保条款(warranty terms)*/
+	@Excel(name = "质保条款(warranty terms)", width = 15)
+    @ApiModelProperty(value = "质保条款(warranty terms)")
+    private String warrantyTerms;
+	/**汇率(exchange rate)*/
+	@Excel(name = "汇率(exchange rate)", width = 15)
+    @ApiModelProperty(value = "汇率(exchange rate)")
+    private java.math.BigDecimal exchangeRate;
+	/**采购员(purchaseman)*/
+	@Excel(name = "采购员(purchaseman)", width = 15)
+    @ApiModelProperty(value = "采购员(purchaseman)")
+    private String purchaseman;
+	/**采购部门(purchase department)*/
+	@Excel(name = "采购部门(purchase department)", width = 15)
+    @ApiModelProperty(value = "采购部门(purchase department)")
+    private String purchaseDepartment;
+	/**币种(currency)*/
+	@Excel(name = "币种(currency)", width = 15)
+    @ApiModelProperty(value = "币种(currency)")
+    private String currency;
+	/**备注(notes)*/
+	@Excel(name = "备注(notes)", width = 15)
+    @ApiModelProperty(value = "备注(notes)")
+    private String notes;
+	/**附件(attachs)*/
+	@Excel(name = "附件(attachs)", width = 15)
+    @ApiModelProperty(value = "附件(attachs)")
+    private String attachs;
+	/**版本号*/
+	@Excel(name = "版本号", width = 15)
+    @ApiModelProperty(value = "版本号")
+    private String version;
+	/**来源*/
+	@Excel(name = "来源", width = 15)
+    @ApiModelProperty(value = "来源")
+    private String sourceCode;
+	/**来源2*/
+	@Excel(name = "来源2", width = 15)
+    @ApiModelProperty(value = "来源2")
+    private String sourceCode2;
+}

+ 153 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrderProduct.java

@@ -0,0 +1,153 @@
+package org.jeecg.modules.purCode.entity;
+
+import java.io.Serializable;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import java.util.Date;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import java.io.UnsupportedEncodingException;
+
+/**
+ * @Description: 采购订单子表 - 产品明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@ApiModel(value="pur_order_product对象", description="采购订单子表 - 产品明细")
+@Data
+@TableName("pur_order_product")
+public class PurOrderProduct implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**状态(1-启用,0-停用)*/
+	@Excel(name = "状态(1-启用,0-停用)", width = 15)
+    @ApiModelProperty(value = "状态(1-启用,0-停用)")
+    private Integer status;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+    @ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+	/**表头主键(销售订单)*/
+    @ApiModelProperty(value = "表头主键(销售订单)")
+    private String headId;
+	/**交期*/
+	@Excel(name = "交期", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "交期")
+    private Date deliveryTime;
+	/**最早发货日期(earliest delivery date)*/
+	@Excel(name = "最早发货日期(earliest delivery date)", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "最早发货日期(earliest delivery date)")
+    private Date earliestDeliveryDate;
+	/**最晚发货日期(latest delivery date)*/
+	@Excel(name = "最晚发货日期(latest delivery date)", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "最晚发货日期(latest delivery date)")
+    private Date latestDeliveryDate;
+	/**产品id*/
+	@Excel(name = "产品id", width = 15)
+    @ApiModelProperty(value = "产品id")
+    private String productId;
+	/**产品中文名(chinese name)*/
+	@Excel(name = "产品中文名(chinese name)", width = 15)
+    @ApiModelProperty(value = "产品中文名(chinese name)")
+    private String chineseName;
+	/**产品英文名*/
+	@Excel(name = "产品英文名", width = 15)
+    @ApiModelProperty(value = "产品英文名")
+    private String englishName;
+	/**规格*/
+	@Excel(name = "规格", width = 15)
+    @ApiModelProperty(value = "规格")
+    private String specifications;
+	/**型号*/
+	@Excel(name = "型号", width = 15)
+    @ApiModelProperty(value = "型号")
+    private String model;
+	/**备件号*/
+	@Excel(name = "备件号", width = 15)
+    @ApiModelProperty(value = "备件号")
+    private String partno;
+	/**图号*/
+	@Excel(name = "图号", width = 15)
+    @ApiModelProperty(value = "图号")
+    private String drawingno;
+	/**订货号*/
+	@Excel(name = "订货号", width = 15)
+    @ApiModelProperty(value = "订货号")
+    private String orderno;
+	/**厂家*/
+	@Excel(name = "厂家", width = 15)
+    @ApiModelProperty(value = "厂家")
+    private String factory;
+	/**质量等级*/
+	@Excel(name = "质量等级", width = 15)
+    @ApiModelProperty(value = "质量等级")
+    private String qualityGrade;
+	/**需要船检证书(need ship inspection certificate)*/
+	@Excel(name = "需要船检证书(need ship inspection certificate)", width = 15)
+    @ApiModelProperty(value = "需要船检证书(need ship inspection certificate)")
+    private String needShipInspection;
+	/**船检证书(ship inspection certificate)*/
+	@Excel(name = "船检证书(ship inspection certificate)", width = 15)
+    @ApiModelProperty(value = "船检证书(ship inspection certificate)")
+    private String shipInspection;
+	/**数量*/
+	@Excel(name = "数量", width = 15)
+    @ApiModelProperty(value = "数量")
+    private Double quantity;
+	/**含税单价(tax price)*/
+	@Excel(name = "含税单价(tax price)", width = 15)
+    @ApiModelProperty(value = "含税单价(tax price)")
+    private java.math.BigDecimal taxPrice;
+	/**含税金额(tax amount)*/
+	@Excel(name = "含税金额(tax amount)", width = 15)
+    @ApiModelProperty(value = "含税金额(tax amount)")
+    private java.math.BigDecimal taxAmount;
+	/**备注(notes)*/
+	@Excel(name = "备注(notes)", width = 15)
+    @ApiModelProperty(value = "备注(notes)")
+    private String notes;
+	/**参照来源id*/
+	@Excel(name = "参照来源id", width = 15)
+    @ApiModelProperty(value = "参照来源id")
+    private String sourceId;
+	/**参照来源*/
+	@Excel(name = "参照来源", width = 15)
+    @ApiModelProperty(value = "参照来源")
+    private String sourceType;
+}

+ 161 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrderProductHis.java

@@ -0,0 +1,161 @@
+package org.jeecg.modules.purCode.entity;
+
+import java.io.Serializable;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import java.util.Date;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import java.io.UnsupportedEncodingException;
+
+/**
+ * @Description: 采购订单子表 - 产品明细(历史)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@ApiModel(value="pur_order_product_his对象", description="采购订单子表 - 产品明细(历史)")
+@Data
+@TableName("pur_order_product_his")
+public class PurOrderProductHis implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**状态(1-启用,0-停用)*/
+	@Excel(name = "状态(1-启用,0-停用)", width = 15)
+    @ApiModelProperty(value = "状态(1-启用,0-停用)")
+    private Integer status;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+    @ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+	/**表头主键(销售订单)*/
+    @ApiModelProperty(value = "表头主键(销售订单)")
+    private String headId;
+	/**交期*/
+	@Excel(name = "交期", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "交期")
+    private Date deliveryTime;
+	/**最早发货日期(earliest delivery date)*/
+	@Excel(name = "最早发货日期(earliest delivery date)", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "最早发货日期(earliest delivery date)")
+    private Date earliestDeliveryDate;
+	/**最晚发货日期(latest delivery date)*/
+	@Excel(name = "最晚发货日期(latest delivery date)", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "最晚发货日期(latest delivery date)")
+    private Date latestDeliveryDate;
+	/**产品id*/
+	@Excel(name = "产品id", width = 15)
+    @ApiModelProperty(value = "产品id")
+    private String productId;
+	/**产品中文名(chinese name)*/
+	@Excel(name = "产品中文名(chinese name)", width = 15)
+    @ApiModelProperty(value = "产品中文名(chinese name)")
+    private String chineseName;
+	/**产品英文名*/
+	@Excel(name = "产品英文名", width = 15)
+    @ApiModelProperty(value = "产品英文名")
+    private String englishName;
+	/**规格*/
+	@Excel(name = "规格", width = 15)
+    @ApiModelProperty(value = "规格")
+    private String specifications;
+	/**型号*/
+	@Excel(name = "型号", width = 15)
+    @ApiModelProperty(value = "型号")
+    private String model;
+	/**备件号*/
+	@Excel(name = "备件号", width = 15)
+    @ApiModelProperty(value = "备件号")
+    private String partno;
+	/**图号*/
+	@Excel(name = "图号", width = 15)
+    @ApiModelProperty(value = "图号")
+    private String drawingno;
+	/**订货号*/
+	@Excel(name = "订货号", width = 15)
+    @ApiModelProperty(value = "订货号")
+    private String orderno;
+	/**厂家*/
+	@Excel(name = "厂家", width = 15)
+    @ApiModelProperty(value = "厂家")
+    private String factory;
+	/**质量等级*/
+	@Excel(name = "质量等级", width = 15)
+    @ApiModelProperty(value = "质量等级")
+    private String qualityGrade;
+	/**需要船检证书(need ship inspection certificate)*/
+	@Excel(name = "需要船检证书(need ship inspection certificate)", width = 15)
+    @ApiModelProperty(value = "需要船检证书(need ship inspection certificate)")
+    private String needShipInspection;
+	/**船检证书(ship inspection certificate)*/
+	@Excel(name = "船检证书(ship inspection certificate)", width = 15)
+    @ApiModelProperty(value = "船检证书(ship inspection certificate)")
+    private String shipInspection;
+	/**数量*/
+	@Excel(name = "数量", width = 15)
+    @ApiModelProperty(value = "数量")
+    private Double quantity;
+	/**含税单价(tax price)*/
+	@Excel(name = "含税单价(tax price)", width = 15)
+    @ApiModelProperty(value = "含税单价(tax price)")
+    private java.math.BigDecimal taxPrice;
+	/**含税金额(tax amount)*/
+	@Excel(name = "含税金额(tax amount)", width = 15)
+    @ApiModelProperty(value = "含税金额(tax amount)")
+    private java.math.BigDecimal taxAmount;
+	/**备注(notes)*/
+	@Excel(name = "备注(notes)", width = 15)
+    @ApiModelProperty(value = "备注(notes)")
+    private String notes;
+	/**参照来源id*/
+	@Excel(name = "参照来源id", width = 15)
+    @ApiModelProperty(value = "参照来源id")
+    private String sourceId;
+	/**参照来源*/
+	@Excel(name = "参照来源", width = 15)
+    @ApiModelProperty(value = "参照来源")
+    private String sourceType;
+	/**历史主键*/
+	@Excel(name = "历史主键", width = 15)
+    @ApiModelProperty(value = "历史主键")
+    private String hisId;
+	/**历史表头主键(采购订单)*/
+	@Excel(name = "历史表头主键(采购订单)", width = 15)
+    @ApiModelProperty(value = "历史表头主键(采购订单)")
+    private String hisHeadId;
+}

+ 87 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrderShip.java

@@ -0,0 +1,87 @@
+package org.jeecg.modules.purCode.entity;
+
+import java.io.Serializable;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import java.util.Date;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import java.io.UnsupportedEncodingException;
+
+/**
+ * @Description: 采购订单子表 - 船明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@ApiModel(value="pur_order_ship对象", description="采购订单子表 - 船明细")
+@Data
+@TableName("pur_order_ship")
+public class PurOrderShip implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**状态(1-启用,0-停用)*/
+	@Excel(name = "状态(1-启用,0-停用)", width = 15)
+    @ApiModelProperty(value = "状态(1-启用,0-停用)")
+    private Integer status;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+    @ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+	/**表头主键(采购订单)*/
+    @ApiModelProperty(value = "表头主键(采购订单)")
+    private String headId;
+	/**船id*/
+	@Excel(name = "船id", width = 15)
+    @ApiModelProperty(value = "船id")
+    private String shipId;
+	/**船名*/
+	@Excel(name = "船名", width = 15)
+    @ApiModelProperty(value = "船名")
+    private String shipName;
+	/**主机号*/
+	@Excel(name = "主机号", width = 15)
+    @ApiModelProperty(value = "主机号")
+    private String hostNumber;
+	/**工程编号*/
+	@Excel(name = "工程编号", width = 15)
+    @ApiModelProperty(value = "工程编号")
+    private String projectNo;
+	/**船厂*/
+	@Excel(name = "船厂", width = 15)
+    @ApiModelProperty(value = "船厂")
+    private String shipFactory;
+	/**船东*/
+	@Excel(name = "船东", width = 15)
+    @ApiModelProperty(value = "船东")
+    private String shipowner;
+}

+ 95 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurOrderShipHis.java

@@ -0,0 +1,95 @@
+package org.jeecg.modules.purCode.entity;
+
+import java.io.Serializable;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import java.util.Date;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import java.io.UnsupportedEncodingException;
+
+/**
+ * @Description: 采购订单子表 - 船明细(历史)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@ApiModel(value="pur_order_ship_his对象", description="采购订单子表 - 船明细(历史)")
+@Data
+@TableName("pur_order_ship_his")
+public class PurOrderShipHis implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**状态(1-启用,0-停用)*/
+	@Excel(name = "状态(1-启用,0-停用)", width = 15)
+    @ApiModelProperty(value = "状态(1-启用,0-停用)")
+    private Integer status;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+    @ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+	/**表头主键(采购订单)*/
+    @ApiModelProperty(value = "表头主键(采购订单)")
+    private String headId;
+	/**船id*/
+	@Excel(name = "船id", width = 15)
+    @ApiModelProperty(value = "船id")
+    private String shipId;
+	/**船名*/
+	@Excel(name = "船名", width = 15)
+    @ApiModelProperty(value = "船名")
+    private String shipName;
+	/**主机号*/
+	@Excel(name = "主机号", width = 15)
+    @ApiModelProperty(value = "主机号")
+    private String hostNumber;
+	/**工程编号*/
+	@Excel(name = "工程编号", width = 15)
+    @ApiModelProperty(value = "工程编号")
+    private String projectNo;
+	/**船厂*/
+	@Excel(name = "船厂", width = 15)
+    @ApiModelProperty(value = "船厂")
+    private String shipFactory;
+	/**船东*/
+	@Excel(name = "船东", width = 15)
+    @ApiModelProperty(value = "船东")
+    private String shipowner;
+	/**历史主键*/
+	@Excel(name = "历史主键", width = 15)
+    @ApiModelProperty(value = "历史主键")
+    private String hisId;
+	/**历史表头主键(采购订单)*/
+	@Excel(name = "历史表头主键(采购订单)", width = 15)
+    @ApiModelProperty(value = "历史表头主键(采购订单)")
+    private String hisHeadId;
+}

+ 37 - 36
srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurPurchaseQuotation.java

@@ -68,38 +68,32 @@ public class PurPurchaseQuotation implements Serializable {
     @DateTimeFormat(pattern="yyyy-MM-dd")
     @ApiModelProperty(value = "单据日期(bill date)")
     private Date billDate;
-	/**价单号(bill code)*/
-	@Excel(name = "价单号(bill code)", width = 15)
-    @ApiModelProperty(value = "价单号(bill code)")
+	/**价单号(bill code)*/
+	@Excel(name = "价单号(bill code)", width = 15)
+    @ApiModelProperty(value = "价单号(bill code)")
     private String billCode;
-	/**询价项目(inquiry project)*/
-	@Excel(name = "询价项目(inquiry project)", width = 15)
-    @ApiModelProperty(value = "询价项目(inquiry project)")
-    private String inquiryProject;
+	/**报价项目(quotation project)*/
+	@Excel(name = "报价项目(quotation project)", width = 15)
+    @ApiModelProperty(value = "报价项目(quotation project)")
+    private String quotationProject;
 	/**项目名称*/
 	@Excel(name = "项目名称", width = 15)
     @ApiModelProperty(value = "项目名称")
     private String projectName;
-	/**询价供应商(inquiry supplier)*/
-	@Excel(name = "询价供应商(inquiry supplier)", width = 15)
-    @ApiModelProperty(value = "询价供应商(inquiry supplier)")
-    private String inquirySuppiler;
+	/**报价供应商(quotation supplier)*/
+	@Excel(name = "报价供应商(quotation supplier)", width = 15)
+    @ApiModelProperty(value = "报价供应商(quotation supplier)")
+    private String quotationSuppiler;
 	/**供应商名称*/
 	@Excel(name = "供应商名称", width = 15)
     @ApiModelProperty(value = "供应商名称")
     private String suppilerName;
-	/**询价有效期(inquiry period)止*/
-	@Excel(name = "询价有效期(inquiry period)止", width = 15, format = "yyyy-MM-dd")
+	/**报价有效期(quotation period)止*/
+	@Excel(name = "报价截止日期(quotationDeadline)", width = 15, format = "yyyy-MM-dd")
 	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
     @DateTimeFormat(pattern="yyyy-MM-dd")
-    @ApiModelProperty(value = "询价有效期(inquiry period)止")
-    private Date inquiryPeriodEnd;
-	/**询价有效期(inquiry period)始*/
-	@Excel(name = "询价有效期(inquiry period)始", width = 15, format = "yyyy-MM-dd")
-	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
-    @DateTimeFormat(pattern="yyyy-MM-dd")
-    @ApiModelProperty(value = "询价有效期(inquiry period)始")
-    private Date inquiryPeriodBegin;
+    @ApiModelProperty(value = "报价截止日期(quotationDeadline)")
+    private Date quotationDeadline;
 	/**业务类型(busyness type)*/
 	@Excel(name = "业务类型(busyness type)", width = 15)
     @ApiModelProperty(value = "业务类型(busyness type)")
@@ -107,6 +101,7 @@ public class PurPurchaseQuotation implements Serializable {
 	/**优先级(priority)*/
 	@Excel(name = "优先级(priority)", width = 15)
     @ApiModelProperty(value = "优先级(priority)")
+    @Dict(dicCode = "priority")
     private String priority;
 	/**产品分类(production class)*/
 	@Excel(name = "产品分类(production class)", width = 15)
@@ -128,6 +123,8 @@ public class PurPurchaseQuotation implements Serializable {
 	@Excel(name = "付款条件(payment terms)", width = 15)
     @ApiModelProperty(value = "付款条件(payment terms)")
     private String paymentTerms;
+    //付款条件-二段信息
+    private String paymentTermsInfo;
 	/**发货方式(delivery)*/
 	@Excel(name = "发货方式(delivery)", width = 15)
     @ApiModelProperty(value = "发货方式(delivery)")
@@ -142,20 +139,24 @@ public class PurPurchaseQuotation implements Serializable {
 	@Excel(name = "报价有效期(quotation validity period)/天", width = 15)
     @ApiModelProperty(value = "报价有效期(quotation validity period)/天")
     private Double quotationValidity;
-	/**采购询价组(procurement inquiry team)*/
-	@Excel(name = "采购询价组(procurement inquiry team)", width = 15)
-    @ApiModelProperty(value = "采购询价组(procurement inquiry team)")
-    private String inquiryTeam;
-	/**附件(attachs)*/
-	@Excel(name = "附件(attachs)", width = 15)
-    @ApiModelProperty(value = "附件(attachs)")
-    private String attachs;
-	/**询价备注(inquiry notes)*/
-	@Excel(name = "询价备注(inquiry notes)", width = 15)
-    @ApiModelProperty(value = "询价备注(inquiry notes)")
-    private String inquiryNotes;
-	/**来源单号(采购询价单)*/
-	@Excel(name = "来源单号(采购询价单)", width = 15)
-    @ApiModelProperty(value = "来源单号(采购询价单)")
+
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "报价有效期(日期)(quotationValidityDate)")
+    private Date quotationValidityDate;
+
+	//币种
+    private String currency;
+	//技术资料
+    private String technicalInformation;
+	//报价资料
+    private String quotationInfomation;
+	/**报价备注(quotation notes)*/
+	@Excel(name = "报价备注(quotation notes)", width = 15)
+    @ApiModelProperty(value = "报价备注(quotation notes)")
+    private String quotationNotes;
+	/**来源单号(采购报价单)*/
+	@Excel(name = "来源单号(采购报价单)", width = 15)
+    @ApiModelProperty(value = "来源单号(采购报价单)")
     private String sourceCode;
 }

+ 5 - 5
srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurPurchaseInquiryProduct.java → srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurPurchaseQuotationProduct.java

@@ -17,15 +17,15 @@ import io.swagger.annotations.ApiModelProperty;
 import java.io.UnsupportedEncodingException;
 
 /**
- * @Description: 采购价单子表 - 产品明细
+ * @Description: 采购价单子表 - 产品明细
  * @Author: jeecg-boot
  * @Date:   2024-11-22
  * @Version: V1.0
  */
-@ApiModel(value="pur_purchase_inquiry_product对象", description="采购价单子表 - 产品明细")
+@ApiModel(value="pur_purchase_quotation_product对象", description="采购报价单子表 - 产品明细")
 @Data
-@TableName("pur_purchase_inquiry_product")
-public class PurPurchaseInquiryProduct implements Serializable {
+@TableName("pur_purchase_quotation_product")
+public class PurPurchaseQuotationProduct implements Serializable {
     private static final long serialVersionUID = 1L;
 
 	/**主键id*/
@@ -141,7 +141,7 @@ public class PurPurchaseInquiryProduct implements Serializable {
 	/**含税金额*/
 	@Excel(name = "含税金额", width = 15)
     @ApiModelProperty(value = "含税金额")
-    private String taxAmount;
+    private java.math.BigDecimal taxAmount;
 	/**备注*/
 	@Excel(name = "备注", width = 15)
     @ApiModelProperty(value = "备注")

+ 1 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurQuotationSelection.java

@@ -83,6 +83,7 @@ public class PurQuotationSelection implements Serializable {
 	/**优先级(priority)*/
 	@Excel(name = "优先级(priority)", width = 15)
     @ApiModelProperty(value = "优先级(priority)")
+    @Dict(dicCode = "priority")
     private String priority;
 	/**产品分类(production class)*/
 	@Excel(name = "产品分类(production class)", width = 15)

+ 1 - 1
srm-module-code/src/main/java/org/jeecg/modules/purCode/entity/PurQuotationSelectionProduct.java

@@ -145,7 +145,7 @@ public class PurQuotationSelectionProduct implements Serializable {
 	/**含税金额*/
 	@Excel(name = "含税金额", width = 15)
     @ApiModelProperty(value = "含税金额")
-    private String taxAmount;
+    private java.math.BigDecimal taxAmount;
 	/**备注*/
 	@Excel(name = "备注", width = 15)
     @ApiModelProperty(value = "备注")

+ 7 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurInquiryFormProductMapper.java

@@ -1,9 +1,14 @@
 package org.jeecg.modules.purCode.mapper;
 
 import java.util.List;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import org.jeecg.modules.purCode.entity.PurInquiryFormProduct;
 import com.baomidou.mybatisplus.core.mapper.BaseMapper;
 import org.apache.ibatis.annotations.Param;
+import org.jeecg.modules.saleCode.vo.SaleInquiryFormAlert;
 
 /**
  * @Description: 采购询价单子表 - 产品明细
@@ -13,6 +18,8 @@ import org.apache.ibatis.annotations.Param;
  */
 public interface PurInquiryFormProductMapper extends BaseMapper<PurInquiryFormProduct> {
 
+	public IPage<SaleInquiryFormAlert> alertPurInquiryList(Page<SaleInquiryFormAlert> page, @Param("ew") QueryWrapper<SaleInquiryFormAlert> queryWrapper);
+
 	/**
 	 * 通过主表id删除子表数据
 	 *

+ 17 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderFilesMapper.java

@@ -0,0 +1,17 @@
+package org.jeecg.modules.purCode.mapper;
+
+import java.util.List;
+
+import org.apache.ibatis.annotations.Param;
+import org.jeecg.modules.purCode.entity.PurOrderFiles;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+
+/**
+ * @Description: 采购订单子表 - 文件
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface PurOrderFilesMapper extends BaseMapper<PurOrderFiles> {
+
+}

+ 17 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderHisMapper.java

@@ -0,0 +1,17 @@
+package org.jeecg.modules.purCode.mapper;
+
+import java.util.List;
+
+import org.apache.ibatis.annotations.Param;
+import org.jeecg.modules.purCode.entity.PurOrderHis;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+
+/**
+ * @Description: 采购订单(历史)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface PurOrderHisMapper extends BaseMapper<PurOrderHis> {
+
+}

+ 17 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderMapper.java

@@ -0,0 +1,17 @@
+package org.jeecg.modules.purCode.mapper;
+
+import java.util.List;
+
+import org.apache.ibatis.annotations.Param;
+import org.jeecg.modules.purCode.entity.PurOrder;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+
+/**
+ * @Description: 采购订单
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface PurOrderMapper extends BaseMapper<PurOrder> {
+
+}

+ 6 - 6
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurPurchaseInquiryProductMapper.java → srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderProductHisMapper.java

@@ -1,17 +1,17 @@
 package org.jeecg.modules.purCode.mapper;
 
 import java.util.List;
-import org.jeecg.modules.purCode.entity.PurPurchaseInquiryProduct;
+import org.jeecg.modules.purCode.entity.PurOrderProductHis;
 import com.baomidou.mybatisplus.core.mapper.BaseMapper;
 import org.apache.ibatis.annotations.Param;
 
 /**
- * @Description: 采购价单子表 - 产品明细
+ * @Description: 采购订单子表 - 产品明细(历史)
  * @Author: jeecg-boot
- * @Date:   2024-11-22
+ * @Date:   2024-11-27
  * @Version: V1.0
  */
-public interface PurPurchaseInquiryProductMapper extends BaseMapper<PurPurchaseInquiryProduct> {
+public interface PurOrderProductHisMapper extends BaseMapper<PurOrderProductHis> {
 
 	/**
 	 * 通过主表id删除子表数据
@@ -25,7 +25,7 @@ public interface PurPurchaseInquiryProductMapper extends BaseMapper<PurPurchaseI
    * 通过主表id查询子表数据
    *
    * @param mainId 主表id
-   * @return List<PurPurchaseInquiryProduct>
+   * @return List<PurOrderProductHis>
    */
-	public List<PurPurchaseInquiryProduct> selectByMainId(@Param("mainId") String mainId);
+	public List<PurOrderProductHis> selectByMainId(@Param("mainId") String mainId);
 }

+ 31 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderProductMapper.java

@@ -0,0 +1,31 @@
+package org.jeecg.modules.purCode.mapper;
+
+import java.util.List;
+import org.jeecg.modules.purCode.entity.PurOrderProduct;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.apache.ibatis.annotations.Param;
+
+/**
+ * @Description: 采购订单子表 - 产品明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface PurOrderProductMapper extends BaseMapper<PurOrderProduct> {
+
+	/**
+	 * 通过主表id删除子表数据
+	 *
+	 * @param mainId 主表id
+	 * @return boolean
+	 */
+	public boolean deleteByMainId(@Param("mainId") String mainId);
+
+  /**
+   * 通过主表id查询子表数据
+   *
+   * @param mainId 主表id
+   * @return List<PurOrderProduct>
+   */
+	public List<PurOrderProduct> selectByMainId(@Param("mainId") String mainId);
+}

+ 31 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderShipHisMapper.java

@@ -0,0 +1,31 @@
+package org.jeecg.modules.purCode.mapper;
+
+import java.util.List;
+import org.jeecg.modules.purCode.entity.PurOrderShipHis;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.apache.ibatis.annotations.Param;
+
+/**
+ * @Description: 采购订单子表 - 船明细(历史)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface PurOrderShipHisMapper extends BaseMapper<PurOrderShipHis> {
+
+	/**
+	 * 通过主表id删除子表数据
+	 *
+	 * @param mainId 主表id
+	 * @return boolean
+	 */
+	public boolean deleteByMainId(@Param("mainId") String mainId);
+
+  /**
+   * 通过主表id查询子表数据
+   *
+   * @param mainId 主表id
+   * @return List<PurOrderShipHis>
+   */
+	public List<PurOrderShipHis> selectByMainId(@Param("mainId") String mainId);
+}

+ 31 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurOrderShipMapper.java

@@ -0,0 +1,31 @@
+package org.jeecg.modules.purCode.mapper;
+
+import java.util.List;
+import org.jeecg.modules.purCode.entity.PurOrderShip;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.apache.ibatis.annotations.Param;
+
+/**
+ * @Description: 采购订单子表 - 船明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface PurOrderShipMapper extends BaseMapper<PurOrderShip> {
+
+	/**
+	 * 通过主表id删除子表数据
+	 *
+	 * @param mainId 主表id
+	 * @return boolean
+	 */
+	public boolean deleteByMainId(@Param("mainId") String mainId);
+
+  /**
+   * 通过主表id查询子表数据
+   *
+   * @param mainId 主表id
+   * @return List<PurOrderShip>
+   */
+	public List<PurOrderShip> selectByMainId(@Param("mainId") String mainId);
+}

+ 41 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/PurPurchaseQuotationProductMapper.java

@@ -0,0 +1,41 @@
+package org.jeecg.modules.purCode.mapper;
+
+import java.util.List;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import org.jeecg.modules.purCode.entity.PurPurchaseQuotationProduct;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.apache.ibatis.annotations.Param;
+import org.jeecg.modules.purCode.vo.SupplierQuotationDetails;
+
+/**
+ * @Description: 采购价单子表 - 产品明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-22
+ * @Version: V1.0
+ */
+public interface PurPurchaseQuotationProductMapper extends BaseMapper<PurPurchaseQuotationProduct> {
+
+	/**
+	 * 通过主表id删除子表数据
+	 *
+	 * @param mainId 主表id
+	 * @return boolean
+	 */
+	public boolean deleteByMainId(@Param("mainId") String mainId);
+
+  /**
+   * 通过主表id查询子表数据
+   *
+   * @param mainId 主表id
+   * @return List<PurPurchaseInquiryProduct>
+   */
+	public List<PurPurchaseQuotationProduct> selectByMainId(@Param("mainId") String mainId);
+
+
+	public IPage<SupplierQuotationDetails> supplierQuotationDetails(Page<SupplierQuotationDetails> page, @Param("ew") QueryWrapper<SupplierQuotationDetails> queryWrapper);
+	public IPage<SupplierQuotationDetails> supplierQuotationTotal(Page<SupplierQuotationDetails> page, @Param("ew") QueryWrapper<SupplierQuotationDetails> queryWrapper);
+
+}

+ 36 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurInquiryFormProductMapper.xml

@@ -13,4 +13,40 @@
 		FROM  pur_inquiry_form_product
 		WHERE
 			 head_id = #{mainId} 	</select>
+
+	<select id="alertPurInquiryList" resultType="org.jeecg.modules.saleCode.vo.SaleInquiryFormAlert">
+		select *
+		from (
+				 select a.id            headId
+					  , b.id            child_id
+					  , a.model         head_model
+					  , b.model         child_model
+					  , a.delivery_time head_delivery_time
+					  , b.delivery_time child_delivery_time
+					  , a.*
+					  , b.product_id
+					  , b.product_class
+					  , b.product_code
+					  , b.chinese_name
+					  , b.english_name
+					  , b.specifications
+					  , b.partno
+					  , b.drawingno
+					  , b.orderno
+					  , b.factory
+					  , b.quality_grade
+					  , b.quantity
+					  , b.unit
+					  , b.need_ship
+					  , b.ship_inspection
+					  , b.notes
+				 from pur_inquiry_form a
+						  left join pur_inquiry_form_product b on a.id = b.head_id
+
+				 where a.del_flag = 0
+				   and a.submit = 1
+				   and b.del_flag = 0
+			 ) a
+			${ew.customSqlSegment}
+	</select>
 </mapper>

+ 5 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderFilesMapper.xml

@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.jeecg.modules.purCode.mapper.PurOrderFilesMapper">
+
+</mapper>

+ 5 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderHisMapper.xml

@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.jeecg.modules.purCode.mapper.PurOrderHisMapper">
+
+</mapper>

+ 5 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderMapper.xml

@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.jeecg.modules.purCode.mapper.PurOrderMapper">
+
+</mapper>

+ 4 - 4
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurPurchaseInquiryProductMapper.xml → srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderProductHisMapper.xml

@@ -1,16 +1,16 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
-<mapper namespace="org.jeecg.modules.purCode.mapper.PurPurchaseInquiryProductMapper">
+<mapper namespace="org.jeecg.modules.purCode.mapper.PurOrderProductHisMapper">
 
 	<delete id="deleteByMainId" parameterType="java.lang.String">
 		DELETE 
-		FROM  pur_purchase_inquiry_product 
+		FROM  pur_order_product_his 
 		WHERE
 			 head_id = #{mainId} 	</delete>
 	
-	<select id="selectByMainId" parameterType="java.lang.String" resultType="org.jeecg.modules.purCode.entity.PurPurchaseInquiryProduct">
+	<select id="selectByMainId" parameterType="java.lang.String" resultType="org.jeecg.modules.purCode.entity.PurOrderProductHis">
 		SELECT * 
-		FROM  pur_purchase_inquiry_product
+		FROM  pur_order_product_his
 		WHERE
 			 head_id = #{mainId} 	</select>
 </mapper>

+ 16 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderProductMapper.xml

@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.jeecg.modules.purCode.mapper.PurOrderProductMapper">
+
+	<delete id="deleteByMainId" parameterType="java.lang.String">
+		DELETE 
+		FROM  pur_order_product 
+		WHERE
+			 head_id = #{mainId} 	</delete>
+	
+	<select id="selectByMainId" parameterType="java.lang.String" resultType="org.jeecg.modules.purCode.entity.PurOrderProduct">
+		SELECT * 
+		FROM  pur_order_product
+		WHERE
+			 head_id = #{mainId} 	</select>
+</mapper>

+ 16 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderShipHisMapper.xml

@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.jeecg.modules.purCode.mapper.PurOrderShipHisMapper">
+
+	<delete id="deleteByMainId" parameterType="java.lang.String">
+		DELETE 
+		FROM  pur_order_ship_his 
+		WHERE
+			 head_id = #{mainId} 	</delete>
+	
+	<select id="selectByMainId" parameterType="java.lang.String" resultType="org.jeecg.modules.purCode.entity.PurOrderShipHis">
+		SELECT * 
+		FROM  pur_order_ship_his
+		WHERE
+			 head_id = #{mainId} 	</select>
+</mapper>

+ 16 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurOrderShipMapper.xml

@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.jeecg.modules.purCode.mapper.PurOrderShipMapper">
+
+	<delete id="deleteByMainId" parameterType="java.lang.String">
+		DELETE 
+		FROM  pur_order_ship 
+		WHERE
+			 head_id = #{mainId} 	</delete>
+	
+	<select id="selectByMainId" parameterType="java.lang.String" resultType="org.jeecg.modules.purCode.entity.PurOrderShip">
+		SELECT * 
+		FROM  pur_order_ship
+		WHERE
+			 head_id = #{mainId} 	</select>
+</mapper>

+ 81 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/mapper/xml/PurPurchaseQuotationProductMapper.xml

@@ -0,0 +1,81 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.jeecg.modules.purCode.mapper.PurPurchaseQuotationProductMapper">
+
+	<delete id="deleteByMainId" parameterType="java.lang.String">
+		DELETE 
+		FROM  pur_purchase_quotation_product
+		WHERE
+			 head_id = #{mainId} 	</delete>
+	
+	<select id="selectByMainId" parameterType="java.lang.String" resultType="org.jeecg.modules.purCode.entity.PurPurchaseQuotationProduct">
+		SELECT * 
+		FROM  pur_purchase_quotation_product
+		WHERE
+			 head_id = #{mainId} 	</select>
+
+
+	<select id="supplierQuotationDetails" resultType="org.jeecg.modules.purCode.vo.SupplierQuotationDetails">
+		select *
+		from (
+				 select a.id            headId
+					  , b.id            child_id
+					  , a.model         head_model
+					  , b.model         child_model
+					  , a.delivery_time head_delivery_time
+					  , b.delivery_time child_delivery_time
+					  , a.*
+					  , b.product_id
+					  , b.product_class
+					  , b.product_code
+					  , b.chinese_name
+					  , b.english_name
+					  , b.specifications
+					  , b.partno
+					  , b.drawingno
+					  , b.orderno
+					  , b.factory
+					  , b.quality_grade
+					  , b.quantity
+					  , b.unit
+					  , b.need_ship
+					  , b.ship_inspection
+					  , b.notes
+				 from pur_purchase_quotation a
+						  left join pur_purchase_quotation_product b on a.id = b.head_id
+
+				 where a.del_flag = 0
+				   and a.submit = 1
+				   and b.del_flag = 0
+
+			 ) a
+			${ew.customSqlSegment}
+	</select>
+
+	<select id="supplierQuotationTotal" resultType="org.jeecg.modules.purCode.vo.SupplierQuotationDetails">
+		select *
+		from (
+				 select a.quotation_project,
+						a.bill_code ,
+						a.bill_date ,
+						a.project_name ,
+						a.suppiler_name ,
+						a.quotation_deadline ,
+						sum(b.tax_amount) taxAmount
+				 from pur_purchase_quotation a
+						  left join pur_purchase_quotation_product b on a.id = b.head_id
+
+				 where a.del_flag = 0
+				   and a.submit = 1
+				   and b.del_flag = 0
+				 group by a.bill_code ,
+						  a.bill_date ,
+						  a.project_name ,
+						  a.suppiler_name ,
+						  a.quotation_deadline,
+				          a.quotation_project
+
+			 ) a
+			${ew.customSqlSegment}
+	</select>
+</mapper>

+ 8 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurInquiryFormProductService.java

@@ -1,7 +1,12 @@
 package org.jeecg.modules.purCode.service;
 
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import org.jeecg.modules.purCode.entity.PurInquiryFormProduct;
 import com.baomidou.mybatisplus.extension.service.IService;
+import org.jeecg.modules.saleCode.vo.SaleInquiryFormAlert;
+
 import java.util.List;
 
 /**
@@ -12,6 +17,8 @@ import java.util.List;
  */
 public interface IPurInquiryFormProductService extends IService<PurInquiryFormProduct> {
 
+	IPage<SaleInquiryFormAlert> alertPurInquiryList(Page<SaleInquiryFormAlert> page, QueryWrapper<SaleInquiryFormAlert> queryWrapper);
+
 	/**
 	 * 通过主表id查询子表数据
 	 *
@@ -19,4 +26,5 @@ public interface IPurInquiryFormProductService extends IService<PurInquiryFormPr
 	 * @return List<PurInquiryFormProduct>
 	 */
 	public List<PurInquiryFormProduct> selectByMainId(String mainId);
+
 }

+ 14 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderFilesService.java

@@ -0,0 +1,14 @@
+package org.jeecg.modules.purCode.service;
+
+import org.jeecg.modules.purCode.entity.PurOrderFiles;
+import com.baomidou.mybatisplus.extension.service.IService;
+
+/**
+ * @Description: 采购订单子表 - 文件
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface IPurOrderFilesService extends IService<PurOrderFiles> {
+
+}

+ 51 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderHisService.java

@@ -0,0 +1,51 @@
+package org.jeecg.modules.purCode.service;
+
+import org.jeecg.modules.purCode.entity.PurOrderShipHis;
+import org.jeecg.modules.purCode.entity.PurOrderProductHis;
+import org.jeecg.modules.purCode.entity.PurOrderHis;
+import com.baomidou.mybatisplus.extension.service.IService;
+import java.io.Serializable;
+import java.util.Collection;
+import java.util.List;
+
+/**
+ * @Description: 采购订单(历史)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface IPurOrderHisService extends IService<PurOrderHis> {
+
+	/**
+	 * 添加一对多
+	 *
+	 * @param purOrderHis
+	 * @param purOrderShipHisList
+	 * @param purOrderProductHisList
+	 */
+	public void saveMain(PurOrderHis purOrderHis,List<PurOrderShipHis> purOrderShipHisList,List<PurOrderProductHis> purOrderProductHisList) ;
+	
+	/**
+	 * 修改一对多
+	 *
+   * @param purOrderHis
+   * @param purOrderShipHisList
+   * @param purOrderProductHisList
+	 */
+	public void updateMain(PurOrderHis purOrderHis,List<PurOrderShipHis> purOrderShipHisList,List<PurOrderProductHis> purOrderProductHisList);
+	
+	/**
+	 * 删除一对多
+	 *
+	 * @param id
+	 */
+	public void delMain (String id);
+	
+	/**
+	 * 批量删除一对多
+	 *
+	 * @param idList
+	 */
+	public void delBatchMain (Collection<? extends Serializable> idList);
+	
+}

+ 22 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderProductHisService.java

@@ -0,0 +1,22 @@
+package org.jeecg.modules.purCode.service;
+
+import org.jeecg.modules.purCode.entity.PurOrderProductHis;
+import com.baomidou.mybatisplus.extension.service.IService;
+import java.util.List;
+
+/**
+ * @Description: 采购订单子表 - 产品明细(历史)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface IPurOrderProductHisService extends IService<PurOrderProductHis> {
+
+	/**
+	 * 通过主表id查询子表数据
+	 *
+	 * @param mainId 主表id
+	 * @return List<PurOrderProductHis>
+	 */
+	public List<PurOrderProductHis> selectByMainId(String mainId);
+}

+ 22 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderProductService.java

@@ -0,0 +1,22 @@
+package org.jeecg.modules.purCode.service;
+
+import org.jeecg.modules.purCode.entity.PurOrderProduct;
+import com.baomidou.mybatisplus.extension.service.IService;
+import java.util.List;
+
+/**
+ * @Description: 采购订单子表 - 产品明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface IPurOrderProductService extends IService<PurOrderProduct> {
+
+	/**
+	 * 通过主表id查询子表数据
+	 *
+	 * @param mainId 主表id
+	 * @return List<PurOrderProduct>
+	 */
+	public List<PurOrderProduct> selectByMainId(String mainId);
+}

+ 51 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderService.java

@@ -0,0 +1,51 @@
+package org.jeecg.modules.purCode.service;
+
+import org.jeecg.modules.purCode.entity.PurOrderShip;
+import org.jeecg.modules.purCode.entity.PurOrderProduct;
+import org.jeecg.modules.purCode.entity.PurOrder;
+import com.baomidou.mybatisplus.extension.service.IService;
+import java.io.Serializable;
+import java.util.Collection;
+import java.util.List;
+
+/**
+ * @Description: 采购订单
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface IPurOrderService extends IService<PurOrder> {
+
+	/**
+	 * 添加一对多
+	 *
+	 * @param purOrder
+	 * @param purOrderShipList
+	 * @param purOrderProductList
+	 */
+	public void saveMain(PurOrder purOrder,List<PurOrderShip> purOrderShipList,List<PurOrderProduct> purOrderProductList) ;
+	
+	/**
+	 * 修改一对多
+	 *
+   * @param purOrder
+   * @param purOrderShipList
+   * @param purOrderProductList
+	 */
+	public void updateMain(PurOrder purOrder,List<PurOrderShip> purOrderShipList,List<PurOrderProduct> purOrderProductList);
+	
+	/**
+	 * 删除一对多
+	 *
+	 * @param id
+	 */
+	public void delMain (String id);
+	
+	/**
+	 * 批量删除一对多
+	 *
+	 * @param idList
+	 */
+	public void delBatchMain (Collection<? extends Serializable> idList);
+	
+}

+ 22 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderShipHisService.java

@@ -0,0 +1,22 @@
+package org.jeecg.modules.purCode.service;
+
+import org.jeecg.modules.purCode.entity.PurOrderShipHis;
+import com.baomidou.mybatisplus.extension.service.IService;
+import java.util.List;
+
+/**
+ * @Description: 采购订单子表 - 船明细(历史)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface IPurOrderShipHisService extends IService<PurOrderShipHis> {
+
+	/**
+	 * 通过主表id查询子表数据
+	 *
+	 * @param mainId 主表id
+	 * @return List<PurOrderShipHis>
+	 */
+	public List<PurOrderShipHis> selectByMainId(String mainId);
+}

+ 22 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurOrderShipService.java

@@ -0,0 +1,22 @@
+package org.jeecg.modules.purCode.service;
+
+import org.jeecg.modules.purCode.entity.PurOrderShip;
+import com.baomidou.mybatisplus.extension.service.IService;
+import java.util.List;
+
+/**
+ * @Description: 采购订单子表 - 船明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface IPurOrderShipService extends IService<PurOrderShip> {
+
+	/**
+	 * 通过主表id查询子表数据
+	 *
+	 * @param mainId 主表id
+	 * @return List<PurOrderShip>
+	 */
+	public List<PurOrderShip> selectByMainId(String mainId);
+}

+ 0 - 22
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurPurchaseInquiryProductService.java

@@ -1,22 +0,0 @@
-package org.jeecg.modules.purCode.service;
-
-import org.jeecg.modules.purCode.entity.PurPurchaseInquiryProduct;
-import com.baomidou.mybatisplus.extension.service.IService;
-import java.util.List;
-
-/**
- * @Description: 采购价单子表 - 产品明细
- * @Author: jeecg-boot
- * @Date:   2024-11-22
- * @Version: V1.0
- */
-public interface IPurPurchaseInquiryProductService extends IService<PurPurchaseInquiryProduct> {
-
-	/**
-	 * 通过主表id查询子表数据
-	 *
-	 * @param mainId 主表id
-	 * @return List<PurPurchaseInquiryProduct>
-	 */
-	public List<PurPurchaseInquiryProduct> selectByMainId(String mainId);
-}

+ 30 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurPurchaseQuotationProductService.java

@@ -0,0 +1,30 @@
+package org.jeecg.modules.purCode.service;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import org.jeecg.modules.purCode.entity.PurPurchaseQuotationProduct;
+import com.baomidou.mybatisplus.extension.service.IService;
+import org.jeecg.modules.purCode.vo.SupplierQuotationDetails;
+
+import java.util.List;
+
+/**
+ * @Description: 采购价单子表 - 产品明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-22
+ * @Version: V1.0
+ */
+public interface IPurPurchaseQuotationProductService extends IService<PurPurchaseQuotationProduct> {
+
+	/**
+	 * 通过主表id查询子表数据
+	 *
+	 * @param mainId 主表id
+	 * @return List<PurPurchaseInquiryProduct>
+	 */
+	public List<PurPurchaseQuotationProduct> selectByMainId(String mainId);
+
+	public IPage<SupplierQuotationDetails> supplierQuotationDetails(Page<SupplierQuotationDetails> page, QueryWrapper<SupplierQuotationDetails> queryWrapper);
+	public IPage<SupplierQuotationDetails> supplierQuotationTotal(Page<SupplierQuotationDetails> page, QueryWrapper<SupplierQuotationDetails> queryWrapper);
+}

+ 5 - 5
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/IPurPurchaseQuotationService.java

@@ -1,7 +1,7 @@
 package org.jeecg.modules.purCode.service;
 
 import org.jeecg.modules.purCode.entity.PurPurchaseQuotationShip;
-import org.jeecg.modules.purCode.entity.PurPurchaseInquiryProduct;
+import org.jeecg.modules.purCode.entity.PurPurchaseQuotationProduct;
 import org.jeecg.modules.purCode.entity.PurPurchaseQuotation;
 import com.baomidou.mybatisplus.extension.service.IService;
 import java.io.Serializable;
@@ -21,18 +21,18 @@ public interface IPurPurchaseQuotationService extends IService<PurPurchaseQuotat
 	 *
 	 * @param purPurchaseQuotation
 	 * @param purPurchaseQuotationShipList
-	 * @param purPurchaseInquiryProductList
+	 * @param purPurchaseQuotationProductList
 	 */
-	public void saveMain(PurPurchaseQuotation purPurchaseQuotation,List<PurPurchaseQuotationShip> purPurchaseQuotationShipList,List<PurPurchaseInquiryProduct> purPurchaseInquiryProductList) ;
+	public void saveMain(PurPurchaseQuotation purPurchaseQuotation,List<PurPurchaseQuotationShip> purPurchaseQuotationShipList,List<PurPurchaseQuotationProduct> purPurchaseQuotationProductList) ;
 	
 	/**
 	 * 修改一对多
 	 *
    * @param purPurchaseQuotation
    * @param purPurchaseQuotationShipList
-   * @param purPurchaseInquiryProductList
+   * @param purPurchaseQuotationProductList
 	 */
-	public void updateMain(PurPurchaseQuotation purPurchaseQuotation,List<PurPurchaseQuotationShip> purPurchaseQuotationShipList,List<PurPurchaseInquiryProduct> purPurchaseInquiryProductList);
+	public void updateMain(PurPurchaseQuotation purPurchaseQuotation,List<PurPurchaseQuotationShip> purPurchaseQuotationShipList,List<PurPurchaseQuotationProduct> purPurchaseQuotationProductList);
 	
 	/**
 	 * 删除一对多

+ 13 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurInquiryFormProductServiceImpl.java

@@ -1,12 +1,17 @@
 package org.jeecg.modules.purCode.service.impl;
 
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import org.jeecg.modules.purCode.entity.PurInquiryFormProduct;
 import org.jeecg.modules.purCode.mapper.PurInquiryFormProductMapper;
 import org.jeecg.modules.purCode.service.IPurInquiryFormProductService;
+import org.jeecg.modules.saleCode.vo.SaleInquiryFormAlert;
 import org.springframework.stereotype.Service;
 import java.util.List;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.transaction.annotation.Transactional;
 
 /**
  * @Description: 采购询价单子表 - 产品明细
@@ -24,4 +29,12 @@ public class PurInquiryFormProductServiceImpl extends ServiceImpl<PurInquiryForm
 	public List<PurInquiryFormProduct> selectByMainId(String mainId) {
 		return purInquiryFormProductMapper.selectByMainId(mainId);
 	}
+
+
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public IPage<SaleInquiryFormAlert> alertPurInquiryList(Page<SaleInquiryFormAlert> page, QueryWrapper<SaleInquiryFormAlert> queryWrapper){
+		return purInquiryFormProductMapper.alertPurInquiryList(page,queryWrapper);
+	}
+
 }

+ 4 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurInquiryFormServiceImpl.java

@@ -38,6 +38,7 @@ public class PurInquiryFormServiceImpl extends ServiceImpl<PurInquiryFormMapper,
 		if(purInquiryFormShipList!=null && purInquiryFormShipList.size()>0) {
 			for(PurInquiryFormShip entity:purInquiryFormShipList) {
 				//外键设置
+				entity.setId(null);
 				entity.setHeadId(purInquiryForm.getId());
 				purInquiryFormShipMapper.insert(entity);
 			}
@@ -45,6 +46,7 @@ public class PurInquiryFormServiceImpl extends ServiceImpl<PurInquiryFormMapper,
 		if(purInquiryFormProductList!=null && purInquiryFormProductList.size()>0) {
 			for(PurInquiryFormProduct entity:purInquiryFormProductList) {
 				//外键设置
+				entity.setId(null);
 				entity.setHeadId(purInquiryForm.getId());
 				purInquiryFormProductMapper.insert(entity);
 			}
@@ -64,6 +66,7 @@ public class PurInquiryFormServiceImpl extends ServiceImpl<PurInquiryFormMapper,
 		if(purInquiryFormShipList!=null && purInquiryFormShipList.size()>0) {
 			for(PurInquiryFormShip entity:purInquiryFormShipList) {
 				//外键设置
+				entity.setId(null);
 				entity.setHeadId(purInquiryForm.getId());
 				purInquiryFormShipMapper.insert(entity);
 			}
@@ -71,6 +74,7 @@ public class PurInquiryFormServiceImpl extends ServiceImpl<PurInquiryFormMapper,
 		if(purInquiryFormProductList!=null && purInquiryFormProductList.size()>0) {
 			for(PurInquiryFormProduct entity:purInquiryFormProductList) {
 				//外键设置
+				entity.setId(null);
 				entity.setHeadId(purInquiryForm.getId());
 				purInquiryFormProductMapper.insert(entity);
 			}

+ 19 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderFilesServiceImpl.java

@@ -0,0 +1,19 @@
+package org.jeecg.modules.purCode.service.impl;
+
+import org.jeecg.modules.purCode.entity.PurOrderFiles;
+import org.jeecg.modules.purCode.mapper.PurOrderFilesMapper;
+import org.jeecg.modules.purCode.service.IPurOrderFilesService;
+import org.springframework.stereotype.Service;
+
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+
+/**
+ * @Description: 采购订单子表 - 文件
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Service
+public class PurOrderFilesServiceImpl extends ServiceImpl<PurOrderFilesMapper, PurOrderFiles> implements IPurOrderFilesService {
+
+}

+ 98 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderHisServiceImpl.java

@@ -0,0 +1,98 @@
+package org.jeecg.modules.purCode.service.impl;
+
+import org.jeecg.modules.purCode.entity.PurOrderHis;
+import org.jeecg.modules.purCode.entity.PurOrderShipHis;
+import org.jeecg.modules.purCode.entity.PurOrderProductHis;
+import org.jeecg.modules.purCode.mapper.PurOrderShipHisMapper;
+import org.jeecg.modules.purCode.mapper.PurOrderProductHisMapper;
+import org.jeecg.modules.purCode.mapper.PurOrderHisMapper;
+import org.jeecg.modules.purCode.service.IPurOrderHisService;
+import org.springframework.stereotype.Service;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.transaction.annotation.Transactional;
+import java.io.Serializable;
+import java.util.List;
+import java.util.Collection;
+
+/**
+ * @Description: 采购订单(历史)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Service
+public class PurOrderHisServiceImpl extends ServiceImpl<PurOrderHisMapper, PurOrderHis> implements IPurOrderHisService {
+
+	@Autowired
+	private PurOrderHisMapper purOrderHisMapper;
+	@Autowired
+	private PurOrderShipHisMapper purOrderShipHisMapper;
+	@Autowired
+	private PurOrderProductHisMapper purOrderProductHisMapper;
+	
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public void saveMain(PurOrderHis purOrderHis, List<PurOrderShipHis> purOrderShipHisList,List<PurOrderProductHis> purOrderProductHisList) {
+		purOrderHisMapper.insert(purOrderHis);
+		if(purOrderShipHisList!=null && purOrderShipHisList.size()>0) {
+			for(PurOrderShipHis entity:purOrderShipHisList) {
+				//外键设置
+				entity.setHeadId(purOrderHis.getId());
+				purOrderShipHisMapper.insert(entity);
+			}
+		}
+		if(purOrderProductHisList!=null && purOrderProductHisList.size()>0) {
+			for(PurOrderProductHis entity:purOrderProductHisList) {
+				//外键设置
+				entity.setHeadId(purOrderHis.getId());
+				purOrderProductHisMapper.insert(entity);
+			}
+		}
+	}
+
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public void updateMain(PurOrderHis purOrderHis,List<PurOrderShipHis> purOrderShipHisList,List<PurOrderProductHis> purOrderProductHisList) {
+		purOrderHisMapper.updateById(purOrderHis);
+		
+		//1.先删除子表数据
+		purOrderShipHisMapper.deleteByMainId(purOrderHis.getId());
+		purOrderProductHisMapper.deleteByMainId(purOrderHis.getId());
+		
+		//2.子表数据重新插入
+		if(purOrderShipHisList!=null && purOrderShipHisList.size()>0) {
+			for(PurOrderShipHis entity:purOrderShipHisList) {
+				//外键设置
+				entity.setHeadId(purOrderHis.getId());
+				purOrderShipHisMapper.insert(entity);
+			}
+		}
+		if(purOrderProductHisList!=null && purOrderProductHisList.size()>0) {
+			for(PurOrderProductHis entity:purOrderProductHisList) {
+				//外键设置
+				entity.setHeadId(purOrderHis.getId());
+				purOrderProductHisMapper.insert(entity);
+			}
+		}
+	}
+
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public void delMain(String id) {
+		purOrderShipHisMapper.deleteByMainId(id);
+		purOrderProductHisMapper.deleteByMainId(id);
+		purOrderHisMapper.deleteById(id);
+	}
+
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public void delBatchMain(Collection<? extends Serializable> idList) {
+		for(Serializable id:idList) {
+			purOrderShipHisMapper.deleteByMainId(id.toString());
+			purOrderProductHisMapper.deleteByMainId(id.toString());
+			purOrderHisMapper.deleteById(id);
+		}
+	}
+	
+}

+ 27 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderProductHisServiceImpl.java

@@ -0,0 +1,27 @@
+package org.jeecg.modules.purCode.service.impl;
+
+import org.jeecg.modules.purCode.entity.PurOrderProductHis;
+import org.jeecg.modules.purCode.mapper.PurOrderProductHisMapper;
+import org.jeecg.modules.purCode.service.IPurOrderProductHisService;
+import org.springframework.stereotype.Service;
+import java.util.List;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
+
+/**
+ * @Description: 采购订单子表 - 产品明细(历史)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Service
+public class PurOrderProductHisServiceImpl extends ServiceImpl<PurOrderProductHisMapper, PurOrderProductHis> implements IPurOrderProductHisService {
+	
+	@Autowired
+	private PurOrderProductHisMapper purOrderProductHisMapper;
+	
+	@Override
+	public List<PurOrderProductHis> selectByMainId(String mainId) {
+		return purOrderProductHisMapper.selectByMainId(mainId);
+	}
+}

+ 27 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderProductServiceImpl.java

@@ -0,0 +1,27 @@
+package org.jeecg.modules.purCode.service.impl;
+
+import org.jeecg.modules.purCode.entity.PurOrderProduct;
+import org.jeecg.modules.purCode.mapper.PurOrderProductMapper;
+import org.jeecg.modules.purCode.service.IPurOrderProductService;
+import org.springframework.stereotype.Service;
+import java.util.List;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
+
+/**
+ * @Description: 采购订单子表 - 产品明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Service
+public class PurOrderProductServiceImpl extends ServiceImpl<PurOrderProductMapper, PurOrderProduct> implements IPurOrderProductService {
+	
+	@Autowired
+	private PurOrderProductMapper purOrderProductMapper;
+	
+	@Override
+	public List<PurOrderProduct> selectByMainId(String mainId) {
+		return purOrderProductMapper.selectByMainId(mainId);
+	}
+}

+ 98 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderServiceImpl.java

@@ -0,0 +1,98 @@
+package org.jeecg.modules.purCode.service.impl;
+
+import org.jeecg.modules.purCode.entity.PurOrder;
+import org.jeecg.modules.purCode.entity.PurOrderShip;
+import org.jeecg.modules.purCode.entity.PurOrderProduct;
+import org.jeecg.modules.purCode.mapper.PurOrderShipMapper;
+import org.jeecg.modules.purCode.mapper.PurOrderProductMapper;
+import org.jeecg.modules.purCode.mapper.PurOrderMapper;
+import org.jeecg.modules.purCode.service.IPurOrderService;
+import org.springframework.stereotype.Service;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.transaction.annotation.Transactional;
+import java.io.Serializable;
+import java.util.List;
+import java.util.Collection;
+
+/**
+ * @Description: 采购订单
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Service
+public class PurOrderServiceImpl extends ServiceImpl<PurOrderMapper, PurOrder> implements IPurOrderService {
+
+	@Autowired
+	private PurOrderMapper purOrderMapper;
+	@Autowired
+	private PurOrderShipMapper purOrderShipMapper;
+	@Autowired
+	private PurOrderProductMapper purOrderProductMapper;
+	
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public void saveMain(PurOrder purOrder, List<PurOrderShip> purOrderShipList,List<PurOrderProduct> purOrderProductList) {
+		purOrderMapper.insert(purOrder);
+		if(purOrderShipList!=null && purOrderShipList.size()>0) {
+			for(PurOrderShip entity:purOrderShipList) {
+				//外键设置
+				entity.setHeadId(purOrder.getId());
+				purOrderShipMapper.insert(entity);
+			}
+		}
+		if(purOrderProductList!=null && purOrderProductList.size()>0) {
+			for(PurOrderProduct entity:purOrderProductList) {
+				//外键设置
+				entity.setHeadId(purOrder.getId());
+				purOrderProductMapper.insert(entity);
+			}
+		}
+	}
+
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public void updateMain(PurOrder purOrder,List<PurOrderShip> purOrderShipList,List<PurOrderProduct> purOrderProductList) {
+		purOrderMapper.updateById(purOrder);
+		
+		//1.先删除子表数据
+		purOrderShipMapper.deleteByMainId(purOrder.getId());
+		purOrderProductMapper.deleteByMainId(purOrder.getId());
+		
+		//2.子表数据重新插入
+		if(purOrderShipList!=null && purOrderShipList.size()>0) {
+			for(PurOrderShip entity:purOrderShipList) {
+				//外键设置
+				entity.setHeadId(purOrder.getId());
+				purOrderShipMapper.insert(entity);
+			}
+		}
+		if(purOrderProductList!=null && purOrderProductList.size()>0) {
+			for(PurOrderProduct entity:purOrderProductList) {
+				//外键设置
+				entity.setHeadId(purOrder.getId());
+				purOrderProductMapper.insert(entity);
+			}
+		}
+	}
+
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public void delMain(String id) {
+		purOrderShipMapper.deleteByMainId(id);
+		purOrderProductMapper.deleteByMainId(id);
+		purOrderMapper.deleteById(id);
+	}
+
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public void delBatchMain(Collection<? extends Serializable> idList) {
+		for(Serializable id:idList) {
+			purOrderShipMapper.deleteByMainId(id.toString());
+			purOrderProductMapper.deleteByMainId(id.toString());
+			purOrderMapper.deleteById(id);
+		}
+	}
+	
+}

+ 27 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderShipHisServiceImpl.java

@@ -0,0 +1,27 @@
+package org.jeecg.modules.purCode.service.impl;
+
+import org.jeecg.modules.purCode.entity.PurOrderShipHis;
+import org.jeecg.modules.purCode.mapper.PurOrderShipHisMapper;
+import org.jeecg.modules.purCode.service.IPurOrderShipHisService;
+import org.springframework.stereotype.Service;
+import java.util.List;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
+
+/**
+ * @Description: 采购订单子表 - 船明细(历史)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Service
+public class PurOrderShipHisServiceImpl extends ServiceImpl<PurOrderShipHisMapper, PurOrderShipHis> implements IPurOrderShipHisService {
+	
+	@Autowired
+	private PurOrderShipHisMapper purOrderShipHisMapper;
+	
+	@Override
+	public List<PurOrderShipHis> selectByMainId(String mainId) {
+		return purOrderShipHisMapper.selectByMainId(mainId);
+	}
+}

+ 27 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurOrderShipServiceImpl.java

@@ -0,0 +1,27 @@
+package org.jeecg.modules.purCode.service.impl;
+
+import org.jeecg.modules.purCode.entity.PurOrderShip;
+import org.jeecg.modules.purCode.mapper.PurOrderShipMapper;
+import org.jeecg.modules.purCode.service.IPurOrderShipService;
+import org.springframework.stereotype.Service;
+import java.util.List;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
+
+/**
+ * @Description: 采购订单子表 - 船明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Service
+public class PurOrderShipServiceImpl extends ServiceImpl<PurOrderShipMapper, PurOrderShip> implements IPurOrderShipService {
+	
+	@Autowired
+	private PurOrderShipMapper purOrderShipMapper;
+	
+	@Override
+	public List<PurOrderShip> selectByMainId(String mainId) {
+		return purOrderShipMapper.selectByMainId(mainId);
+	}
+}

+ 0 - 27
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurPurchaseInquiryProductServiceImpl.java

@@ -1,27 +0,0 @@
-package org.jeecg.modules.purCode.service.impl;
-
-import org.jeecg.modules.purCode.entity.PurPurchaseInquiryProduct;
-import org.jeecg.modules.purCode.mapper.PurPurchaseInquiryProductMapper;
-import org.jeecg.modules.purCode.service.IPurPurchaseInquiryProductService;
-import org.springframework.stereotype.Service;
-import java.util.List;
-import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
-import org.springframework.beans.factory.annotation.Autowired;
-
-/**
- * @Description: 采购价单子表 - 产品明细
- * @Author: jeecg-boot
- * @Date:   2024-11-22
- * @Version: V1.0
- */
-@Service
-public class PurPurchaseInquiryProductServiceImpl extends ServiceImpl<PurPurchaseInquiryProductMapper, PurPurchaseInquiryProduct> implements IPurPurchaseInquiryProductService {
-	
-	@Autowired
-	private PurPurchaseInquiryProductMapper purPurchaseInquiryProductMapper;
-	
-	@Override
-	public List<PurPurchaseInquiryProduct> selectByMainId(String mainId) {
-		return purPurchaseInquiryProductMapper.selectByMainId(mainId);
-	}
-}

+ 47 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurPurchaseQuotationProductServiceImpl.java

@@ -0,0 +1,47 @@
+package org.jeecg.modules.purCode.service.impl;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import org.jeecg.modules.purCode.entity.PurPurchaseQuotationProduct;
+import org.jeecg.modules.purCode.mapper.PurPurchaseQuotationProductMapper;
+import org.jeecg.modules.purCode.service.IPurPurchaseQuotationProductService;
+import org.jeecg.modules.purCode.vo.SupplierQuotationDetails;
+import org.jeecg.modules.saleCode.vo.SaleInquiryFormAlert;
+import org.springframework.stereotype.Service;
+import java.util.List;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.transaction.annotation.Transactional;
+
+/**
+ * @Description: 采购价单子表 - 产品明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-22
+ * @Version: V1.0
+ */
+@Service
+public class PurPurchaseQuotationProductServiceImpl extends ServiceImpl<PurPurchaseQuotationProductMapper, PurPurchaseQuotationProduct> implements IPurPurchaseQuotationProductService {
+	
+	@Autowired
+	private PurPurchaseQuotationProductMapper purPurchaseQuotationProductMapper;
+	
+	@Override
+	public List<PurPurchaseQuotationProduct> selectByMainId(String mainId) {
+		return purPurchaseQuotationProductMapper.selectByMainId(mainId);
+	}
+
+
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public IPage<SupplierQuotationDetails> supplierQuotationDetails(Page<SupplierQuotationDetails> page, QueryWrapper<SupplierQuotationDetails> queryWrapper){
+		return purPurchaseQuotationProductMapper.supplierQuotationDetails(page,queryWrapper);
+	}
+
+	@Override
+	@Transactional(rollbackFor = Exception.class)
+	public IPage<SupplierQuotationDetails> supplierQuotationTotal(Page<SupplierQuotationDetails> page, QueryWrapper<SupplierQuotationDetails> queryWrapper){
+		return purPurchaseQuotationProductMapper.supplierQuotationTotal(page,queryWrapper);
+	}
+
+}

+ 18 - 14
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurPurchaseQuotationServiceImpl.java

@@ -2,9 +2,9 @@ package org.jeecg.modules.purCode.service.impl;
 
 import org.jeecg.modules.purCode.entity.PurPurchaseQuotation;
 import org.jeecg.modules.purCode.entity.PurPurchaseQuotationShip;
-import org.jeecg.modules.purCode.entity.PurPurchaseInquiryProduct;
+import org.jeecg.modules.purCode.entity.PurPurchaseQuotationProduct;
 import org.jeecg.modules.purCode.mapper.PurPurchaseQuotationShipMapper;
-import org.jeecg.modules.purCode.mapper.PurPurchaseInquiryProductMapper;
+import org.jeecg.modules.purCode.mapper.PurPurchaseQuotationProductMapper;
 import org.jeecg.modules.purCode.mapper.PurPurchaseQuotationMapper;
 import org.jeecg.modules.purCode.service.IPurPurchaseQuotationService;
 import org.springframework.stereotype.Service;
@@ -29,50 +29,54 @@ public class PurPurchaseQuotationServiceImpl extends ServiceImpl<PurPurchaseQuot
 	@Autowired
 	private PurPurchaseQuotationShipMapper purPurchaseQuotationShipMapper;
 	@Autowired
-	private PurPurchaseInquiryProductMapper purPurchaseInquiryProductMapper;
+	private PurPurchaseQuotationProductMapper purPurchaseQuotationProductMapper;
 	
 	@Override
 	@Transactional(rollbackFor = Exception.class)
-	public void saveMain(PurPurchaseQuotation purPurchaseQuotation, List<PurPurchaseQuotationShip> purPurchaseQuotationShipList,List<PurPurchaseInquiryProduct> purPurchaseInquiryProductList) {
+	public void saveMain(PurPurchaseQuotation purPurchaseQuotation, List<PurPurchaseQuotationShip> purPurchaseQuotationShipList,List<PurPurchaseQuotationProduct> purPurchaseQuotationProductList) {
 		purPurchaseQuotationMapper.insert(purPurchaseQuotation);
 		if(purPurchaseQuotationShipList!=null && purPurchaseQuotationShipList.size()>0) {
 			for(PurPurchaseQuotationShip entity:purPurchaseQuotationShipList) {
 				//外键设置
+				entity.setId(null);
 				entity.setHeadId(purPurchaseQuotation.getId());
 				purPurchaseQuotationShipMapper.insert(entity);
 			}
 		}
-		if(purPurchaseInquiryProductList!=null && purPurchaseInquiryProductList.size()>0) {
-			for(PurPurchaseInquiryProduct entity:purPurchaseInquiryProductList) {
+		if(purPurchaseQuotationProductList !=null && purPurchaseQuotationProductList.size()>0) {
+			for(PurPurchaseQuotationProduct entity: purPurchaseQuotationProductList) {
 				//外键设置
 				entity.setHeadId(purPurchaseQuotation.getId());
-				purPurchaseInquiryProductMapper.insert(entity);
+				entity.setId(null);
+				purPurchaseQuotationProductMapper.insert(entity);
 			}
 		}
 	}
 
 	@Override
 	@Transactional(rollbackFor = Exception.class)
-	public void updateMain(PurPurchaseQuotation purPurchaseQuotation,List<PurPurchaseQuotationShip> purPurchaseQuotationShipList,List<PurPurchaseInquiryProduct> purPurchaseInquiryProductList) {
+	public void updateMain(PurPurchaseQuotation purPurchaseQuotation,List<PurPurchaseQuotationShip> purPurchaseQuotationShipList,List<PurPurchaseQuotationProduct> purPurchaseQuotationProductList) {
 		purPurchaseQuotationMapper.updateById(purPurchaseQuotation);
 		
 		//1.先删除子表数据
 		purPurchaseQuotationShipMapper.deleteByMainId(purPurchaseQuotation.getId());
-		purPurchaseInquiryProductMapper.deleteByMainId(purPurchaseQuotation.getId());
+		purPurchaseQuotationProductMapper.deleteByMainId(purPurchaseQuotation.getId());
 		
 		//2.子表数据重新插入
 		if(purPurchaseQuotationShipList!=null && purPurchaseQuotationShipList.size()>0) {
 			for(PurPurchaseQuotationShip entity:purPurchaseQuotationShipList) {
 				//外键设置
+				entity.setId(null);
 				entity.setHeadId(purPurchaseQuotation.getId());
 				purPurchaseQuotationShipMapper.insert(entity);
 			}
 		}
-		if(purPurchaseInquiryProductList!=null && purPurchaseInquiryProductList.size()>0) {
-			for(PurPurchaseInquiryProduct entity:purPurchaseInquiryProductList) {
+		if(purPurchaseQuotationProductList !=null && purPurchaseQuotationProductList.size()>0) {
+			for(PurPurchaseQuotationProduct entity: purPurchaseQuotationProductList) {
 				//外键设置
+				entity.setId(null);
 				entity.setHeadId(purPurchaseQuotation.getId());
-				purPurchaseInquiryProductMapper.insert(entity);
+				purPurchaseQuotationProductMapper.insert(entity);
 			}
 		}
 	}
@@ -81,7 +85,7 @@ public class PurPurchaseQuotationServiceImpl extends ServiceImpl<PurPurchaseQuot
 	@Transactional(rollbackFor = Exception.class)
 	public void delMain(String id) {
 		purPurchaseQuotationShipMapper.deleteByMainId(id);
-		purPurchaseInquiryProductMapper.deleteByMainId(id);
+		purPurchaseQuotationProductMapper.deleteByMainId(id);
 		purPurchaseQuotationMapper.deleteById(id);
 	}
 
@@ -90,7 +94,7 @@ public class PurPurchaseQuotationServiceImpl extends ServiceImpl<PurPurchaseQuot
 	public void delBatchMain(Collection<? extends Serializable> idList) {
 		for(Serializable id:idList) {
 			purPurchaseQuotationShipMapper.deleteByMainId(id.toString());
-			purPurchaseInquiryProductMapper.deleteByMainId(id.toString());
+			purPurchaseQuotationProductMapper.deleteByMainId(id.toString());
 			purPurchaseQuotationMapper.deleteById(id);
 		}
 	}

+ 4 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/service/impl/PurQuotationSelectionServiceImpl.java

@@ -38,6 +38,7 @@ public class PurQuotationSelectionServiceImpl extends ServiceImpl<PurQuotationSe
 		if(purQuotationSelectionShipList!=null && purQuotationSelectionShipList.size()>0) {
 			for(PurQuotationSelectionShip entity:purQuotationSelectionShipList) {
 				//外键设置
+				entity.setId(null);
 				entity.setHeadId(purQuotationSelection.getId());
 				purQuotationSelectionShipMapper.insert(entity);
 			}
@@ -45,6 +46,7 @@ public class PurQuotationSelectionServiceImpl extends ServiceImpl<PurQuotationSe
 		if(purQuotationSelectionProductList!=null && purQuotationSelectionProductList.size()>0) {
 			for(PurQuotationSelectionProduct entity:purQuotationSelectionProductList) {
 				//外键设置
+				entity.setId(null);
 				entity.setHeadId(purQuotationSelection.getId());
 				purQuotationSelectionProductMapper.insert(entity);
 			}
@@ -64,6 +66,7 @@ public class PurQuotationSelectionServiceImpl extends ServiceImpl<PurQuotationSe
 		if(purQuotationSelectionShipList!=null && purQuotationSelectionShipList.size()>0) {
 			for(PurQuotationSelectionShip entity:purQuotationSelectionShipList) {
 				//外键设置
+				entity.setId(null);
 				entity.setHeadId(purQuotationSelection.getId());
 				purQuotationSelectionShipMapper.insert(entity);
 			}
@@ -71,6 +74,7 @@ public class PurQuotationSelectionServiceImpl extends ServiceImpl<PurQuotationSe
 		if(purQuotationSelectionProductList!=null && purQuotationSelectionProductList.size()>0) {
 			for(PurQuotationSelectionProduct entity:purQuotationSelectionProductList) {
 				//外键设置
+				entity.setId(null);
 				entity.setHeadId(purQuotationSelection.getId());
 				purQuotationSelectionProductMapper.insert(entity);
 			}

+ 7 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/vo/PurInquiryFormPage.java

@@ -49,6 +49,7 @@ public class PurInquiryFormPage {
 	/**状态(1-结束,0-询价中)*/
 	@Excel(name = "状态(1-结束,0-询价中)", width = 15)
 	@ApiModelProperty(value = "状态(1-结束,0-询价中)")
+	@Dict(dicCode = "purchase_inquiry_status")
     private Integer status;
 	/**删除状态(0-正常,1-已删除)*/
 	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
@@ -57,6 +58,7 @@ public class PurInquiryFormPage {
 	/**提交(1是 0否)*/
 	@Excel(name = "提交(1是 0否)", width = 15)
 	@ApiModelProperty(value = "提交(1是 0否)")
+	@Dict(dicCode = "yes_or_no")
     private String submit;
 	/**单据日期(bill date)*/
 	@Excel(name = "单据日期(bill date)", width = 15, format = "yyyy-MM-dd")
@@ -120,6 +122,8 @@ public class PurInquiryFormPage {
 	@Excel(name = "付款条件(payment terms)", width = 15)
 	@ApiModelProperty(value = "付款条件(payment terms)")
     private String paymentTerms;
+	//付款条件-二段信息
+	private String paymentTermsInfo;
 	/**交货地点(place of delivery)*/
 	@Excel(name = "交货地点(place of delivery)", width = 15)
 	@ApiModelProperty(value = "交货地点(place of delivery)")
@@ -142,6 +146,7 @@ public class PurInquiryFormPage {
 	@Excel(name = "采购询价组(procurement inquiry team)", width = 15)
 	@ApiModelProperty(value = "采购询价组(procurement inquiry team)")
     private String inquiryTeam;
+	private String inquiryTeamName;
 	/**附件(attachs)*/
 	@Excel(name = "附件(attachs)", width = 15)
 	@ApiModelProperty(value = "附件(attachs)")
@@ -152,6 +157,8 @@ public class PurInquiryFormPage {
     private String inquiryNotes;
 	//来源单号(销售询价单)
     private String sourceCode;
+	//来源销售询价单文件
+    private String saleAttachs;
 
 	@ExcelCollection(name="采购询价单子表 - 船明细")
 	@ApiModelProperty(value = "采购询价单子表 - 船明细")

+ 199 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/vo/PurOrderHisPage.java

@@ -0,0 +1,199 @@
+package org.jeecg.modules.purCode.vo;
+
+import java.util.List;
+import org.jeecg.modules.purCode.entity.PurOrderHis;
+import org.jeecg.modules.purCode.entity.PurOrderShipHis;
+import org.jeecg.modules.purCode.entity.PurOrderProductHis;
+import lombok.Data;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import org.jeecgframework.poi.excel.annotation.ExcelEntity;
+import org.jeecgframework.poi.excel.annotation.ExcelCollection;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import java.util.Date;
+import org.jeecg.common.aspect.annotation.Dict;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+
+/**
+ * @Description: 采购订单(历史)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Data
+@ApiModel(value="pur_order_hisPage对象", description="采购订单(历史)")
+public class PurOrderHisPage {
+
+	/**历史主键*/
+	@Excel(name = "历史主键", width = 15)
+	@ApiModelProperty(value = "历史主键")
+    private String hisId;
+	/**主键id*/
+	@ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+	@ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	@ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+	@ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	@ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**客户确认(1-已确认,0-未确认)*/
+	@Excel(name = "客户确认(1-已确认,0-未确认)", width = 15)
+	@ApiModelProperty(value = "客户确认(1-已确认,0-未确认)")
+    private Integer status;
+	/**提交(submit)1是0否*/
+	@Excel(name = "提交(submit)1是0否", width = 15)
+	@ApiModelProperty(value = "提交(submit)1是0否")
+    private String submit;
+	/**关闭(close)1是0否*/
+	@Excel(name = "关闭(close)1是0否", width = 15)
+	@ApiModelProperty(value = "关闭(close)1是0否")
+    private String close;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+	@ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    private Integer delFlag;
+	/**单据日期*/
+	@Excel(name = "单据日期", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+	@ApiModelProperty(value = "单据日期")
+    private Date billDate;
+	/**单据编码*/
+	@Excel(name = "单据编码", width = 15)
+	@ApiModelProperty(value = "单据编码")
+    private String billCode;
+	/**项目(project)*/
+	@Excel(name = "项目(project)", width = 15)
+	@ApiModelProperty(value = "项目(project)")
+    private String project;
+	/**项目名称*/
+	@Excel(name = "项目名称", width = 15)
+	@ApiModelProperty(value = "项目名称")
+    private String projectName;
+	/**供应商(supplier)*/
+	@Excel(name = "供应商(supplier)", width = 15)
+	@ApiModelProperty(value = "供应商(supplier)")
+    private String supplier;
+	/**供应商名称*/
+	@Excel(name = "供应商名称", width = 15)
+	@ApiModelProperty(value = "供应商名称")
+    private String supplierName;
+	/**业务类型(busyness type)*/
+	@Excel(name = "业务类型(busyness type)", width = 15)
+	@ApiModelProperty(value = "业务类型(busyness type)")
+    private String busynessType;
+	/**优先级(priority)*/
+	@Excel(name = "优先级(priority)", width = 15)
+	@ApiModelProperty(value = "优先级(priority)")
+    private String priority;
+	/**产品分类(production class)*/
+	@Excel(name = "产品分类(production class)", width = 15)
+	@ApiModelProperty(value = "产品分类(production class)")
+    private String productionClass;
+	/**机型(model)*/
+	@Excel(name = "机型(model)", width = 15)
+	@ApiModelProperty(value = "机型(model)")
+    private String model;
+	/**厂家(maker)*/
+	@Excel(name = "厂家(maker)", width = 15)
+	@ApiModelProperty(value = "厂家(maker)")
+    private String maker;
+	/**贸易条款(trade Terms)*/
+	@Excel(name = "贸易条款(trade Terms)", width = 15)
+	@ApiModelProperty(value = "贸易条款(trade Terms)")
+    private String tradeTerms;
+	/**是否出口(export)*/
+	@Excel(name = "是否出口(export)", width = 15)
+	@ApiModelProperty(value = "是否出口(export)")
+    private String isExport;
+	/**包装要求(packageb requirement)*/
+	@Excel(name = "包装要求(packageb requirement)", width = 15)
+	@ApiModelProperty(value = "包装要求(packageb requirement)")
+    private String packagebRequirement;
+	/**收件人(recipient)*/
+	@Excel(name = "收件人(recipient)", width = 15)
+	@ApiModelProperty(value = "收件人(recipient)")
+    private String recipient;
+	/**收件人电话(recipient tel)*/
+	@Excel(name = "收件人电话(recipient tel)", width = 15)
+	@ApiModelProperty(value = "收件人电话(recipient tel)")
+    private String recipientTel;
+	/**收件人地址(recipient address)*/
+	@Excel(name = "收件人地址(recipient address)", width = 15)
+	@ApiModelProperty(value = "收件人地址(recipient address)")
+    private String recipientAddress;
+	/**付款条件(payment terms)*/
+	@Excel(name = "付款条件(payment terms)", width = 15)
+	@ApiModelProperty(value = "付款条件(payment terms)")
+    private String paymentTerms;
+	/**发货方式(delivery)*/
+	@Excel(name = "发货方式(delivery)", width = 15)
+	@ApiModelProperty(value = "发货方式(delivery)")
+    private String delivery;
+	/**质保期(warranty period)/月*/
+	@Excel(name = "质保期(warranty period)/月", width = 15)
+	@ApiModelProperty(value = "质保期(warranty period)/月")
+    private String warrantyPeriod;
+	/**质保条款(warranty terms)*/
+	@Excel(name = "质保条款(warranty terms)", width = 15)
+	@ApiModelProperty(value = "质保条款(warranty terms)")
+    private String warrantyTerms;
+	/**汇率(exchange rate)*/
+	@Excel(name = "汇率(exchange rate)", width = 15)
+	@ApiModelProperty(value = "汇率(exchange rate)")
+    private java.math.BigDecimal exchangeRate;
+	/**采购员(purchaseman)*/
+	@Excel(name = "采购员(purchaseman)", width = 15)
+	@ApiModelProperty(value = "采购员(purchaseman)")
+    private String purchaseman;
+	/**采购部门(purchase department)*/
+	@Excel(name = "采购部门(purchase department)", width = 15)
+	@ApiModelProperty(value = "采购部门(purchase department)")
+    private String purchaseDepartment;
+	/**币种(currency)*/
+	@Excel(name = "币种(currency)", width = 15)
+	@ApiModelProperty(value = "币种(currency)")
+    private String currency;
+	/**备注(notes)*/
+	@Excel(name = "备注(notes)", width = 15)
+	@ApiModelProperty(value = "备注(notes)")
+    private String notes;
+	/**附件(attachs)*/
+	@Excel(name = "附件(attachs)", width = 15)
+	@ApiModelProperty(value = "附件(attachs)")
+    private String attachs;
+	/**版本号*/
+	@Excel(name = "版本号", width = 15)
+	@ApiModelProperty(value = "版本号")
+    private String version;
+	/**来源*/
+	@Excel(name = "来源", width = 15)
+	@ApiModelProperty(value = "来源")
+    private String sourceCode;
+	/**来源2*/
+	@Excel(name = "来源2", width = 15)
+	@ApiModelProperty(value = "来源2")
+    private String sourceCode2;
+
+	@ExcelCollection(name="采购订单子表 - 船明细(历史)")
+	@ApiModelProperty(value = "采购订单子表 - 船明细(历史)")
+	private List<PurOrderShipHis> purOrderShipHisList;
+	@ExcelCollection(name="采购订单子表 - 产品明细(历史)")
+	@ApiModelProperty(value = "采购订单子表 - 产品明细(历史)")
+	private List<PurOrderProductHis> purOrderProductHisList;
+
+}

+ 195 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/vo/PurOrderPage.java

@@ -0,0 +1,195 @@
+package org.jeecg.modules.purCode.vo;
+
+import java.util.List;
+import org.jeecg.modules.purCode.entity.PurOrder;
+import org.jeecg.modules.purCode.entity.PurOrderShip;
+import org.jeecg.modules.purCode.entity.PurOrderProduct;
+import lombok.Data;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import org.jeecgframework.poi.excel.annotation.ExcelEntity;
+import org.jeecgframework.poi.excel.annotation.ExcelCollection;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import java.util.Date;
+import org.jeecg.common.aspect.annotation.Dict;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+
+/**
+ * @Description: 采购订单
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Data
+@ApiModel(value="pur_orderPage对象", description="采购订单")
+public class PurOrderPage {
+
+	/**主键id*/
+	@ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+	@ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	@ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+	@ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	@ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**客户确认(1-已确认,0-未确认)*/
+	@Excel(name = "客户确认(1-已确认,0-未确认)", width = 15)
+	@ApiModelProperty(value = "客户确认(1-已确认,0-未确认)")
+    private Integer status;
+	/**提交(submit)1是0否*/
+	@Excel(name = "提交(submit)1是0否", width = 15)
+	@ApiModelProperty(value = "提交(submit)1是0否")
+    private String submit;
+	/**关闭(close)1是0否*/
+	@Excel(name = "关闭(close)1是0否", width = 15)
+	@ApiModelProperty(value = "关闭(close)1是0否")
+    private String close;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+	@ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    private Integer delFlag;
+	/**单据日期*/
+	@Excel(name = "单据日期", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+	@ApiModelProperty(value = "单据日期")
+    private Date billDate;
+	/**单据编码*/
+	@Excel(name = "单据编码", width = 15)
+	@ApiModelProperty(value = "单据编码")
+    private String billCode;
+	/**项目(project)*/
+	@Excel(name = "项目(project)", width = 15)
+	@ApiModelProperty(value = "项目(project)")
+    private String project;
+	/**项目名称*/
+	@Excel(name = "项目名称", width = 15)
+	@ApiModelProperty(value = "项目名称")
+    private String projectName;
+	/**供应商(supplier)*/
+	@Excel(name = "供应商(supplier)", width = 15)
+	@ApiModelProperty(value = "供应商(supplier)")
+    private String supplier;
+	/**供应商名称*/
+	@Excel(name = "供应商名称", width = 15)
+	@ApiModelProperty(value = "供应商名称")
+    private String supplierName;
+	/**业务类型(busyness type)*/
+	@Excel(name = "业务类型(busyness type)", width = 15)
+	@ApiModelProperty(value = "业务类型(busyness type)")
+    private String busynessType;
+	/**优先级(priority)*/
+	@Excel(name = "优先级(priority)", width = 15)
+	@ApiModelProperty(value = "优先级(priority)")
+    private String priority;
+	/**产品分类(production class)*/
+	@Excel(name = "产品分类(production class)", width = 15)
+	@ApiModelProperty(value = "产品分类(production class)")
+    private String productionClass;
+	/**机型(model)*/
+	@Excel(name = "机型(model)", width = 15)
+	@ApiModelProperty(value = "机型(model)")
+    private String model;
+	/**厂家(maker)*/
+	@Excel(name = "厂家(maker)", width = 15)
+	@ApiModelProperty(value = "厂家(maker)")
+    private String maker;
+	/**贸易条款(trade Terms)*/
+	@Excel(name = "贸易条款(trade Terms)", width = 15)
+	@ApiModelProperty(value = "贸易条款(trade Terms)")
+    private String tradeTerms;
+	/**是否出口(export)*/
+	@Excel(name = "是否出口(export)", width = 15)
+	@ApiModelProperty(value = "是否出口(export)")
+    private String isExport;
+	/**包装要求(packageb requirement)*/
+	@Excel(name = "包装要求(packageb requirement)", width = 15)
+	@ApiModelProperty(value = "包装要求(packageb requirement)")
+    private String packagebRequirement;
+	/**收件人(recipient)*/
+	@Excel(name = "收件人(recipient)", width = 15)
+	@ApiModelProperty(value = "收件人(recipient)")
+    private String recipient;
+	/**收件人电话(recipient tel)*/
+	@Excel(name = "收件人电话(recipient tel)", width = 15)
+	@ApiModelProperty(value = "收件人电话(recipient tel)")
+    private String recipientTel;
+	/**收件人地址(recipient address)*/
+	@Excel(name = "收件人地址(recipient address)", width = 15)
+	@ApiModelProperty(value = "收件人地址(recipient address)")
+    private String recipientAddress;
+	/**付款条件(payment terms)*/
+	@Excel(name = "付款条件(payment terms)", width = 15)
+	@ApiModelProperty(value = "付款条件(payment terms)")
+    private String paymentTerms;
+	/**发货方式(delivery)*/
+	@Excel(name = "发货方式(delivery)", width = 15)
+	@ApiModelProperty(value = "发货方式(delivery)")
+    private String delivery;
+	/**质保期(warranty period)/月*/
+	@Excel(name = "质保期(warranty period)/月", width = 15)
+	@ApiModelProperty(value = "质保期(warranty period)/月")
+    private String warrantyPeriod;
+	/**质保条款(warranty terms)*/
+	@Excel(name = "质保条款(warranty terms)", width = 15)
+	@ApiModelProperty(value = "质保条款(warranty terms)")
+    private String warrantyTerms;
+	/**汇率(exchange rate)*/
+	@Excel(name = "汇率(exchange rate)", width = 15)
+	@ApiModelProperty(value = "汇率(exchange rate)")
+    private java.math.BigDecimal exchangeRate;
+	/**采购员(purchaseman)*/
+	@Excel(name = "采购员(purchaseman)", width = 15)
+	@ApiModelProperty(value = "采购员(purchaseman)")
+    private String purchaseman;
+	/**采购部门(purchase department)*/
+	@Excel(name = "采购部门(purchase department)", width = 15)
+	@ApiModelProperty(value = "采购部门(purchase department)")
+    private String purchaseDepartment;
+	/**币种(currency)*/
+	@Excel(name = "币种(currency)", width = 15)
+	@ApiModelProperty(value = "币种(currency)")
+    private String currency;
+	/**备注(notes)*/
+	@Excel(name = "备注(notes)", width = 15)
+	@ApiModelProperty(value = "备注(notes)")
+    private String notes;
+	/**附件(attachs)*/
+	@Excel(name = "附件(attachs)", width = 15)
+	@ApiModelProperty(value = "附件(attachs)")
+    private String attachs;
+	/**版本号*/
+	@Excel(name = "版本号", width = 15)
+	@ApiModelProperty(value = "版本号")
+    private String version;
+	/**来源*/
+	@Excel(name = "来源", width = 15)
+	@ApiModelProperty(value = "来源")
+    private String sourceCode;
+	/**来源2*/
+	@Excel(name = "来源2", width = 15)
+	@ApiModelProperty(value = "来源2")
+    private String sourceCode2;
+
+	@ExcelCollection(name="采购订单子表 - 船明细")
+	@ApiModelProperty(value = "采购订单子表 - 船明细")
+	private List<PurOrderShip> purOrderShipList;
+	@ExcelCollection(name="采购订单子表 - 产品明细")
+	@ApiModelProperty(value = "采购订单子表 - 产品明细")
+	private List<PurOrderProduct> purOrderProductList;
+
+}

+ 73 - 73
srm-module-code/src/main/java/org/jeecg/modules/purCode/vo/PurPurchaseQuotationPage.java

@@ -1,19 +1,17 @@
 package org.jeecg.modules.purCode.vo;
 
 import java.util.List;
-import org.jeecg.modules.purCode.entity.PurPurchaseQuotation;
+
+import com.baomidou.mybatisplus.annotation.TableLogic;
 import org.jeecg.modules.purCode.entity.PurPurchaseQuotationShip;
-import org.jeecg.modules.purCode.entity.PurPurchaseInquiryProduct;
+import org.jeecg.modules.purCode.entity.PurPurchaseQuotationProduct;
 import lombok.Data;
 import org.jeecgframework.poi.excel.annotation.Excel;
-import org.jeecgframework.poi.excel.annotation.ExcelEntity;
 import org.jeecgframework.poi.excel.annotation.ExcelCollection;
 import com.fasterxml.jackson.annotation.JsonFormat;
 import org.springframework.format.annotation.DateTimeFormat;
 import java.util.Date;
-import org.jeecg.common.aspect.annotation.Dict;
-import org.jeecg.common.constant.ProvinceCityArea;
-import org.jeecg.common.util.SpringContextUtils;
+
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 
@@ -29,137 +27,139 @@ public class PurPurchaseQuotationPage {
 
 	/**主键id*/
 	@ApiModelProperty(value = "主键id")
-    private String id;
+	private String id;
 	/**创建人*/
 	@ApiModelProperty(value = "创建人")
-    private String createBy;
+	private String createBy;
 	/**创建时间*/
 	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
-    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
 	@ApiModelProperty(value = "创建时间")
-    private Date createTime;
+	private Date createTime;
 	/**更新人*/
 	@ApiModelProperty(value = "更新人")
-    private String updateBy;
+	private String updateBy;
 	/**更新时间*/
 	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
-    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
 	@ApiModelProperty(value = "更新时间")
-    private Date updateTime;
+	private Date updateTime;
 	/**状态(1-结束,0-报价中)*/
 	@Excel(name = "状态(1-结束,0-报价中)", width = 15)
 	@ApiModelProperty(value = "状态(1-结束,0-报价中)")
-    private Integer status;
+	private Integer status;
 	/**删除状态(0-正常,1-已删除)*/
 	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
 	@ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
-    private Integer delFlag;
+	@TableLogic
+	private Integer delFlag;
 	/**提交(1是 0否)*/
 	@Excel(name = "提交(1是 0否)", width = 15)
 	@ApiModelProperty(value = "提交(1是 0否)")
-    private String submit;
+	private String submit;
 	/**单据日期(bill date)*/
 	@Excel(name = "单据日期(bill date)", width = 15, format = "yyyy-MM-dd")
 	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
-    @DateTimeFormat(pattern="yyyy-MM-dd")
+	@DateTimeFormat(pattern="yyyy-MM-dd")
 	@ApiModelProperty(value = "单据日期(bill date)")
-    private Date billDate;
-	/**价单号(bill code)*/
-	@Excel(name = "价单号(bill code)", width = 15)
-	@ApiModelProperty(value = "价单号(bill code)")
-    private String billCode;
-	/**询价项目(inquiry project)*/
-	@Excel(name = "询价项目(inquiry project)", width = 15)
-	@ApiModelProperty(value = "询价项目(inquiry project)")
-    private String inquiryProject;
+	private Date billDate;
+	/**价单号(bill code)*/
+	@Excel(name = "价单号(bill code)", width = 15)
+	@ApiModelProperty(value = "价单号(bill code)")
+	private String billCode;
+	/**报价项目(quotation project)*/
+	@Excel(name = "报价项目(quotation project)", width = 15)
+	@ApiModelProperty(value = "报价项目(quotation project)")
+	private String quotationProject;
 	/**项目名称*/
 	@Excel(name = "项目名称", width = 15)
 	@ApiModelProperty(value = "项目名称")
-    private String projectName;
-	/**询价供应商(inquiry supplier)*/
-	@Excel(name = "询价供应商(inquiry supplier)", width = 15)
-	@ApiModelProperty(value = "询价供应商(inquiry supplier)")
-    private String inquirySuppiler;
+	private String projectName;
+	/**报价供应商(quotation supplier)*/
+	@Excel(name = "报价供应商(quotation supplier)", width = 15)
+	@ApiModelProperty(value = "报价供应商(quotation supplier)")
+	private String quotationSuppiler;
 	/**供应商名称*/
 	@Excel(name = "供应商名称", width = 15)
 	@ApiModelProperty(value = "供应商名称")
-    private String suppilerName;
-	/**询价有效期(inquiry period)止*/
-	@Excel(name = "询价有效期(inquiry period)止", width = 15, format = "yyyy-MM-dd")
+	private String suppilerName;
+	/**报价有效期(quotation period)止*/
+	@Excel(name = "报价截止日期(quotationDeadline)", width = 15, format = "yyyy-MM-dd")
 	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
-    @DateTimeFormat(pattern="yyyy-MM-dd")
-	@ApiModelProperty(value = "询价有效期(inquiry period)止")
-    private Date inquiryPeriodEnd;
-	/**询价有效期(inquiry period)始*/
-	@Excel(name = "询价有效期(inquiry period)始", width = 15, format = "yyyy-MM-dd")
-	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
-    @DateTimeFormat(pattern="yyyy-MM-dd")
-	@ApiModelProperty(value = "询价有效期(inquiry period)始")
-    private Date inquiryPeriodBegin;
+	@DateTimeFormat(pattern="yyyy-MM-dd")
+	@ApiModelProperty(value = "报价截止日期(quotationDeadline)")
+	private Date quotationDeadline;
 	/**业务类型(busyness type)*/
 	@Excel(name = "业务类型(busyness type)", width = 15)
 	@ApiModelProperty(value = "业务类型(busyness type)")
-    private String busynessType;
+	private String busynessType;
 	/**优先级(priority)*/
 	@Excel(name = "优先级(priority)", width = 15)
 	@ApiModelProperty(value = "优先级(priority)")
-    private String priority;
+	private String priority;
 	/**产品分类(production class)*/
 	@Excel(name = "产品分类(production class)", width = 15)
 	@ApiModelProperty(value = "产品分类(production class)")
-    private String productionClass;
+	private String productionClass;
 	/**机型(model)*/
 	@Excel(name = "机型(model)", width = 15)
 	@ApiModelProperty(value = "机型(model)")
-    private String model;
+	private String model;
 	/**厂家(maker)*/
 	@Excel(name = "厂家(maker)", width = 15)
 	@ApiModelProperty(value = "厂家(maker)")
-    private String maker;
+	private String maker;
 	/**交货地点(place of delivery)*/
 	@Excel(name = "交货地点(place of delivery)", width = 15)
 	@ApiModelProperty(value = "交货地点(place of delivery)")
-    private String placeDelivery;
+	private String placeDelivery;
 	/**付款条件(payment terms)*/
 	@Excel(name = "付款条件(payment terms)", width = 15)
 	@ApiModelProperty(value = "付款条件(payment terms)")
-    private String paymentTerms;
+	private String paymentTerms;
+	//付款条件-二段信息
+	private String paymentTermsInfo;
 	/**发货方式(delivery)*/
 	@Excel(name = "发货方式(delivery)", width = 15)
 	@ApiModelProperty(value = "发货方式(delivery)")
-    private String delivery;
+	private String delivery;
 	/**交期(delivery time)*/
 	@Excel(name = "交期(delivery time)", width = 15, format = "yyyy-MM-dd")
 	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
-    @DateTimeFormat(pattern="yyyy-MM-dd")
+	@DateTimeFormat(pattern="yyyy-MM-dd")
 	@ApiModelProperty(value = "交期(delivery time)")
-    private Date deliveryTime;
+	private Date deliveryTime;
 	/**报价有效期(quotation validity period)/天*/
 	@Excel(name = "报价有效期(quotation validity period)/天", width = 15)
 	@ApiModelProperty(value = "报价有效期(quotation validity period)/天")
-    private Double quotationValidity;
-	/**采购询价组(procurement inquiry team)*/
-	@Excel(name = "采购询价组(procurement inquiry team)", width = 15)
-	@ApiModelProperty(value = "采购询价组(procurement inquiry team)")
-    private String inquiryTeam;
-	/**附件(attachs)*/
-	@Excel(name = "附件(attachs)", width = 15)
-	@ApiModelProperty(value = "附件(attachs)")
-    private String attachs;
-	/**询价备注(inquiry notes)*/
-	@Excel(name = "询价备注(inquiry notes)", width = 15)
-	@ApiModelProperty(value = "询价备注(inquiry notes)")
-    private String inquiryNotes;
-	/**来源单号(采购询价单)*/
-	@Excel(name = "来源单号(采购询价单)", width = 15)
-	@ApiModelProperty(value = "来源单号(采购询价单)")
-    private String sourceCode;
+	private Double quotationValidity;
+
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+	@DateTimeFormat(pattern="yyyy-MM-dd")
+	@ApiModelProperty(value = "报价有效期(日期)(quotationValidityDate)")
+	private Date quotationValidityDate;
+
+
+	//币种
+	private String currency;
+	//技术资料
+	private String technicalInformation;
+	//报价资料
+	private String quotationInfomation;
+	/**报价备注(quotation notes)*/
+	@Excel(name = "报价备注(quotation notes)", width = 15)
+	@ApiModelProperty(value = "报价备注(quotation notes)")
+	private String quotationNotes;
+	/**来源单号(采购报价单)*/
+	@Excel(name = "来源单号(采购报价单)", width = 15)
+	@ApiModelProperty(value = "来源单号(采购报价单)")
+	private String sourceCode;
 
 	@ExcelCollection(name="采购报价单 - 船明细")
 	@ApiModelProperty(value = "采购报价单 - 船明细")
 	private List<PurPurchaseQuotationShip> purPurchaseQuotationShipList;
-	@ExcelCollection(name="采购价单子表 - 产品明细")
-	@ApiModelProperty(value = "采购价单子表 - 产品明细")
-	private List<PurPurchaseInquiryProduct> purPurchaseInquiryProductList;
+	@ExcelCollection(name="采购价单子表 - 产品明细")
+	@ApiModelProperty(value = "采购价单子表 - 产品明细")
+	private List<PurPurchaseQuotationProduct> purPurchaseQuotationProductList;
 
 }

+ 238 - 0
srm-module-code/src/main/java/org/jeecg/modules/purCode/vo/SupplierQuotationDetails.java

@@ -0,0 +1,238 @@
+package org.jeecg.modules.purCode.vo;
+
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import org.springframework.format.annotation.DateTimeFormat;
+
+import java.util.Date;
+@Data
+@TableName("SupplierQuotationDetails")
+public class SupplierQuotationDetails {
+
+    /**主键id*/
+    @ApiModelProperty(value = "主键id")
+    private String id;
+    private String headId;
+    private String childId;
+    /**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+    /**创建时间*/
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+    /**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+    /**更新时间*/
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+    /**状态(1-结束,0-报价中)*/
+    @Excel(name = "状态(1-结束,0-报价中)", width = 15)
+    @ApiModelProperty(value = "状态(1-结束,0-报价中)")
+    private Integer status;
+    /**删除状态(0-正常,1-已删除)*/
+    @Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+    @ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+    /**提交(1是 0否)*/
+    @Excel(name = "提交(1是 0否)", width = 15)
+    @ApiModelProperty(value = "提交(1是 0否)")
+    private String submit;
+    /**单据日期(bill date)*/
+    @Excel(name = "单据日期(bill date)", width = 15, format = "yyyy-MM-dd")
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "单据日期(bill date)")
+    private Date billDate;
+    /**报价单号(bill code)*/
+    @Excel(name = "报价单号(bill code)", width = 15)
+    @ApiModelProperty(value = "报价单号(bill code)")
+    private String billCode;
+    /**报价项目(quotation project)*/
+    @Excel(name = "报价项目(quotation project)", width = 15)
+    @ApiModelProperty(value = "报价项目(quotation project)")
+    private String quotationProject;
+    /**项目名称*/
+    @Excel(name = "项目名称", width = 15)
+    @ApiModelProperty(value = "项目名称")
+    private String projectName;
+    /**报价供应商(quotation supplier)*/
+    @Excel(name = "报价供应商(quotation supplier)", width = 15)
+    @ApiModelProperty(value = "报价供应商(quotation supplier)")
+    private String quotationSuppiler;
+    /**供应商名称*/
+    @Excel(name = "供应商名称", width = 15)
+    @ApiModelProperty(value = "供应商名称")
+    private String suppilerName;
+    /**报价有效期(quotation period)止*/
+    @Excel(name = "报价截止日期(quotationDeadline)", width = 15, format = "yyyy-MM-dd")
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "报价截止日期(quotationDeadline)")
+    private Date quotationDeadline;
+    /**业务类型(busyness type)*/
+    @Excel(name = "业务类型(busyness type)", width = 15)
+    @ApiModelProperty(value = "业务类型(busyness type)")
+    private String busynessType;
+    /**优先级(priority)*/
+    @Excel(name = "优先级(priority)", width = 15)
+    @ApiModelProperty(value = "优先级(priority)")
+    private String priority;
+    /**产品分类(production class)*/
+    @Excel(name = "产品分类(production class)", width = 15)
+    @ApiModelProperty(value = "产品分类(production class)")
+    private String productionClass;
+    /**机型(model)*/
+    @Excel(name = "机型(model)", width = 15)
+    @ApiModelProperty(value = "机型(model)")
+    private String headModel;
+    /**厂家(maker)*/
+    @Excel(name = "厂家(maker)", width = 15)
+    @ApiModelProperty(value = "厂家(maker)")
+    private String maker;
+    /**交货地点(place of delivery)*/
+    @Excel(name = "交货地点(place of delivery)", width = 15)
+    @ApiModelProperty(value = "交货地点(place of delivery)")
+    private String placeDelivery;
+    /**付款条件(payment terms)*/
+    @Excel(name = "付款条件(payment terms)", width = 15)
+    @ApiModelProperty(value = "付款条件(payment terms)")
+    private String paymentTerms;
+    //付款条件-二段信息
+    private String paymentTermsInfo;
+    /**发货方式(delivery)*/
+    @Excel(name = "发货方式(delivery)", width = 15)
+    @ApiModelProperty(value = "发货方式(delivery)")
+    private String delivery;
+    /**交期(delivery time)*/
+    @Excel(name = "交期(delivery time)", width = 15, format = "yyyy-MM-dd")
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "交期(delivery time)")
+    private Date headDeliveryTime;
+    /**报价有效期(quotation validity period)/天*/
+    @Excel(name = "报价有效期(quotation validity period)/天", width = 15)
+    @ApiModelProperty(value = "报价有效期(quotation validity period)/天")
+    private Double quotationValidity;
+
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "报价有效期(日期)(quotationValidityDate)")
+    private Date quotationValidityDate;
+
+    //币种
+    private String currency;
+    //技术资料
+    private String technicalInformation;
+    //报价资料
+    private String quotationInfomation;
+    /**报价备注(quotation notes)*/
+    @Excel(name = "报价备注(quotation notes)", width = 15)
+    @ApiModelProperty(value = "报价备注(quotation notes)")
+    private String quotationNotes;
+    /**来源单号(采购报价单)*/
+    @Excel(name = "来源单号(采购报价单)", width = 15)
+    @ApiModelProperty(value = "来源单号(采购报价单)")
+    private String sourceCode;
+
+
+    /**交期*/
+    @Excel(name = "交期", width = 15, format = "yyyy-MM-dd")
+    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "交期")
+    private Date childDeliveryTime;
+    /**产品id*/
+    @Excel(name = "产品id", width = 15)
+    @ApiModelProperty(value = "产品id")
+    private String productId;
+    /**产品分类*/
+    @Excel(name = "产品分类", width = 15)
+    @ApiModelProperty(value = "产品分类")
+    private String productClass;
+    /**产品编码*/
+    @Excel(name = "产品编码", width = 15)
+    @ApiModelProperty(value = "产品编码")
+    private String productCode;
+    /**产品中文名*/
+    @Excel(name = "产品中文名", width = 15)
+    @ApiModelProperty(value = "产品中文名")
+    private String chineseName;
+    /**产品英文名*/
+    @Excel(name = "产品英文名", width = 15)
+    @ApiModelProperty(value = "产品英文名")
+    private String englishName;
+    /**规格*/
+    @Excel(name = "规格", width = 15)
+    @ApiModelProperty(value = "规格")
+    private String specifications;
+    /**型号*/
+    @Excel(name = "型号", width = 15)
+    @ApiModelProperty(value = "型号")
+    private String childModel;
+    /**备件号*/
+    @Excel(name = "备件号", width = 15)
+    @ApiModelProperty(value = "备件号")
+    private String partno;
+    /**图号*/
+    @Excel(name = "图号", width = 15)
+    @ApiModelProperty(value = "图号")
+    private String drawingno;
+    /**订货号*/
+    @Excel(name = "订货号", width = 15)
+    @ApiModelProperty(value = "订货号")
+    private String orderno;
+    /**厂家*/
+    @Excel(name = "厂家", width = 15)
+    @ApiModelProperty(value = "厂家")
+    private String factory;
+    /**质量等级*/
+    @Excel(name = "质量等级", width = 15)
+    @ApiModelProperty(value = "质量等级")
+    private String qualityGrade;
+    /**单位*/
+    @Excel(name = "单位", width = 15)
+    @ApiModelProperty(value = "单位")
+    private String unit;
+    /**需要船检证书(1是 0否)*/
+    @Excel(name = "需要船检证书(1是 0否)", width = 15)
+    @ApiModelProperty(value = "需要船检证书(1是 0否)")
+    private String needShip;
+    /**船检证书*/
+    @Excel(name = "船检证书", width = 15)
+    @ApiModelProperty(value = "船检证书")
+    private String shipInspection;
+    /**数量*/
+    @Excel(name = "数量", width = 15)
+    @ApiModelProperty(value = "数量")
+    private java.math.BigDecimal quantity;
+    /**含税单价*/
+    @Excel(name = "含税单价", width = 15)
+    @ApiModelProperty(value = "含税单价")
+    private java.math.BigDecimal taxPrice;
+    /**上一次报价*/
+    @Excel(name = "上一次报价", width = 15)
+    @ApiModelProperty(value = "上一次报价")
+    private java.math.BigDecimal lastPrice;
+    /**含税金额*/
+    @Excel(name = "含税金额", width = 15)
+    @ApiModelProperty(value = "含税金额")
+    private String taxAmount;
+    /**备注*/
+    @Excel(name = "备注", width = 15)
+    @ApiModelProperty(value = "备注")
+    private String notes;
+    /**来源id(采购询价单-产品id)*/
+    @Excel(name = "来源id(采购询价单-产品id)", width = 15)
+    @ApiModelProperty(value = "来源id(采购询价单-产品id)")
+    private String sourceId;
+}

+ 721 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/controller/SaleOrderController.java

@@ -0,0 +1,721 @@
+package org.jeecg.modules.saleCode.controller;
+
+import java.io.UnsupportedEncodingException;
+import java.io.IOException;
+import java.net.URLDecoder;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+import java.util.Map;
+import java.util.stream.Collectors;
+import java.util.HashMap;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+
+import org.apache.commons.lang.StringUtils;
+import org.jeecg.modules.baseCode.service.ISerialPatternService;
+import org.jeecg.modules.saleCode.entity.*;
+import org.jeecg.modules.saleCode.service.ISaleOrderHisService;
+import org.jeecgframework.poi.excel.ExcelImportUtil;
+import org.jeecgframework.poi.excel.def.NormalExcelConstants;
+import org.jeecgframework.poi.excel.entity.ExportParams;
+import org.jeecgframework.poi.excel.entity.ImportParams;
+import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
+import org.jeecg.common.system.vo.LoginUser;
+import org.apache.shiro.SecurityUtils;
+import org.jeecg.common.api.vo.Result;
+import org.jeecg.common.system.query.QueryGenerator;
+import org.jeecg.common.system.query.QueryRuleEnum;
+import org.jeecg.common.util.oConvertUtils;
+import org.jeecg.modules.saleCode.entity.SaleOrder;
+import org.jeecg.modules.saleCode.vo.SaleOrderPage;
+import org.jeecg.modules.saleCode.service.ISaleOrderService;
+import org.jeecg.modules.saleCode.service.ISaleOrderShipService;
+import org.jeecg.modules.saleCode.service.ISaleOrderProductService;
+import org.springframework.beans.BeanUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+import org.springframework.web.servlet.ModelAndView;
+import org.springframework.web.multipart.MultipartFile;
+import org.springframework.web.multipart.MultipartHttpServletRequest;
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import lombok.extern.slf4j.Slf4j;
+import com.alibaba.fastjson.JSON;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.jeecg.common.aspect.annotation.AutoLog;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+
+
+ /**
+ * @Description: 销售订单
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Api(tags="销售订单")
+@RestController
+@RequestMapping("/saleCode/saleOrder")
+@Slf4j
+public class SaleOrderController {
+	@Autowired
+	private ISaleOrderService saleOrderService;
+	@Autowired
+	private ISaleOrderShipService saleOrderShipService;
+	@Autowired
+	private ISaleOrderProductService saleOrderProductService;
+	@Autowired
+	 private ISaleOrderHisService saleOrderHisService;
+	 @Autowired
+	 private ISerialPatternService serialPatternService;
+	/**
+	 * 分页列表查询
+	 *
+	 * @param saleOrder
+	 * @param pageNo
+	 * @param pageSize
+	 * @param req
+	 * @return
+	 */
+	//@AutoLog(value = "销售订单-分页列表查询")
+	@ApiOperation(value="销售订单-分页列表查询", notes="销售订单-分页列表查询")
+	@GetMapping(value = "/list")
+	public Result<IPage<SaleOrder>> queryPageList(SaleOrder saleOrder,
+								   @RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
+								   @RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
+								   HttpServletRequest req) {
+        QueryWrapper<SaleOrder> queryWrapper = QueryGenerator.initQueryWrapper(saleOrder, req.getParameterMap());
+		Page<SaleOrder> page = new Page<SaleOrder>(pageNo, pageSize);
+		IPage<SaleOrder> pageList = saleOrderService.page(page, queryWrapper);
+		return Result.OK(pageList);
+	}
+	
+	/**
+	 *   添加
+	 *
+	 * @param saleOrderPage
+	 * @return
+	 */
+	@AutoLog(value = "销售订单-添加")
+	@ApiOperation(value="销售订单-添加", notes="销售订单-添加")
+    @RequiresPermissions("saleCode:sale_order:add")
+	@PostMapping(value = "/add")
+	public Result<String> add(@RequestBody SaleOrderPage saleOrderPage) {
+		SaleOrder saleOrder = new SaleOrder();
+		BeanUtils.copyProperties(saleOrderPage, saleOrder);
+
+		String code = saleOrder.getBillCode();
+		if (StringUtils.isNotBlank(code)) {
+
+			QueryWrapper<SaleOrder> queryWrapper = new QueryWrapper();
+			queryWrapper.eq("bill_code", code);
+			queryWrapper.eq("del_flag", "0");
+
+			List<SaleOrder> list = saleOrderService.list(queryWrapper);
+			if (list.size() != 0) {
+				return Result.error("销售订单编码重复,请修改!");
+			}
+		} else {
+
+			Result<String> result = serialPatternService.getNextSerial("sale_order", "bill_code");
+			if (!result.isSuccess()) {
+				return result;
+			}
+			saleOrder.setBillCode(result.getMessage());
+		}
+
+
+		saleOrderService.saveMain(saleOrder, saleOrderPage.getSaleOrderShipList(),saleOrderPage.getSaleOrderProductList());
+		return Result.OK("添加成功!");
+	}
+	
+	/**
+	 *  编辑
+	 *
+	 * @param saleOrderPage
+	 * @return
+	 */
+	@AutoLog(value = "销售订单-编辑")
+	@ApiOperation(value="销售订单-编辑", notes="销售订单-编辑")
+    @RequiresPermissions("saleCode:sale_order:edit")
+	@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
+	public Result<String> edit(@RequestBody SaleOrderPage saleOrderPage) {
+		SaleOrder saleOrder = new SaleOrder();
+		BeanUtils.copyProperties(saleOrderPage, saleOrder);
+		SaleOrder saleOrderEntity = saleOrderService.getById(saleOrder.getId());
+		if(saleOrderEntity==null) {
+			return Result.error("未找到对应数据");
+		}
+		saleOrder.setVersion("1");
+		saleOrderService.updateMain(saleOrder, saleOrderPage.getSaleOrderShipList(),saleOrderPage.getSaleOrderProductList());
+		return Result.OK("编辑成功!");
+	}
+
+
+	 /**
+	  * 修订
+	  *
+	  * @param saleOrderPage
+	  * @return
+	  */
+	 @AutoLog(value = "销售订单-修订")
+	 @ApiOperation(value = "销售订单-修订", notes = "销售订单-修订")
+	 @RequiresPermissions("saleCode:sale_order:editHis")
+	 @RequestMapping(value = "/editHis", method = {RequestMethod.PUT, RequestMethod.POST})
+	 public Result<String> editHis(@RequestBody SaleOrderPage saleOrderPage) {
+		 SaleOrder saleOrder = new SaleOrder();
+		 BeanUtils.copyProperties(saleOrderPage, saleOrder);
+		 SaleOrder saleOrderEntity = saleOrderService.getById(saleOrder.getId());
+		 if (saleOrderEntity == null) {
+			 return Result.error("未找到对应数据");
+		 }
+		 //提交(submit)1是0否
+		 String submit = saleOrderEntity.getSubmit();
+
+		 if (submit == null || submit == "" || !submit.equals(1)) {
+			 return Result.error("未提交的单据不能进行修订!");
+		 }
+
+		 String version = saleOrderEntity.getVersion();
+		 int newV = Integer.valueOf(version) + 1;
+
+		 List<SaleOrderShipHis> saleOrderShipHisList = new ArrayList<>();
+		 if(saleOrderPage.getSaleOrderShipList().size() > 0){
+			 for (SaleOrderShip o : saleOrderPage.getSaleOrderShipList()) {
+				 SaleOrderShipHis his = new SaleOrderShipHis();
+				 BeanUtils.copyProperties(o,his);
+				 his.setId(null);
+				 his.setHisId(o.getId());
+				 saleOrderShipHisList.add(his);
+			 }
+
+		 }
+
+		 List<SaleOrderProductHis> saleOrderProductList = new ArrayList<>();
+		 if(saleOrderPage.getSaleOrderProductList().size() > 0){
+
+			 for (SaleOrderProduct o : saleOrderPage.getSaleOrderProductList()) {
+				 SaleOrderProductHis his = new SaleOrderProductHis();
+				 BeanUtils.copyProperties(o,his);
+				 his.setId(null);
+				 his.setHisId(o.getId());
+				 saleOrderProductList.add(his);
+			 }
+
+		 }
+
+		 SaleOrderHis saleOrderHis = new SaleOrderHis();
+		 BeanUtils.copyProperties(saleOrderPage,saleOrderHis);
+		 saleOrderHis.setId(null);
+		 saleOrderHis.setHisId(saleOrderPage.getId());
+		 saleOrderHis.setVersion(version);
+		 saleOrderHisService.saveMain(saleOrderHis, saleOrderShipHisList, saleOrderProductList);
+
+		 saleOrder.setVersion(String.valueOf(newV));
+
+		 saleOrderService.updateMain(saleOrder, saleOrderPage.getSaleOrderShipList(), saleOrderPage.getSaleOrderProductList());
+		 return Result.OK("编辑成功!");
+	 }
+
+
+	/**
+	 *   通过id删除
+	 *
+	 * @param id
+	 * @return
+	 */
+	@AutoLog(value = "销售订单-通过id删除")
+	@ApiOperation(value="销售订单-通过id删除", notes="销售订单-通过id删除")
+    @RequiresPermissions("saleCode:sale_order:delete")
+	@DeleteMapping(value = "/delete")
+	public Result<String> delete(@RequestParam(name="id",required=true) String id) {
+
+		SaleOrder order = saleOrderService.getById(id);
+		if(order==null) {
+			return Result.error("未找到对应数据");
+		}
+		String submit = order.getSubmit();
+		if(StringUtils.isNotBlank(submit) && submit.equals("1")){
+			return Result.error("已提交的数据无法删除");
+		}
+		saleOrderService.delMain(id);
+		return Result.OK("删除成功!");
+	}
+	
+	/**
+	 *  批量删除
+	 *
+	 * @param ids
+	 * @return
+	 */
+	@AutoLog(value = "销售订单-批量删除")
+	@ApiOperation(value="销售订单-批量删除", notes="销售订单-批量删除")
+    @RequiresPermissions("saleCode:sale_order:deleteBatch")
+	@DeleteMapping(value = "/deleteBatch")
+	public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
+
+		for(String o:ids.split(",")){
+			SaleOrder order = saleOrderService.getById(o);
+			if(order==null) {
+				return Result.error("未找到对应数据");
+			}
+			String submit = order.getSubmit();
+			if(StringUtils.isNotBlank(submit) && submit.equals("1")){
+				return Result.error("单号"+order.getBillCode()+"已提交,无法删除");
+			}
+		}
+
+		this.saleOrderService.delBatchMain(Arrays.asList(ids.split(",")));
+		return Result.OK("批量删除成功!");
+	}
+
+
+	 /**
+	  * 批量提交
+	  *
+	  * @param ids
+	  * @return
+	  */
+	 @AutoLog(value = "销售订单-批量提交")
+	 @ApiOperation(value = "销售订单-批量提交", notes = "销售订单-批量提交")
+	 @GetMapping(value = "/submitBatch")
+	 public Result<String> submitBatch(@RequestParam(name = "ids", required = true) String ids) {
+
+		 QueryWrapper<SaleOrder> queryWrapper = new QueryWrapper<>();
+		 queryWrapper.in("id", Arrays.asList(ids.split(",")));
+
+		 List<SaleOrder> list = saleOrderService.list(queryWrapper);
+		 if (list.size() == 0) {
+			 return Result.error("数据为空!");
+		 }
+
+		 StringBuffer sb = new StringBuffer();
+		 for (SaleOrder o : list) {
+			 // 1-已提交,0-未提交
+			 String submit = o.getSubmit();
+			 String code = o.getBillCode();
+
+			 //关闭(close)1是0否
+			 String getClose = o.getClose();
+
+			 if (StringUtils.isNotBlank(getClose) && !getClose.equals("1")) {
+				 sb.append("单号" + code).append("已关闭,无法执行此操作;");
+				 continue;
+			 }
+			 if (submit != null && submit != "" && submit.equals("1")) {
+				 sb.append("单据编码" + code).append("已提交,请勿再次提交;");
+				 continue;
+			 }
+		 }
+
+		 if (StringUtils.isNotBlank(sb.toString())) {
+
+			 return Result.error(sb.toString());
+		 }
+
+		 SaleOrder ent = new SaleOrder();
+		 ent.setSubmit("1");
+		 saleOrderService.update(ent, queryWrapper);
+
+		 return Result.OK("提交成功!");
+	 }
+
+	 /**
+	  * 批量取消提交
+	  *
+	  * @param ids
+	  * @return
+	  */
+	 @AutoLog(value = "销售订单-批量取消提交")
+	 @ApiOperation(value = "销售订单-批量取消提交", notes = "销售订单-批量取消提交")
+	 @GetMapping(value = "/returnSubmitBatch")
+	 public Result<String> returnSubmitBatch(@RequestParam(name = "ids", required = true) String ids) {
+
+		 QueryWrapper<SaleOrder> queryWrapper = new QueryWrapper<>();
+		 queryWrapper.in("id", Arrays.asList(ids.split(",")));
+
+		 List<SaleOrder> list = saleOrderService.list(queryWrapper);
+		 if (list.size() == 0) {
+			 return Result.error("数据为空!");
+		 }
+
+		 StringBuffer sb = new StringBuffer();
+		 for (SaleOrder o : list) {
+			 //提交(1-是 ,0-否)
+			 String submit = o.getSubmit();
+			 Integer Status = o.getStatus();
+			 String code = o.getBillCode();
+			 String version = o.getVersion();
+
+			 if (Status != null && Status.equals(1)) {
+				 sb.append("单号" + code).append("客户已确认,无法取消提交;");
+				 continue;
+			 }
+			 if (submit == null || submit == "" || submit.equals("0")) {
+				 sb.append("单号" + code).append("已取消提交,请勿再次取消提交;");
+				 continue;
+			 }
+
+			 if (StringUtils.isNotBlank(version) && !version.equals("1")) {
+				 sb.append("单号" + code).append("含有修订记录,无法取消提交;");
+				 continue;
+			 }
+
+			 //关闭(close)1是0否
+			 String getClose = o.getClose();
+
+			 if (StringUtils.isNotBlank(getClose) && !getClose.equals("1")) {
+				 sb.append("单号" + code).append("已关闭,无法执行此操作;");
+				 continue;
+			 }
+		 }
+
+		 if (StringUtils.isNotBlank(sb.toString())) {
+
+			 return Result.error(sb.toString());
+		 }
+
+		 SaleOrder ent = new SaleOrder();
+		 ent.setSubmit("0");
+		 saleOrderService.update(ent, queryWrapper);
+
+		 return Result.OK("取消提交成功!");
+	 }
+
+	 /**
+	  * 批量确认
+	  *
+	  * @param ids
+	  * @return
+	  */
+	 @AutoLog(value = "销售订单-批量确认")
+	 @ApiOperation(value = "销售订单-批量确认", notes = "销售订单-批量确认")
+	 @GetMapping(value = "/submitConfirm")
+	 public Result<String> submitConfirm(@RequestParam(name = "ids", required = true) String ids) {
+
+		 QueryWrapper<SaleOrder> queryWrapper = new QueryWrapper<>();
+		 queryWrapper.in("id", Arrays.asList(ids.split(",")));
+
+		 List<SaleOrder> list = saleOrderService.list(queryWrapper);
+		 if (list.size() == 0) {
+			 return Result.error("数据为空!");
+		 }
+
+		 StringBuffer sb = new StringBuffer();
+		 for (SaleOrder o : list) {
+			 //提交(1-是 ,0-否)
+			 String getSubmit = o.getSubmit();
+			 // 1-已确认,0-未确认
+			 Integer getStatus = o.getStatus();
+			 String code = o.getBillCode();
+
+			 if (getSubmit == null || getSubmit == null || getSubmit.equals(0)) {
+				 sb.append("单据编码" + code).append("还未提交,无法确认;");
+				 continue;
+			 }
+			 if (getStatus != null && getStatus.equals(1)) {
+				 sb.append("单据编码" + code).append("已确认,请勿再次确认;");
+				 continue;
+			 }
+			 //关闭(close)1是0否
+			 String getClose = o.getClose();
+
+			 if (StringUtils.isNotBlank(getClose) && !getClose.equals("1")) {
+				 sb.append("单号" + code).append("已关闭,无法执行此操作;");
+				 continue;
+			 }
+		 }
+
+		 if (StringUtils.isNotBlank(sb.toString())) {
+
+			 return Result.error(sb.toString());
+		 }
+
+		 SaleOrder ent = new SaleOrder();
+		 ent.setStatus(1);
+		 saleOrderService.update(ent, queryWrapper);
+
+		 return Result.OK("确认成功!");
+	 }
+
+	 /**
+	  * 批量取消确认
+	  *
+	  * @param ids
+	  * @return
+	  */
+	 @AutoLog(value = "销售订单-批量取消确认")
+	 @ApiOperation(value = "销售订单-批量取消确认", notes = "销售订单-批量取消确认")
+	 @GetMapping(value = "/returnSubmitConfirm")
+	 public Result<String> returnSubmitConfirm(@RequestParam(name = "ids", required = true) String ids) {
+
+		 QueryWrapper<SaleOrder> queryWrapper = new QueryWrapper<>();
+		 queryWrapper.in("id", Arrays.asList(ids.split(",")));
+
+		 List<SaleOrder> list = saleOrderService.list(queryWrapper);
+		 if (list.size() == 0) {
+			 return Result.error("数据为空!");
+		 }
+
+		 StringBuffer sb = new StringBuffer();
+		 for (SaleOrder o : list) {
+			 //确认(1-是 ,0-否)
+			 Integer submit = o.getStatus();
+			 String code = o.getBillCode();
+			 String version = o.getVersion();
+			 //关闭(close)1是0否
+			 String getClose = o.getClose();
+
+			 if (submit == null || submit.equals(0)) {
+				 sb.append("单号" + code).append("已取消确认,请勿再次取消确认;");
+				 continue;
+			 }
+
+			 if (StringUtils.isNotBlank(getClose) && !getClose.equals("1")) {
+				 sb.append("单号" + code).append("已关闭,无法取消确认;");
+				 continue;
+			 }
+
+			 if (StringUtils.isNotBlank(version) && !version.equals("1")) {
+				 sb.append("单号" + code).append("含有修订记录,无法取消确认;");
+				 continue;
+			 }
+
+		 }
+
+		 if (StringUtils.isNotBlank(sb.toString())) {
+
+			 return Result.error(sb.toString());
+		 }
+
+		 SaleOrder ent = new SaleOrder();
+		 ent.setStatus(0);
+		 saleOrderService.update(ent, queryWrapper);
+
+		 return Result.OK("取消确认成功!");
+	 }
+
+	 /**
+	  * 批量关闭
+	  *
+	  * @param ids
+	  * @return
+	  */
+	 @AutoLog(value = "销售订单-批量关闭")
+	 @ApiOperation(value = "销售订单-批量关闭", notes = "销售订单-批量关闭")
+	 @GetMapping(value = "/submitClose")
+	 public Result<String> submitClose(@RequestParam(name = "ids", required = true) String ids) {
+
+		 QueryWrapper<SaleOrder> queryWrapper = new QueryWrapper<>();
+		 queryWrapper.in("id", Arrays.asList(ids.split(",")));
+
+		 List<SaleOrder> list = saleOrderService.list(queryWrapper);
+		 if (list.size() == 0) {
+			 return Result.error("数据为空!");
+		 }
+
+		 StringBuffer sb = new StringBuffer();
+		 for (SaleOrder o : list) {
+
+			 String code = o.getBillCode();
+
+			 //关闭(close)1是0否
+			 String getClose = o.getClose();
+
+			 if (StringUtils.isNotBlank(getClose) && !getClose.equals("1")) {
+				 sb.append("单号" + code).append("已关闭,无需再次关闭;");
+				 continue;
+			 }
+		 }
+
+		 if (StringUtils.isNotBlank(sb.toString())) {
+
+			 return Result.error(sb.toString());
+		 }
+
+		 SaleOrder ent = new SaleOrder();
+		 ent.setClose("1");
+		 saleOrderService.update(ent, queryWrapper);
+
+		 return Result.OK("关闭成功!");
+	 }
+
+	 /**
+	  * 批量批量关闭
+	  *
+	  * @param ids
+	  * @return
+	  */
+	 @AutoLog(value = "销售订单-取消关闭")
+	 @ApiOperation(value = "销售订单-取消关闭", notes = "销售订单-取消关闭")
+	 @GetMapping(value = "/returnClose")
+	 public Result<String> returnClose(@RequestParam(name = "ids", required = true) String ids) {
+
+		 QueryWrapper<SaleOrder> queryWrapper = new QueryWrapper<>();
+		 queryWrapper.in("id", Arrays.asList(ids.split(",")));
+
+		 List<SaleOrder> list = saleOrderService.list(queryWrapper);
+		 if (list.size() == 0) {
+			 return Result.error("数据为空!");
+		 }
+
+		 StringBuffer sb = new StringBuffer();
+		 for (SaleOrder o : list) {
+
+			 String code = o.getBillCode();
+			 //关闭(close)1是0否
+			 String getClose = o.getClose();
+
+			 if (StringUtils.isBlank(getClose) || !getClose.equals("0")) {
+				 sb.append("单号" + code).append("已取消关闭,无法再次操作;");
+				 continue;
+			 }
+
+		 }
+
+		 if (StringUtils.isNotBlank(sb.toString())) {
+
+			 return Result.error(sb.toString());
+		 }
+
+		 SaleOrder ent = new SaleOrder();
+		 ent.setClose("0");
+		 saleOrderService.update(ent, queryWrapper);
+
+		 return Result.OK("取消关闭成功!");
+	 }
+
+
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "销售订单-通过id查询")
+	@ApiOperation(value="销售订单-通过id查询", notes="销售订单-通过id查询")
+	@GetMapping(value = "/queryById")
+	public Result<SaleOrder> queryById(@RequestParam(name="id",required=true) String id) {
+		SaleOrder saleOrder = saleOrderService.getById(id);
+		if(saleOrder==null) {
+			return Result.error("未找到对应数据");
+		}
+		return Result.OK(saleOrder);
+
+	}
+	
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "销售订单子表 - 船明细通过主表ID查询")
+	@ApiOperation(value="销售订单子表 - 船明细主表ID查询", notes="销售订单子表 - 船明细-通主表ID查询")
+	@GetMapping(value = "/querySaleOrderShipByMainId")
+	public Result<List<SaleOrderShip>> querySaleOrderShipListByMainId(@RequestParam(name="id",required=true) String id) {
+		List<SaleOrderShip> saleOrderShipList = saleOrderShipService.selectByMainId(id);
+		return Result.OK(saleOrderShipList);
+	}
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "销售订单子表 - 产品明细通过主表ID查询")
+	@ApiOperation(value="销售订单子表 - 产品明细主表ID查询", notes="销售订单子表 - 产品明细-通主表ID查询")
+	@GetMapping(value = "/querySaleOrderProductByMainId")
+	public Result<List<SaleOrderProduct>> querySaleOrderProductListByMainId(@RequestParam(name="id",required=true) String id) {
+		List<SaleOrderProduct> saleOrderProductList = saleOrderProductService.selectByMainId(id);
+		return Result.OK(saleOrderProductList);
+	}
+
+    /**
+    * 导出excel
+    *
+    * @param request
+    * @param saleOrder
+    */
+    @RequiresPermissions("saleCode:sale_order:exportXls")
+    @RequestMapping(value = "/exportXls")
+    public ModelAndView exportXls(HttpServletRequest request, SaleOrder saleOrder) {
+      // Step.1 组装查询条件查询数据
+      QueryWrapper<SaleOrder> queryWrapper = QueryGenerator.initQueryWrapper(saleOrder, request.getParameterMap());
+      LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
+
+      //配置选中数据查询条件
+      String selections = request.getParameter("selections");
+      if(oConvertUtils.isNotEmpty(selections)) {
+         List<String> selectionList = Arrays.asList(selections.split(","));
+         queryWrapper.in("id",selectionList);
+      }
+      //Step.2 获取导出数据
+      List<SaleOrder> saleOrderList = saleOrderService.list(queryWrapper);
+
+      // Step.3 组装pageList
+      List<SaleOrderPage> pageList = new ArrayList<SaleOrderPage>();
+      for (SaleOrder main : saleOrderList) {
+          SaleOrderPage vo = new SaleOrderPage();
+          BeanUtils.copyProperties(main, vo);
+          List<SaleOrderShip> saleOrderShipList = saleOrderShipService.selectByMainId(main.getId());
+          vo.setSaleOrderShipList(saleOrderShipList);
+          List<SaleOrderProduct> saleOrderProductList = saleOrderProductService.selectByMainId(main.getId());
+          vo.setSaleOrderProductList(saleOrderProductList);
+          pageList.add(vo);
+      }
+
+      // Step.4 AutoPoi 导出Excel
+      ModelAndView mv = new ModelAndView(new JeecgEntityExcelView());
+      mv.addObject(NormalExcelConstants.FILE_NAME, "销售订单列表");
+      mv.addObject(NormalExcelConstants.CLASS, SaleOrderPage.class);
+      mv.addObject(NormalExcelConstants.PARAMS, new ExportParams("销售订单数据", "导出人:"+sysUser.getRealname(), "销售订单"));
+      mv.addObject(NormalExcelConstants.DATA_LIST, pageList);
+      return mv;
+    }
+
+    /**
+    * 通过excel导入数据
+    *
+    * @param request
+    * @param response
+    * @return
+    */
+    @RequiresPermissions("saleCode:sale_order:importExcel")
+    @RequestMapping(value = "/importExcel", method = RequestMethod.POST)
+    public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
+      MultipartHttpServletRequest multipartRequest = (MultipartHttpServletRequest) request;
+      Map<String, MultipartFile> fileMap = multipartRequest.getFileMap();
+      for (Map.Entry<String, MultipartFile> entity : fileMap.entrySet()) {
+          // 获取上传文件对象
+          MultipartFile file = entity.getValue();
+          ImportParams params = new ImportParams();
+          params.setTitleRows(2);
+          params.setHeadRows(1);
+          params.setNeedSave(true);
+          try {
+              List<SaleOrderPage> list = ExcelImportUtil.importExcel(file.getInputStream(), SaleOrderPage.class, params);
+              for (SaleOrderPage page : list) {
+                  SaleOrder po = new SaleOrder();
+                  BeanUtils.copyProperties(page, po);
+                  saleOrderService.saveMain(po, page.getSaleOrderShipList(),page.getSaleOrderProductList());
+              }
+              return Result.OK("文件导入成功!数据行数:" + list.size());
+          } catch (Exception e) {
+              log.error(e.getMessage(),e);
+              return Result.error("文件导入失败:"+e.getMessage());
+          } finally {
+              try {
+                  file.getInputStream().close();
+              } catch (IOException e) {
+                  e.printStackTrace();
+              }
+          }
+      }
+      return Result.OK("文件导入失败!");
+    }
+
+}

+ 180 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/controller/SaleOrderFilesController.java

@@ -0,0 +1,180 @@
+package org.jeecg.modules.saleCode.controller;
+
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.stream.Collectors;
+import java.io.IOException;
+import java.io.UnsupportedEncodingException;
+import java.net.URLDecoder;
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import org.jeecg.common.api.vo.Result;
+import org.jeecg.common.system.query.QueryGenerator;
+import org.jeecg.common.system.query.QueryRuleEnum;
+import org.jeecg.common.util.oConvertUtils;
+import org.jeecg.modules.saleCode.entity.SaleOrderFiles;
+import org.jeecg.modules.saleCode.service.ISaleOrderFilesService;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import lombok.extern.slf4j.Slf4j;
+
+import org.jeecgframework.poi.excel.ExcelImportUtil;
+import org.jeecgframework.poi.excel.def.NormalExcelConstants;
+import org.jeecgframework.poi.excel.entity.ExportParams;
+import org.jeecgframework.poi.excel.entity.ImportParams;
+import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
+import org.jeecg.common.system.base.controller.JeecgController;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+import org.springframework.web.multipart.MultipartFile;
+import org.springframework.web.multipart.MultipartHttpServletRequest;
+import org.springframework.web.servlet.ModelAndView;
+import com.alibaba.fastjson.JSON;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.jeecg.common.aspect.annotation.AutoLog;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+
+ /**
+ * @Description: 销售订单子表-文件
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Api(tags="销售订单子表-文件")
+@RestController
+@RequestMapping("/saleCode/saleOrderFiles")
+@Slf4j
+public class SaleOrderFilesController extends JeecgController<SaleOrderFiles, ISaleOrderFilesService> {
+	@Autowired
+	private ISaleOrderFilesService saleOrderFilesService;
+	
+	/**
+	 * 分页列表查询
+	 *
+	 * @param saleOrderFiles
+	 * @param pageNo
+	 * @param pageSize
+	 * @param req
+	 * @return
+	 */
+	//@AutoLog(value = "销售订单子表-文件-分页列表查询")
+	@ApiOperation(value="销售订单子表-文件-分页列表查询", notes="销售订单子表-文件-分页列表查询")
+	@GetMapping(value = "/list")
+	public Result<IPage<SaleOrderFiles>> queryPageList(SaleOrderFiles saleOrderFiles,
+								   @RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
+								   @RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
+								   HttpServletRequest req) {
+        QueryWrapper<SaleOrderFiles> queryWrapper = QueryGenerator.initQueryWrapper(saleOrderFiles, req.getParameterMap());
+		Page<SaleOrderFiles> page = new Page<SaleOrderFiles>(pageNo, pageSize);
+		IPage<SaleOrderFiles> pageList = saleOrderFilesService.page(page, queryWrapper);
+		return Result.OK(pageList);
+	}
+	
+	/**
+	 *   添加
+	 *
+	 * @param saleOrderFiles
+	 * @return
+	 */
+	@AutoLog(value = "销售订单子表-文件-添加")
+	@ApiOperation(value="销售订单子表-文件-添加", notes="销售订单子表-文件-添加")
+	@RequiresPermissions("saleCode:sale_order_files:add")
+	@PostMapping(value = "/add")
+	public Result<String> add(@RequestBody SaleOrderFiles saleOrderFiles) {
+		saleOrderFilesService.save(saleOrderFiles);
+		return Result.OK("添加成功!");
+	}
+	
+	/**
+	 *  编辑
+	 *
+	 * @param saleOrderFiles
+	 * @return
+	 */
+	@AutoLog(value = "销售订单子表-文件-编辑")
+	@ApiOperation(value="销售订单子表-文件-编辑", notes="销售订单子表-文件-编辑")
+	@RequiresPermissions("saleCode:sale_order_files:edit")
+	@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
+	public Result<String> edit(@RequestBody SaleOrderFiles saleOrderFiles) {
+		saleOrderFilesService.updateById(saleOrderFiles);
+		return Result.OK("编辑成功!");
+	}
+	
+	/**
+	 *   通过id删除
+	 *
+	 * @param id
+	 * @return
+	 */
+	@AutoLog(value = "销售订单子表-文件-通过id删除")
+	@ApiOperation(value="销售订单子表-文件-通过id删除", notes="销售订单子表-文件-通过id删除")
+	@RequiresPermissions("saleCode:sale_order_files:delete")
+	@DeleteMapping(value = "/delete")
+	public Result<String> delete(@RequestParam(name="id",required=true) String id) {
+		saleOrderFilesService.removeById(id);
+		return Result.OK("删除成功!");
+	}
+	
+	/**
+	 *  批量删除
+	 *
+	 * @param ids
+	 * @return
+	 */
+	@AutoLog(value = "销售订单子表-文件-批量删除")
+	@ApiOperation(value="销售订单子表-文件-批量删除", notes="销售订单子表-文件-批量删除")
+	@RequiresPermissions("saleCode:sale_order_files:deleteBatch")
+	@DeleteMapping(value = "/deleteBatch")
+	public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
+		this.saleOrderFilesService.removeByIds(Arrays.asList(ids.split(",")));
+		return Result.OK("批量删除成功!");
+	}
+	
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "销售订单子表-文件-通过id查询")
+	@ApiOperation(value="销售订单子表-文件-通过id查询", notes="销售订单子表-文件-通过id查询")
+	@GetMapping(value = "/queryById")
+	public Result<SaleOrderFiles> queryById(@RequestParam(name="id",required=true) String id) {
+		SaleOrderFiles saleOrderFiles = saleOrderFilesService.getById(id);
+		if(saleOrderFiles==null) {
+			return Result.error("未找到对应数据");
+		}
+		return Result.OK(saleOrderFiles);
+	}
+
+    /**
+    * 导出excel
+    *
+    * @param request
+    * @param saleOrderFiles
+    */
+    @RequiresPermissions("saleCode:sale_order_files:exportXls")
+    @RequestMapping(value = "/exportXls")
+    public ModelAndView exportXls(HttpServletRequest request, SaleOrderFiles saleOrderFiles) {
+        return super.exportXls(request, saleOrderFiles, SaleOrderFiles.class, "销售订单子表-文件");
+    }
+
+    /**
+      * 通过excel导入数据
+    *
+    * @param request
+    * @param response
+    * @return
+    */
+    @RequiresPermissions("saleCode:sale_order_files:importExcel")
+    @RequestMapping(value = "/importExcel", method = RequestMethod.POST)
+    public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
+        return super.importExcel(request, response, SaleOrderFiles.class);
+    }
+
+}

+ 288 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/controller/SaleOrderHisController.java

@@ -0,0 +1,288 @@
+package org.jeecg.modules.saleCode.controller;
+
+import java.io.UnsupportedEncodingException;
+import java.io.IOException;
+import java.net.URLDecoder;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+import java.util.Map;
+import java.util.stream.Collectors;
+import java.util.HashMap;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+
+import org.jeecgframework.poi.excel.ExcelImportUtil;
+import org.jeecgframework.poi.excel.def.NormalExcelConstants;
+import org.jeecgframework.poi.excel.entity.ExportParams;
+import org.jeecgframework.poi.excel.entity.ImportParams;
+import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
+import org.jeecg.common.system.vo.LoginUser;
+import org.apache.shiro.SecurityUtils;
+import org.jeecg.common.api.vo.Result;
+import org.jeecg.common.system.query.QueryGenerator;
+import org.jeecg.common.system.query.QueryRuleEnum;
+import org.jeecg.common.util.oConvertUtils;
+import org.jeecg.modules.saleCode.entity.SaleOrderShipHis;
+import org.jeecg.modules.saleCode.entity.SaleOrderProductHis;
+import org.jeecg.modules.saleCode.entity.SaleOrderHis;
+import org.jeecg.modules.saleCode.vo.SaleOrderHisPage;
+import org.jeecg.modules.saleCode.service.ISaleOrderHisService;
+import org.jeecg.modules.saleCode.service.ISaleOrderShipHisService;
+import org.jeecg.modules.saleCode.service.ISaleOrderProductHisService;
+import org.springframework.beans.BeanUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+import org.springframework.web.servlet.ModelAndView;
+import org.springframework.web.multipart.MultipartFile;
+import org.springframework.web.multipart.MultipartHttpServletRequest;
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import lombok.extern.slf4j.Slf4j;
+import com.alibaba.fastjson.JSON;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.jeecg.common.aspect.annotation.AutoLog;
+import org.apache.shiro.authz.annotation.RequiresPermissions;
+
+
+ /**
+ * @Description: 销售订单(历史表)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Api(tags="销售订单(历史表)")
+@RestController
+@RequestMapping("/saleCode/saleOrderHis")
+@Slf4j
+public class SaleOrderHisController {
+	@Autowired
+	private ISaleOrderHisService saleOrderHisService;
+	@Autowired
+	private ISaleOrderShipHisService saleOrderShipHisService;
+	@Autowired
+	private ISaleOrderProductHisService saleOrderProductHisService;
+	
+	/**
+	 * 分页列表查询
+	 *
+	 * @param saleOrderHis
+	 * @param pageNo
+	 * @param pageSize
+	 * @param req
+	 * @return
+	 */
+	//@AutoLog(value = "销售订单(历史表)-分页列表查询")
+	@ApiOperation(value="销售订单(历史表)-分页列表查询", notes="销售订单(历史表)-分页列表查询")
+	@GetMapping(value = "/list")
+	public Result<IPage<SaleOrderHis>> queryPageList(SaleOrderHis saleOrderHis,
+								   @RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
+								   @RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
+								   HttpServletRequest req) {
+        QueryWrapper<SaleOrderHis> queryWrapper = QueryGenerator.initQueryWrapper(saleOrderHis, req.getParameterMap());
+		Page<SaleOrderHis> page = new Page<SaleOrderHis>(pageNo, pageSize);
+		IPage<SaleOrderHis> pageList = saleOrderHisService.page(page, queryWrapper);
+		return Result.OK(pageList);
+	}
+	
+	/**
+	 *   添加
+	 *
+	 * @param saleOrderHisPage
+	 * @return
+	 */
+	@AutoLog(value = "销售订单(历史表)-添加")
+	@ApiOperation(value="销售订单(历史表)-添加", notes="销售订单(历史表)-添加")
+    @RequiresPermissions("saleCode:sale_order_his:add")
+	@PostMapping(value = "/add")
+	public Result<String> add(@RequestBody SaleOrderHisPage saleOrderHisPage) {
+		SaleOrderHis saleOrderHis = new SaleOrderHis();
+		BeanUtils.copyProperties(saleOrderHisPage, saleOrderHis);
+		saleOrderHisService.saveMain(saleOrderHis, saleOrderHisPage.getSaleOrderShipHisList(),saleOrderHisPage.getSaleOrderProductHisList());
+		return Result.OK("添加成功!");
+	}
+	
+	/**
+	 *  编辑
+	 *
+	 * @param saleOrderHisPage
+	 * @return
+	 */
+	@AutoLog(value = "销售订单(历史表)-编辑")
+	@ApiOperation(value="销售订单(历史表)-编辑", notes="销售订单(历史表)-编辑")
+    @RequiresPermissions("saleCode:sale_order_his:edit")
+	@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
+	public Result<String> edit(@RequestBody SaleOrderHisPage saleOrderHisPage) {
+		SaleOrderHis saleOrderHis = new SaleOrderHis();
+		BeanUtils.copyProperties(saleOrderHisPage, saleOrderHis);
+		SaleOrderHis saleOrderHisEntity = saleOrderHisService.getById(saleOrderHis.getId());
+		if(saleOrderHisEntity==null) {
+			return Result.error("未找到对应数据");
+		}
+		saleOrderHisService.updateMain(saleOrderHis, saleOrderHisPage.getSaleOrderShipHisList(),saleOrderHisPage.getSaleOrderProductHisList());
+		return Result.OK("编辑成功!");
+	}
+	
+	/**
+	 *   通过id删除
+	 *
+	 * @param id
+	 * @return
+	 */
+	@AutoLog(value = "销售订单(历史表)-通过id删除")
+	@ApiOperation(value="销售订单(历史表)-通过id删除", notes="销售订单(历史表)-通过id删除")
+    @RequiresPermissions("saleCode:sale_order_his:delete")
+	@DeleteMapping(value = "/delete")
+	public Result<String> delete(@RequestParam(name="id",required=true) String id) {
+		saleOrderHisService.delMain(id);
+		return Result.OK("删除成功!");
+	}
+	
+	/**
+	 *  批量删除
+	 *
+	 * @param ids
+	 * @return
+	 */
+	@AutoLog(value = "销售订单(历史表)-批量删除")
+	@ApiOperation(value="销售订单(历史表)-批量删除", notes="销售订单(历史表)-批量删除")
+    @RequiresPermissions("saleCode:sale_order_his:deleteBatch")
+	@DeleteMapping(value = "/deleteBatch")
+	public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
+		this.saleOrderHisService.delBatchMain(Arrays.asList(ids.split(",")));
+		return Result.OK("批量删除成功!");
+	}
+	
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "销售订单(历史表)-通过id查询")
+	@ApiOperation(value="销售订单(历史表)-通过id查询", notes="销售订单(历史表)-通过id查询")
+	@GetMapping(value = "/queryById")
+	public Result<SaleOrderHis> queryById(@RequestParam(name="id",required=true) String id) {
+		SaleOrderHis saleOrderHis = saleOrderHisService.getById(id);
+		if(saleOrderHis==null) {
+			return Result.error("未找到对应数据");
+		}
+		return Result.OK(saleOrderHis);
+
+	}
+	
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "销售订单子表 - 船明细(历史表)通过主表ID查询")
+	@ApiOperation(value="销售订单子表 - 船明细(历史表)主表ID查询", notes="销售订单子表 - 船明细(历史表)-通主表ID查询")
+	@GetMapping(value = "/querySaleOrderShipHisByMainId")
+	public Result<List<SaleOrderShipHis>> querySaleOrderShipHisListByMainId(@RequestParam(name="id",required=true) String id) {
+		List<SaleOrderShipHis> saleOrderShipHisList = saleOrderShipHisService.selectByMainId(id);
+		return Result.OK(saleOrderShipHisList);
+	}
+	/**
+	 * 通过id查询
+	 *
+	 * @param id
+	 * @return
+	 */
+	//@AutoLog(value = "销售订单子表 - 产品明细(历史表)通过主表ID查询")
+	@ApiOperation(value="销售订单子表 - 产品明细(历史表)主表ID查询", notes="销售订单子表 - 产品明细(历史表)-通主表ID查询")
+	@GetMapping(value = "/querySaleOrderProductHisByMainId")
+	public Result<List<SaleOrderProductHis>> querySaleOrderProductHisListByMainId(@RequestParam(name="id",required=true) String id) {
+		List<SaleOrderProductHis> saleOrderProductHisList = saleOrderProductHisService.selectByMainId(id);
+		return Result.OK(saleOrderProductHisList);
+	}
+
+    /**
+    * 导出excel
+    *
+    * @param request
+    * @param saleOrderHis
+    */
+    @RequiresPermissions("saleCode:sale_order_his:exportXls")
+    @RequestMapping(value = "/exportXls")
+    public ModelAndView exportXls(HttpServletRequest request, SaleOrderHis saleOrderHis) {
+      // Step.1 组装查询条件查询数据
+      QueryWrapper<SaleOrderHis> queryWrapper = QueryGenerator.initQueryWrapper(saleOrderHis, request.getParameterMap());
+      LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
+
+      //配置选中数据查询条件
+      String selections = request.getParameter("selections");
+      if(oConvertUtils.isNotEmpty(selections)) {
+         List<String> selectionList = Arrays.asList(selections.split(","));
+         queryWrapper.in("id",selectionList);
+      }
+      //Step.2 获取导出数据
+      List<SaleOrderHis> saleOrderHisList = saleOrderHisService.list(queryWrapper);
+
+      // Step.3 组装pageList
+      List<SaleOrderHisPage> pageList = new ArrayList<SaleOrderHisPage>();
+      for (SaleOrderHis main : saleOrderHisList) {
+          SaleOrderHisPage vo = new SaleOrderHisPage();
+          BeanUtils.copyProperties(main, vo);
+          List<SaleOrderShipHis> saleOrderShipHisList = saleOrderShipHisService.selectByMainId(main.getId());
+          vo.setSaleOrderShipHisList(saleOrderShipHisList);
+          List<SaleOrderProductHis> saleOrderProductHisList = saleOrderProductHisService.selectByMainId(main.getId());
+          vo.setSaleOrderProductHisList(saleOrderProductHisList);
+          pageList.add(vo);
+      }
+
+      // Step.4 AutoPoi 导出Excel
+      ModelAndView mv = new ModelAndView(new JeecgEntityExcelView());
+      mv.addObject(NormalExcelConstants.FILE_NAME, "销售订单(历史表)列表");
+      mv.addObject(NormalExcelConstants.CLASS, SaleOrderHisPage.class);
+      mv.addObject(NormalExcelConstants.PARAMS, new ExportParams("销售订单(历史表)数据", "导出人:"+sysUser.getRealname(), "销售订单(历史表)"));
+      mv.addObject(NormalExcelConstants.DATA_LIST, pageList);
+      return mv;
+    }
+
+    /**
+    * 通过excel导入数据
+    *
+    * @param request
+    * @param response
+    * @return
+    */
+    @RequiresPermissions("saleCode:sale_order_his:importExcel")
+    @RequestMapping(value = "/importExcel", method = RequestMethod.POST)
+    public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
+      MultipartHttpServletRequest multipartRequest = (MultipartHttpServletRequest) request;
+      Map<String, MultipartFile> fileMap = multipartRequest.getFileMap();
+      for (Map.Entry<String, MultipartFile> entity : fileMap.entrySet()) {
+          // 获取上传文件对象
+          MultipartFile file = entity.getValue();
+          ImportParams params = new ImportParams();
+          params.setTitleRows(2);
+          params.setHeadRows(1);
+          params.setNeedSave(true);
+          try {
+              List<SaleOrderHisPage> list = ExcelImportUtil.importExcel(file.getInputStream(), SaleOrderHisPage.class, params);
+              for (SaleOrderHisPage page : list) {
+                  SaleOrderHis po = new SaleOrderHis();
+                  BeanUtils.copyProperties(page, po);
+                  saleOrderHisService.saveMain(po, page.getSaleOrderShipHisList(),page.getSaleOrderProductHisList());
+              }
+              return Result.OK("文件导入成功!数据行数:" + list.size());
+          } catch (Exception e) {
+              log.error(e.getMessage(),e);
+              return Result.error("文件导入失败:"+e.getMessage());
+          } finally {
+              try {
+                  file.getInputStream().close();
+              } catch (IOException e) {
+                  e.printStackTrace();
+              }
+          }
+      }
+      return Result.OK("文件导入失败!");
+    }
+
+}

+ 22 - 1
srm-module-code/src/main/java/org/jeecg/modules/saleCode/controller/SaleQuotationController.java

@@ -13,6 +13,7 @@ import org.apache.commons.lang.StringUtils;
 import org.jeecg.modules.baseCode.service.ISerialPatternService;
 import org.jeecg.modules.saleCode.entity.*;
 import org.jeecg.modules.saleCode.service.*;
+import org.jeecg.modules.saleCode.vo.SaleQuotationAlert;
 import org.jeecgframework.poi.excel.ExcelImportUtil;
 import org.jeecgframework.poi.excel.def.NormalExcelConstants;
 import org.jeecgframework.poi.excel.entity.ExportParams;
@@ -84,6 +85,26 @@ public class SaleQuotationController {
         return Result.OK(pageList);
     }
 
+    /**
+     * 销售报价单弹框明细
+     * @param saleInquiryForm
+     * @param pageNo
+     * @param pageSize
+     * @param req
+     * @return
+     */
+    @ApiOperation(value = "销售报价单弹框明细", notes = "销售报价单弹框明细")
+    @GetMapping(value = "/saleQuotationDetailsAlert")
+    public Result<IPage<SaleQuotationAlert>> saleQuotationDetailsAlert(SaleQuotationAlert saleInquiryForm,
+                                                                 @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
+                                                                 @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
+                                                                 HttpServletRequest req) {
+
+        QueryWrapper<SaleQuotationAlert> queryWrapper = QueryGenerator.initQueryWrapper(saleInquiryForm, req.getParameterMap());
+        Page<SaleQuotationAlert> page = new Page<SaleQuotationAlert>(pageNo,pageSize);
+        IPage<SaleQuotationAlert> pageList = saleQuotationProductService.saleQuotationDetailsAlert(page, queryWrapper);
+        return Result.OK(pageList);
+    }
     /**
      * 添加
      *
@@ -184,7 +205,7 @@ public class SaleQuotationController {
         }
 
         List<SaleQuotationProductHis> saleQuotationProductList = new ArrayList<>();
-        if(saleQuotationPage.getSaleQuotationShipList().size() > 0){
+        if(saleQuotationPage.getSaleQuotationProductList().size() > 0){
 
             for (SaleQuotationProduct o : saleQuotationPage.getSaleQuotationProductList()) {
                 SaleQuotationProductHis his = new SaleQuotationProductHis();

+ 1 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleContract.java

@@ -92,6 +92,7 @@ public class SaleContract implements Serializable {
 	/**优先级(priority)*/
 	@Excel(name = "优先级(priority)", width = 15)
     @ApiModelProperty(value = "优先级(priority)")
+    @Dict(dicCode = "priority")
     private String priority;
 	/**产品分类(production class)*/
 	@Excel(name = "产品分类(production class)", width = 15)

+ 4 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleInquiryForm.java

@@ -116,10 +116,12 @@ public class SaleInquiryForm implements Serializable {
 	/**优先级(priority)*/
 	@Excel(name = "优先级(priority)", width = 15)
     @ApiModelProperty(value = "优先级(priority)")
+    @Dict(dicCode = "priority")
     private String priority;
 	/**产品分类(production class)*/
 	@Excel(name = "产品分类(production class)", width = 15)
     @ApiModelProperty(value = "产品分类(production class)")
+    @Dict(dictTable = "base_product_class", dicCode = "id", dicText = "name")
     private String productionClass;
 	/**机型(model)*/
 	@Excel(name = "机型(model)", width = 15)
@@ -140,7 +142,9 @@ public class SaleInquiryForm implements Serializable {
 	/**采购询价组(procurement inquiry team)*/
 	@Excel(name = "采购询价组(procurement inquiry team)", width = 15)
     @ApiModelProperty(value = "采购询价组(procurement inquiry team)")
+    @Dict(dictTable = "sys_depart", dicCode = "id", dicText = "depart_name")
     private String inquiryTeam;
+    private String inquiryTeamName;
 	/**交期(delivery time)*/
 	@Excel(name = "交期(delivery time)", width = 20, format = "yyyy-MM-dd")
 	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")

+ 229 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrder.java

@@ -0,0 +1,229 @@
+package org.jeecg.modules.saleCode.entity;
+
+import java.io.Serializable;
+import java.io.UnsupportedEncodingException;
+import java.util.Date;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import org.jeecg.common.aspect.annotation.Dict;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+
+/**
+ * @Description: 销售订单
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@ApiModel(value="sale_order对象", description="销售订单")
+@Data
+@TableName("sale_order")
+public class SaleOrder implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**客户确认(1-已确认,0-未确认)*/
+	@Excel(name = "客户确认(1-已确认,0-未确认)", width = 15)
+    @ApiModelProperty(value = "客户确认(1-已确认,0-未确认)")
+    private Integer status;
+	/**提交(submit)1是0否*/
+	@Excel(name = "提交(submit)1是0否", width = 15)
+    @ApiModelProperty(value = "提交(submit)1是0否")
+    private String submit;
+	/**关闭(close)1是0否*/
+	@Excel(name = "关闭(close)1是0否", width = 15)
+    @ApiModelProperty(value = "关闭(close)1是0否")
+    private String close;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+    @ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+	/**单据日期*/
+	@Excel(name = "单据日期", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "单据日期")
+    private Date billDate;
+	/**单据编码*/
+	@Excel(name = "单据编码", width = 15)
+    @ApiModelProperty(value = "单据编码")
+    private String billCode;
+	/**项目(project)*/
+	@Excel(name = "项目(project)", width = 15)
+    @ApiModelProperty(value = "项目(project)")
+    private String project;
+	/**项目名称*/
+	@Excel(name = "项目名称", width = 15)
+    @ApiModelProperty(value = "项目名称")
+    private String projectName;
+	/**客户(customer)*/
+	@Excel(name = "客户(customer)", width = 15)
+    @ApiModelProperty(value = "客户(customer)")
+    private String customer;
+	/**客户名称*/
+	@Excel(name = "客户名称", width = 15)
+    @ApiModelProperty(value = "客户名称")
+    private String customerName;
+	/**业务类型(busyness type)*/
+	@Excel(name = "业务类型(busyness type)", width = 15)
+    @ApiModelProperty(value = "业务类型(busyness type)")
+    private String busynessType;
+	/**中间人(intermediator)*/
+	@Excel(name = "中间人(intermediator)", width = 15)
+    @ApiModelProperty(value = "中间人(intermediator)")
+    private String intermediator;
+	/**中间人名称*/
+	@Excel(name = "中间人名称", width = 15)
+    @ApiModelProperty(value = "中间人名称")
+    private String intermediatorName;
+	/**优先级(priority)*/
+	@Excel(name = "优先级(priority)", width = 15)
+    @ApiModelProperty(value = "优先级(priority)")
+    private String priority;
+	/**产品分类(production class)*/
+	@Excel(name = "产品分类(production class)", width = 15)
+    @ApiModelProperty(value = "产品分类(production class)")
+    private String productionClass;
+	/**机型(model)*/
+	@Excel(name = "机型(model)", width = 15)
+    @ApiModelProperty(value = "机型(model)")
+    private String model;
+	/**厂家(maker)*/
+	@Excel(name = "厂家(maker)", width = 15)
+    @ApiModelProperty(value = "厂家(maker)")
+    private String maker;
+	/**币种(currency)*/
+	@Excel(name = "币种(currency)", width = 15)
+    @ApiModelProperty(value = "币种(currency)")
+    private String currency;
+	/**汇率(exchange rate)*/
+	@Excel(name = "汇率(exchange rate)", width = 15)
+    @ApiModelProperty(value = "汇率(exchange rate)")
+    private java.math.BigDecimal exchangeRate;
+	/**交货条款(delivery terms)*/
+	@Excel(name = "交货条款(delivery terms)", width = 15)
+    @ApiModelProperty(value = "交货条款(delivery terms)")
+    private String deliveryTerms;
+	/**付款条件(payment terms)*/
+	@Excel(name = "付款条件(payment terms)", width = 15)
+    @ApiModelProperty(value = "付款条件(payment terms)")
+    private String paymentTerms;
+	/**交期(delivery time)*/
+	@Excel(name = "交期(delivery time)", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "交期(delivery time)")
+    private Date deliveryTime;
+	/**发货方式(delivery)*/
+	@Excel(name = "发货方式(delivery)", width = 15)
+    @ApiModelProperty(value = "发货方式(delivery)")
+    private String delivery;
+	/**交货地点(delivery address)*/
+	@Excel(name = "交货地点(delivery address)", width = 15)
+    @ApiModelProperty(value = "交货地点(delivery address)")
+    private String deliveryAddress;
+	/**开票抬头(Invoice header)*/
+	@Excel(name = "开票抬头(Invoice header)", width = 15)
+    @ApiModelProperty(value = "开票抬头(Invoice header)")
+    private String invoiceHeader;
+	/**质保期(warranty period)*/
+	@Excel(name = "质保期(warranty period)", width = 15)
+    @ApiModelProperty(value = "质保期(warranty period)")
+    private String warrantyPeriod;
+	/**是否出口(export) 1是0否*/
+	@Excel(name = "是否出口(export) 1是0否", width = 15)
+    @ApiModelProperty(value = "是否出口(export) 1是0否")
+    private String isExport;
+	/**包装要求(packageb requirement)*/
+	@Excel(name = "包装要求(packageb requirement)", width = 15)
+    @ApiModelProperty(value = "包装要求(packageb requirement)")
+    private String packagebRequirement;
+	/**销售部门(sale department)*/
+	@Excel(name = "销售部门(sale department)", width = 15)
+    @ApiModelProperty(value = "销售部门(sale department)")
+    private String saleDepartment;
+	/**业务员(salesman)*/
+	@Excel(name = "业务员(salesman)", width = 15)
+    @ApiModelProperty(value = "业务员(salesman)")
+    private String salesman;
+	/**销售部门(sale department)名称*/
+	@Excel(name = "销售部门(sale department)名称", width = 15)
+    @ApiModelProperty(value = "销售部门(sale department)名称")
+    private String saleDepartmentName;
+	/**业务员(salesman)名称*/
+	@Excel(name = "业务员(salesman)名称", width = 15)
+    @ApiModelProperty(value = "业务员(salesman)名称")
+    private String salesmanName;
+	/**附件(attachs)*/
+	@Excel(name = "附件(attachs)", width = 15)
+    @ApiModelProperty(value = "附件(attachs)")
+    private String attachs;
+	/**备注(notes)*/
+	@Excel(name = "备注(notes)", width = 15)
+    @ApiModelProperty(value = "备注(notes)")
+    private String notes;
+	/**客户订单号(customer order number)*/
+	@Excel(name = "客户订单号(customer order number)", width = 15)
+    @ApiModelProperty(value = "客户订单号(customer order number)")
+    private String customerOrder;
+	/**折上折(double discount)*/
+	@Excel(name = "折上折(double discount)", width = 15)
+    @ApiModelProperty(value = "折上折(double discount)")
+    private java.math.BigDecimal doubleDiscount;
+	/**折后金额(converted amount)*/
+	@Excel(name = "折后金额(converted amount)", width = 15)
+    @ApiModelProperty(value = "折后金额(converted amount)")
+    private String convertedAmount;
+	/**质保条款(warranty terms)*/
+	@Excel(name = "质保条款(warranty terms)", width = 15)
+    @ApiModelProperty(value = "质保条款(warranty terms)")
+    private String warrantyTerms;
+	/**预付比例(advance ratio)*/
+	@Excel(name = "预付比例(advance ratio)", width = 15)
+    @ApiModelProperty(value = "预付比例(advance ratio)")
+    private String advanceRatio;
+	/**版本号*/
+	@Excel(name = "版本号", width = 15)
+    @ApiModelProperty(value = "版本号")
+    private String version;
+    private String sourceCode;
+    private String sourceCode2;
+
+
+//	/订单金额(order money)
+    private java.math.BigDecimal orderMoney;
+//    发货金额(delivery money)
+    private java.math.BigDecimal deliveryMoney;
+//    发票金额(invoice money)
+    private java.math.BigDecimal invoiceMoney;
+//    收款金额(collected money)
+    private java.math.BigDecimal collectedMoney;
+}

+ 83 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrderFiles.java

@@ -0,0 +1,83 @@
+package org.jeecg.modules.saleCode.entity;
+
+import java.io.Serializable;
+import java.io.UnsupportedEncodingException;
+import java.util.Date;
+import java.math.BigDecimal;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import org.jeecg.common.aspect.annotation.Dict;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.EqualsAndHashCode;
+import lombok.experimental.Accessors;
+
+/**
+ * @Description: 销售订单子表-文件
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@Data
+@TableName("sale_order_files")
+@Accessors(chain = true)
+@EqualsAndHashCode(callSuper = false)
+@ApiModel(value="sale_order_files对象", description="销售订单子表-文件")
+public class SaleOrderFiles implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**状态(1-启用,0-停用)*/
+	@Excel(name = "状态(1-启用,0-停用)", width = 15)
+    @ApiModelProperty(value = "状态(1-启用,0-停用)")
+    private Integer status;
+	/**附件(attachs)*/
+	@Excel(name = "附件(attachs)", width = 15)
+    @ApiModelProperty(value = "附件(attachs)")
+    private String attachs;
+	/**附件名称*/
+	@Excel(name = "附件名称", width = 15)
+    @ApiModelProperty(value = "附件名称")
+    private String name;
+	/**
+1扫描合同 2基础协议*/
+	@Excel(name = "1扫描合同 2基础协议", width = 15)
+    @ApiModelProperty(value = "1扫描合同 2基础协议")
+    private java.lang.String type;
+	/**销售订单主表主键*/
+	@Excel(name = "销售订单主表主键", width = 15)
+    @ApiModelProperty(value = "销售订单主表主键")
+    private java.lang.String headId;
+	/**删除标记*/
+	@Excel(name = "删除标记", width = 15)
+    @ApiModelProperty(value = "删除标记")
+    @TableLogic
+    private java.lang.Integer delFlag;
+}

+ 231 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrderHis.java

@@ -0,0 +1,231 @@
+package org.jeecg.modules.saleCode.entity;
+
+import java.io.Serializable;
+import java.io.UnsupportedEncodingException;
+import java.util.Date;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import org.jeecg.common.aspect.annotation.Dict;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+
+/**
+ * @Description: 销售订单(历史表)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@ApiModel(value="sale_order_his对象", description="销售订单(历史表)")
+@Data
+@TableName("sale_order_his")
+public class SaleOrderHis implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**历史主键*/
+	@Excel(name = "历史主键", width = 15)
+    @ApiModelProperty(value = "历史主键")
+    private String hisId;
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**客户确认(1-已确认,0-未确认)*/
+	@Excel(name = "客户确认(1-已确认,0-未确认)", width = 15)
+    @ApiModelProperty(value = "客户确认(1-已确认,0-未确认)")
+    private Integer status;
+	/**提交(submit)1是0否*/
+	@Excel(name = "提交(submit)1是0否", width = 15)
+    @ApiModelProperty(value = "提交(submit)1是0否")
+    private String submit;
+	/**关闭(close)1是0否*/
+	@Excel(name = "关闭(close)1是0否", width = 15)
+    @ApiModelProperty(value = "关闭(close)1是0否")
+    private String close;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+    @ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+	/**单据日期*/
+	@Excel(name = "单据日期", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "单据日期")
+    private Date billDate;
+	/**单据编码*/
+	@Excel(name = "单据编码", width = 15)
+    @ApiModelProperty(value = "单据编码")
+    private String billCode;
+	/**项目(project)*/
+	@Excel(name = "项目(project)", width = 15)
+    @ApiModelProperty(value = "项目(project)")
+    private String project;
+	/**项目名称*/
+	@Excel(name = "项目名称", width = 15)
+    @ApiModelProperty(value = "项目名称")
+    private String projectName;
+	/**客户(customer)*/
+	@Excel(name = "客户(customer)", width = 15)
+    @ApiModelProperty(value = "客户(customer)")
+    private String customer;
+	/**客户名称*/
+	@Excel(name = "客户名称", width = 15)
+    @ApiModelProperty(value = "客户名称")
+    private String customerName;
+	/**业务类型(busyness type)*/
+	@Excel(name = "业务类型(busyness type)", width = 15)
+    @ApiModelProperty(value = "业务类型(busyness type)")
+    private String busynessType;
+	/**中间人(intermediator)*/
+	@Excel(name = "中间人(intermediator)", width = 15)
+    @ApiModelProperty(value = "中间人(intermediator)")
+    private String intermediator;
+	/**中间人名称*/
+	@Excel(name = "中间人名称", width = 15)
+    @ApiModelProperty(value = "中间人名称")
+    private String intermediatorName;
+	/**优先级(priority)*/
+	@Excel(name = "优先级(priority)", width = 15)
+    @ApiModelProperty(value = "优先级(priority)")
+    private String priority;
+	/**产品分类(production class)*/
+	@Excel(name = "产品分类(production class)", width = 15)
+    @ApiModelProperty(value = "产品分类(production class)")
+    private String productionClass;
+	/**机型(model)*/
+	@Excel(name = "机型(model)", width = 15)
+    @ApiModelProperty(value = "机型(model)")
+    private String model;
+	/**厂家(maker)*/
+	@Excel(name = "厂家(maker)", width = 15)
+    @ApiModelProperty(value = "厂家(maker)")
+    private String maker;
+	/**币种(currency)*/
+	@Excel(name = "币种(currency)", width = 15)
+    @ApiModelProperty(value = "币种(currency)")
+    private String currency;
+	/**汇率(exchange rate)*/
+	@Excel(name = "汇率(exchange rate)", width = 15)
+    @ApiModelProperty(value = "汇率(exchange rate)")
+    private java.math.BigDecimal exchangeRate;
+	/**交货条款(delivery terms)*/
+	@Excel(name = "交货条款(delivery terms)", width = 15)
+    @ApiModelProperty(value = "交货条款(delivery terms)")
+    private String deliveryTerms;
+	/**付款条件(payment terms)*/
+	@Excel(name = "付款条件(payment terms)", width = 15)
+    @ApiModelProperty(value = "付款条件(payment terms)")
+    private String paymentTerms;
+	/**交期(delivery time)*/
+	@Excel(name = "交期(delivery time)", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "交期(delivery time)")
+    private Date deliveryTime;
+	/**发货方式(delivery)*/
+	@Excel(name = "发货方式(delivery)", width = 15)
+    @ApiModelProperty(value = "发货方式(delivery)")
+    private String delivery;
+	/**交货地点(delivery address)*/
+	@Excel(name = "交货地点(delivery address)", width = 15)
+    @ApiModelProperty(value = "交货地点(delivery address)")
+    private String deliveryAddress;
+	/**开票抬头(Invoice header)*/
+	@Excel(name = "开票抬头(Invoice header)", width = 15)
+    @ApiModelProperty(value = "开票抬头(Invoice header)")
+    private String invoiceHeader;
+	/**质保期(warranty period)*/
+	@Excel(name = "质保期(warranty period)", width = 15)
+    @ApiModelProperty(value = "质保期(warranty period)")
+    private String warrantyPeriod;
+	/**是否出口(export) 1是0否*/
+	@Excel(name = "是否出口(export) 1是0否", width = 15)
+    @ApiModelProperty(value = "是否出口(export) 1是0否")
+    private String isExport;
+	/**包装要求(packageb requirement)*/
+	@Excel(name = "包装要求(packageb requirement)", width = 15)
+    @ApiModelProperty(value = "包装要求(packageb requirement)")
+    private String packagebRequirement;
+	/**销售部门(sale department)*/
+	@Excel(name = "销售部门(sale department)", width = 15)
+    @ApiModelProperty(value = "销售部门(sale department)")
+    private String saleDepartment;
+	/**业务员(salesman)*/
+	@Excel(name = "业务员(salesman)", width = 15)
+    @ApiModelProperty(value = "业务员(salesman)")
+    private String salesman;
+	/**销售部门(sale department)名称*/
+	@Excel(name = "销售部门(sale department)名称", width = 15)
+    @ApiModelProperty(value = "销售部门(sale department)名称")
+    private String saleDepartmentName;
+	/**业务员(salesman)名称*/
+	@Excel(name = "业务员(salesman)名称", width = 15)
+    @ApiModelProperty(value = "业务员(salesman)名称")
+    private String salesmanName;
+	/**附件(attachs)*/
+	@Excel(name = "附件(attachs)", width = 15)
+    @ApiModelProperty(value = "附件(attachs)")
+    private String attachs;
+	/**备注(notes)*/
+	@Excel(name = "备注(notes)", width = 15)
+    @ApiModelProperty(value = "备注(notes)")
+    private String notes;
+	/**客户订单号(customer order number)*/
+	@Excel(name = "客户订单号(customer order number)", width = 15)
+    @ApiModelProperty(value = "客户订单号(customer order number)")
+    private String customerOrder;
+	/**折上折(double discount)*/
+	@Excel(name = "折上折(double discount)", width = 15)
+    @ApiModelProperty(value = "折上折(double discount)")
+    private java.math.BigDecimal doubleDiscount;
+	/**折后金额(converted amount)*/
+	@Excel(name = "折后金额(converted amount)", width = 15)
+    @ApiModelProperty(value = "折后金额(converted amount)")
+    private String convertedAmount;
+	/**质保条款(warranty terms)*/
+	@Excel(name = "质保条款(warranty terms)", width = 15)
+    @ApiModelProperty(value = "质保条款(warranty terms)")
+    private String warrantyTerms;
+	/**预付比例(advance ratio)*/
+	@Excel(name = "预付比例(advance ratio)", width = 15)
+    @ApiModelProperty(value = "预付比例(advance ratio)")
+    private String advanceRatio;
+	/**版本号*/
+	@Excel(name = "版本号", width = 15)
+    @ApiModelProperty(value = "版本号")
+    private String version;
+    private String sourceCode;
+    private String sourceCode2;
+    //	/订单金额(order money)
+    private java.math.BigDecimal orderMoney;
+    //    发货金额(delivery money)
+    private java.math.BigDecimal deliveryMoney;
+    //    发票金额(invoice money)
+    private java.math.BigDecimal invoiceMoney;
+    //    收款金额(collected money)
+    private java.math.BigDecimal collectedMoney;
+}

+ 154 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrderProduct.java

@@ -0,0 +1,154 @@
+package org.jeecg.modules.saleCode.entity;
+
+import java.io.Serializable;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import java.util.Date;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import java.io.UnsupportedEncodingException;
+
+/**
+ * @Description: 销售订单子表 - 产品明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@ApiModel(value="sale_order_product对象", description="销售订单子表 - 产品明细")
+@Data
+@TableName("sale_order_product")
+public class SaleOrderProduct implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**状态(1-启用,0-停用)*/
+	@Excel(name = "状态(1-启用,0-停用)", width = 15)
+    @ApiModelProperty(value = "状态(1-启用,0-停用)")
+    private Integer status;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+    @ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+	/**表头主键(销售订单)*/
+    @ApiModelProperty(value = "表头主键(销售订单)")
+    private String headId;
+	/**交期*/
+	@Excel(name = "交期", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "交期")
+    private Date deliveryTime;
+	/**产品id*/
+	@Excel(name = "产品id", width = 15)
+    @ApiModelProperty(value = "产品id")
+    private String productId;
+	/**产品分类*/
+	@Excel(name = "产品分类", width = 15)
+    @ApiModelProperty(value = "产品分类")
+    private String productClass;
+	/**产品编码*/
+	@Excel(name = "产品编码", width = 15)
+    @ApiModelProperty(value = "产品编码")
+    private String productCode;
+	/**产品中文名*/
+	@Excel(name = "产品中文名", width = 15)
+    @ApiModelProperty(value = "产品中文名")
+    private String chineseName;
+	/**产品英文名*/
+	@Excel(name = "产品英文名", width = 15)
+    @ApiModelProperty(value = "产品英文名")
+    private String englishName;
+	/**规格*/
+	@Excel(name = "规格", width = 15)
+    @ApiModelProperty(value = "规格")
+    private String specifications;
+	/**型号*/
+	@Excel(name = "型号", width = 15)
+    @ApiModelProperty(value = "型号")
+    private String model;
+	/**备件号*/
+	@Excel(name = "备件号", width = 15)
+    @ApiModelProperty(value = "备件号")
+    private String partno;
+	/**图号*/
+	@Excel(name = "图号", width = 15)
+    @ApiModelProperty(value = "图号")
+    private String drawingno;
+	/**订货号*/
+	@Excel(name = "订货号", width = 15)
+    @ApiModelProperty(value = "订货号")
+    private String orderno;
+	/**厂家*/
+	@Excel(name = "厂家", width = 15)
+    @ApiModelProperty(value = "厂家")
+    private String factory;
+	/**质量等级*/
+	@Excel(name = "质量等级", width = 15)
+    @ApiModelProperty(value = "质量等级")
+    private String qualityGrade;
+	/**数量*/
+	@Excel(name = "数量", width = 15)
+    @ApiModelProperty(value = "数量")
+    private Double quantity;
+	/**税率(tax rate)*/
+	@Excel(name = "税率(tax rate)", width = 15)
+    @ApiModelProperty(value = "税率(tax rate)")
+    private java.math.BigDecimal taxRate;
+	/**折扣(discount)*/
+	@Excel(name = "折扣(discount)", width = 15)
+    @ApiModelProperty(value = "折扣(discount)")
+    private java.math.BigDecimal discount;
+	/**含税单价(tax price)*/
+	@Excel(name = "含税单价(tax price)", width = 15)
+    @ApiModelProperty(value = "含税单价(tax price)")
+    private java.math.BigDecimal taxPrice;
+	/**含税金额(tax amount)*/
+	@Excel(name = "含税金额(tax amount)", width = 15)
+    @ApiModelProperty(value = "含税金额(tax amount)")
+    private java.math.BigDecimal taxAmount;
+	/**折后单价(discounted unit price)*/
+	@Excel(name = "折后单价(discounted unit price)", width = 15)
+    @ApiModelProperty(value = "折后单价(discounted unit price)")
+    private java.math.BigDecimal discountedPrice;
+	/**折后金额(converted amount)*/
+	@Excel(name = "折后金额(converted amount)", width = 15)
+    @ApiModelProperty(value = "折后金额(converted amount)")
+    private java.math.BigDecimal discountedAmount;
+	/**备注(notes)*/
+	@Excel(name = "备注(notes)", width = 15)
+    @ApiModelProperty(value = "备注(notes)")
+    private String notes;
+	/**参照来源*/
+	@Excel(name = "参照来源", width = 15)
+    @ApiModelProperty(value = "参照来源")
+    private String sourceId;
+    private String sourceType;
+}

+ 162 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrderProductHis.java

@@ -0,0 +1,162 @@
+package org.jeecg.modules.saleCode.entity;
+
+import java.io.Serializable;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import java.util.Date;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import java.io.UnsupportedEncodingException;
+
+/**
+ * @Description: 销售订单子表 - 产品明细(历史表)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@ApiModel(value="sale_order_product_his对象", description="销售订单子表 - 产品明细(历史表)")
+@Data
+@TableName("sale_order_product_his")
+public class SaleOrderProductHis implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**状态(1-启用,0-停用)*/
+	@Excel(name = "状态(1-启用,0-停用)", width = 15)
+    @ApiModelProperty(value = "状态(1-启用,0-停用)")
+    private Integer status;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+    @ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+	/**表头主键(销售订单)*/
+    @ApiModelProperty(value = "表头主键(销售订单)")
+    private String headId;
+	/**交期*/
+	@Excel(name = "交期", width = 15, format = "yyyy-MM-dd")
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
+    @DateTimeFormat(pattern="yyyy-MM-dd")
+    @ApiModelProperty(value = "交期")
+    private Date deliveryTime;
+	/**产品id*/
+	@Excel(name = "产品id", width = 15)
+    @ApiModelProperty(value = "产品id")
+    private String productId;
+	/**产品分类*/
+	@Excel(name = "产品分类", width = 15)
+    @ApiModelProperty(value = "产品分类")
+    private String productClass;
+	/**产品编码*/
+	@Excel(name = "产品编码", width = 15)
+    @ApiModelProperty(value = "产品编码")
+    private String productCode;
+	/**产品中文名*/
+	@Excel(name = "产品中文名", width = 15)
+    @ApiModelProperty(value = "产品中文名")
+    private String chineseName;
+	/**产品英文名*/
+	@Excel(name = "产品英文名", width = 15)
+    @ApiModelProperty(value = "产品英文名")
+    private String englishName;
+	/**规格*/
+	@Excel(name = "规格", width = 15)
+    @ApiModelProperty(value = "规格")
+    private String specifications;
+	/**型号*/
+	@Excel(name = "型号", width = 15)
+    @ApiModelProperty(value = "型号")
+    private String model;
+	/**备件号*/
+	@Excel(name = "备件号", width = 15)
+    @ApiModelProperty(value = "备件号")
+    private String partno;
+	/**图号*/
+	@Excel(name = "图号", width = 15)
+    @ApiModelProperty(value = "图号")
+    private String drawingno;
+	/**订货号*/
+	@Excel(name = "订货号", width = 15)
+    @ApiModelProperty(value = "订货号")
+    private String orderno;
+	/**厂家*/
+	@Excel(name = "厂家", width = 15)
+    @ApiModelProperty(value = "厂家")
+    private String factory;
+	/**质量等级*/
+	@Excel(name = "质量等级", width = 15)
+    @ApiModelProperty(value = "质量等级")
+    private String qualityGrade;
+	/**数量*/
+	@Excel(name = "数量", width = 15)
+    @ApiModelProperty(value = "数量")
+    private Double quantity;
+	/**税率(tax rate)*/
+	@Excel(name = "税率(tax rate)", width = 15)
+    @ApiModelProperty(value = "税率(tax rate)")
+    private java.math.BigDecimal taxRate;
+	/**折扣(discount)*/
+	@Excel(name = "折扣(discount)", width = 15)
+    @ApiModelProperty(value = "折扣(discount)")
+    private java.math.BigDecimal discount;
+	/**含税单价(tax price)*/
+	@Excel(name = "含税单价(tax price)", width = 15)
+    @ApiModelProperty(value = "含税单价(tax price)")
+    private java.math.BigDecimal taxPrice;
+	/**含税金额(tax amount)*/
+	@Excel(name = "含税金额(tax amount)", width = 15)
+    @ApiModelProperty(value = "含税金额(tax amount)")
+    private java.math.BigDecimal taxAmount;
+	/**折后单价(discounted unit price)*/
+	@Excel(name = "折后单价(discounted unit price)", width = 15)
+    @ApiModelProperty(value = "折后单价(discounted unit price)")
+    private java.math.BigDecimal discountedPrice;
+	/**折后金额(converted amount)*/
+	@Excel(name = "折后金额(converted amount)", width = 15)
+    @ApiModelProperty(value = "折后金额(converted amount)")
+    private java.math.BigDecimal discountedAmount;
+	/**备注(notes)*/
+	@Excel(name = "备注(notes)", width = 15)
+    @ApiModelProperty(value = "备注(notes)")
+    private String notes;
+	/**参照来源*/
+	@Excel(name = "参照来源", width = 15)
+    @ApiModelProperty(value = "参照来源")
+    private String sourceId;
+	/**历史主键*/
+	@Excel(name = "历史主键", width = 15)
+    @ApiModelProperty(value = "历史主键")
+    private String hisId;
+	/**历史表头主键(销售订单)*/
+	@Excel(name = "历史表头主键(销售订单)", width = 15)
+    @ApiModelProperty(value = "历史表头主键(销售订单)")
+    private String hisHeadId;
+    private String sourceType;
+}

+ 87 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrderShip.java

@@ -0,0 +1,87 @@
+package org.jeecg.modules.saleCode.entity;
+
+import java.io.Serializable;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import java.util.Date;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import java.io.UnsupportedEncodingException;
+
+/**
+ * @Description: 销售订单子表 - 船明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@ApiModel(value="sale_order_ship对象", description="销售订单子表 - 船明细")
+@Data
+@TableName("sale_order_ship")
+public class SaleOrderShip implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**状态(1-启用,0-停用)*/
+	@Excel(name = "状态(1-启用,0-停用)", width = 15)
+    @ApiModelProperty(value = "状态(1-启用,0-停用)")
+    private Integer status;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+    @ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+	/**表头主键(销售订单)*/
+    @ApiModelProperty(value = "表头主键(销售订单)")
+    private String headId;
+	/**船id*/
+	@Excel(name = "船id", width = 15)
+    @ApiModelProperty(value = "船id")
+    private String shipId;
+	/**船名*/
+	@Excel(name = "船名", width = 15)
+    @ApiModelProperty(value = "船名")
+    private String shipName;
+	/**主机号*/
+	@Excel(name = "主机号", width = 15)
+    @ApiModelProperty(value = "主机号")
+    private String hostNumber;
+	/**工程编号*/
+	@Excel(name = "工程编号", width = 15)
+    @ApiModelProperty(value = "工程编号")
+    private String projectNo;
+	/**船厂*/
+	@Excel(name = "船厂", width = 15)
+    @ApiModelProperty(value = "船厂")
+    private String shipFactory;
+	/**船东*/
+	@Excel(name = "船东", width = 15)
+    @ApiModelProperty(value = "船东")
+    private String shipowner;
+}

+ 95 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleOrderShipHis.java

@@ -0,0 +1,95 @@
+package org.jeecg.modules.saleCode.entity;
+
+import java.io.Serializable;
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import com.baomidou.mybatisplus.annotation.TableLogic;
+import org.jeecg.common.constant.ProvinceCityArea;
+import org.jeecg.common.util.SpringContextUtils;
+import lombok.Data;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.springframework.format.annotation.DateTimeFormat;
+import org.jeecgframework.poi.excel.annotation.Excel;
+import java.util.Date;
+import io.swagger.annotations.ApiModel;
+import io.swagger.annotations.ApiModelProperty;
+import java.io.UnsupportedEncodingException;
+
+/**
+ * @Description: 销售订单子表 - 船明细(历史表)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+@ApiModel(value="sale_order_ship_his对象", description="销售订单子表 - 船明细(历史表)")
+@Data
+@TableName("sale_order_ship_his")
+public class SaleOrderShipHis implements Serializable {
+    private static final long serialVersionUID = 1L;
+
+	/**主键id*/
+	@TableId(type = IdType.ASSIGN_ID)
+    @ApiModelProperty(value = "主键id")
+    private String id;
+	/**创建人*/
+    @ApiModelProperty(value = "创建人")
+    private String createBy;
+	/**创建时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "创建时间")
+    private Date createTime;
+	/**更新人*/
+    @ApiModelProperty(value = "更新人")
+    private String updateBy;
+	/**更新时间*/
+	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
+    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
+    @ApiModelProperty(value = "更新时间")
+    private Date updateTime;
+	/**状态(1-启用,0-停用)*/
+	@Excel(name = "状态(1-启用,0-停用)", width = 15)
+    @ApiModelProperty(value = "状态(1-启用,0-停用)")
+    private Integer status;
+	/**删除状态(0-正常,1-已删除)*/
+	@Excel(name = "删除状态(0-正常,1-已删除)", width = 15)
+    @ApiModelProperty(value = "删除状态(0-正常,1-已删除)")
+    @TableLogic
+    private Integer delFlag;
+	/**表头主键(销售订单)*/
+    @ApiModelProperty(value = "表头主键(销售订单)")
+    private String headId;
+	/**船id*/
+	@Excel(name = "船id", width = 15)
+    @ApiModelProperty(value = "船id")
+    private String shipId;
+	/**船名*/
+	@Excel(name = "船名", width = 15)
+    @ApiModelProperty(value = "船名")
+    private String shipName;
+	/**主机号*/
+	@Excel(name = "主机号", width = 15)
+    @ApiModelProperty(value = "主机号")
+    private String hostNumber;
+	/**工程编号*/
+	@Excel(name = "工程编号", width = 15)
+    @ApiModelProperty(value = "工程编号")
+    private String projectNo;
+	/**船厂*/
+	@Excel(name = "船厂", width = 15)
+    @ApiModelProperty(value = "船厂")
+    private String shipFactory;
+	/**船东*/
+	@Excel(name = "船东", width = 15)
+    @ApiModelProperty(value = "船东")
+    private String shipowner;
+	/**历史主键*/
+	@Excel(name = "历史主键", width = 15)
+    @ApiModelProperty(value = "历史主键")
+    private String hisId;
+	/**历史表头主键(销售订单)*/
+	@Excel(name = "历史表头主键(销售订单)", width = 15)
+    @ApiModelProperty(value = "历史表头主键(销售订单)")
+    private String hisHeadId;
+}

+ 2 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleQuotation.java

@@ -103,6 +103,7 @@ public class SaleQuotation implements Serializable {
 	/**优先级(priority)*/
 	@Excel(name = "优先级(priority)", width = 15)
     @ApiModelProperty(value = "优先级(priority)")
+    @Dict(dicCode = "priority")
     private String priority;
 	/**产品分类(production class)*/
 	@Excel(name = "产品分类(production class)", width = 15)
@@ -174,4 +175,5 @@ public class SaleQuotation implements Serializable {
 	@Excel(name = "邮箱发送", width = 15)
     @ApiModelProperty(value = "邮箱发送")
     private String send;
+    private String sourceCode;
 }

+ 1 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleQuotationHis.java

@@ -177,4 +177,5 @@ public class SaleQuotationHis implements Serializable {
 	@Excel(name = "邮箱发送", width = 15)
     @ApiModelProperty(value = "邮箱发送")
     private String send;
+    private String sourceCode;
 }

+ 1 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleQuotationProduct.java

@@ -170,4 +170,5 @@ public class SaleQuotationProduct implements Serializable {
 	@Excel(name = "备注(notes)", width = 15)
     @ApiModelProperty(value = "备注(notes)")
     private String notes;
+    private String sourceId;
 }

+ 1 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/entity/SaleQuotationProductHis.java

@@ -178,4 +178,5 @@ public class SaleQuotationProductHis implements Serializable {
 	@Excel(name = "备注(notes)", width = 15)
     @ApiModelProperty(value = "备注(notes)")
     private String notes;
+    private String sourceId;
 }

+ 17 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderFilesMapper.java

@@ -0,0 +1,17 @@
+package org.jeecg.modules.saleCode.mapper;
+
+import java.util.List;
+
+import org.apache.ibatis.annotations.Param;
+import org.jeecg.modules.saleCode.entity.SaleOrderFiles;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+
+/**
+ * @Description: 销售订单子表-文件
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface SaleOrderFilesMapper extends BaseMapper<SaleOrderFiles> {
+
+}

+ 17 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderHisMapper.java

@@ -0,0 +1,17 @@
+package org.jeecg.modules.saleCode.mapper;
+
+import java.util.List;
+
+import org.apache.ibatis.annotations.Param;
+import org.jeecg.modules.saleCode.entity.SaleOrderHis;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+
+/**
+ * @Description: 销售订单(历史表)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface SaleOrderHisMapper extends BaseMapper<SaleOrderHis> {
+
+}

+ 17 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderMapper.java

@@ -0,0 +1,17 @@
+package org.jeecg.modules.saleCode.mapper;
+
+import java.util.List;
+
+import org.apache.ibatis.annotations.Param;
+import org.jeecg.modules.saleCode.entity.SaleOrder;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+
+/**
+ * @Description: 销售订单
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface SaleOrderMapper extends BaseMapper<SaleOrder> {
+
+}

+ 31 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderProductHisMapper.java

@@ -0,0 +1,31 @@
+package org.jeecg.modules.saleCode.mapper;
+
+import java.util.List;
+import org.jeecg.modules.saleCode.entity.SaleOrderProductHis;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.apache.ibatis.annotations.Param;
+
+/**
+ * @Description: 销售订单子表 - 产品明细(历史表)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface SaleOrderProductHisMapper extends BaseMapper<SaleOrderProductHis> {
+
+	/**
+	 * 通过主表id删除子表数据
+	 *
+	 * @param mainId 主表id
+	 * @return boolean
+	 */
+	public boolean deleteByMainId(@Param("mainId") String mainId);
+
+  /**
+   * 通过主表id查询子表数据
+   *
+   * @param mainId 主表id
+   * @return List<SaleOrderProductHis>
+   */
+	public List<SaleOrderProductHis> selectByMainId(@Param("mainId") String mainId);
+}

+ 31 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderProductMapper.java

@@ -0,0 +1,31 @@
+package org.jeecg.modules.saleCode.mapper;
+
+import java.util.List;
+import org.jeecg.modules.saleCode.entity.SaleOrderProduct;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.apache.ibatis.annotations.Param;
+
+/**
+ * @Description: 销售订单子表 - 产品明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface SaleOrderProductMapper extends BaseMapper<SaleOrderProduct> {
+
+	/**
+	 * 通过主表id删除子表数据
+	 *
+	 * @param mainId 主表id
+	 * @return boolean
+	 */
+	public boolean deleteByMainId(@Param("mainId") String mainId);
+
+  /**
+   * 通过主表id查询子表数据
+   *
+   * @param mainId 主表id
+   * @return List<SaleOrderProduct>
+   */
+	public List<SaleOrderProduct> selectByMainId(@Param("mainId") String mainId);
+}

+ 31 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderShipHisMapper.java

@@ -0,0 +1,31 @@
+package org.jeecg.modules.saleCode.mapper;
+
+import java.util.List;
+import org.jeecg.modules.saleCode.entity.SaleOrderShipHis;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.apache.ibatis.annotations.Param;
+
+/**
+ * @Description: 销售订单子表 - 船明细(历史表)
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface SaleOrderShipHisMapper extends BaseMapper<SaleOrderShipHis> {
+
+	/**
+	 * 通过主表id删除子表数据
+	 *
+	 * @param mainId 主表id
+	 * @return boolean
+	 */
+	public boolean deleteByMainId(@Param("mainId") String mainId);
+
+  /**
+   * 通过主表id查询子表数据
+   *
+   * @param mainId 主表id
+   * @return List<SaleOrderShipHis>
+   */
+	public List<SaleOrderShipHis> selectByMainId(@Param("mainId") String mainId);
+}

+ 31 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleOrderShipMapper.java

@@ -0,0 +1,31 @@
+package org.jeecg.modules.saleCode.mapper;
+
+import java.util.List;
+import org.jeecg.modules.saleCode.entity.SaleOrderShip;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.apache.ibatis.annotations.Param;
+
+/**
+ * @Description: 销售订单子表 - 船明细
+ * @Author: jeecg-boot
+ * @Date:   2024-11-27
+ * @Version: V1.0
+ */
+public interface SaleOrderShipMapper extends BaseMapper<SaleOrderShip> {
+
+	/**
+	 * 通过主表id删除子表数据
+	 *
+	 * @param mainId 主表id
+	 * @return boolean
+	 */
+	public boolean deleteByMainId(@Param("mainId") String mainId);
+
+  /**
+   * 通过主表id查询子表数据
+   *
+   * @param mainId 主表id
+   * @return List<SaleOrderShip>
+   */
+	public List<SaleOrderShip> selectByMainId(@Param("mainId") String mainId);
+}

+ 9 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/SaleQuotationProductMapper.java

@@ -1,9 +1,14 @@
 package org.jeecg.modules.saleCode.mapper;
 
 import java.util.List;
+
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import org.jeecg.modules.saleCode.entity.SaleQuotationProduct;
 import com.baomidou.mybatisplus.core.mapper.BaseMapper;
 import org.apache.ibatis.annotations.Param;
+import org.jeecg.modules.saleCode.vo.SaleQuotationAlert;
 
 /**
  * @Description: 销售报价单-产品明细
@@ -28,4 +33,8 @@ public interface SaleQuotationProductMapper extends BaseMapper<SaleQuotationProd
    * @return List<SaleQuotationProduct>
    */
 	public List<SaleQuotationProduct> selectByMainId(@Param("mainId") String mainId);
+
+	public IPage<SaleQuotationAlert> saleQuotationDetailsAlert(Page<SaleQuotationAlert> page, @Param("ew") QueryWrapper<SaleQuotationAlert> queryWrapper);
+
+
 }

+ 5 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/xml/SaleOrderFilesMapper.xml

@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.jeecg.modules.saleCode.mapper.SaleOrderFilesMapper">
+
+</mapper>

+ 5 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/xml/SaleOrderHisMapper.xml

@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.jeecg.modules.saleCode.mapper.SaleOrderHisMapper">
+
+</mapper>

+ 5 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/xml/SaleOrderMapper.xml

@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.jeecg.modules.saleCode.mapper.SaleOrderMapper">
+
+</mapper>

+ 16 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/xml/SaleOrderProductHisMapper.xml

@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.jeecg.modules.saleCode.mapper.SaleOrderProductHisMapper">
+
+	<delete id="deleteByMainId" parameterType="java.lang.String">
+		DELETE 
+		FROM  sale_order_product_his 
+		WHERE
+			 head_id = #{mainId} 	</delete>
+	
+	<select id="selectByMainId" parameterType="java.lang.String" resultType="org.jeecg.modules.saleCode.entity.SaleOrderProductHis">
+		SELECT * 
+		FROM  sale_order_product_his
+		WHERE
+			 head_id = #{mainId} 	</select>
+</mapper>

+ 16 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/xml/SaleOrderProductMapper.xml

@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.jeecg.modules.saleCode.mapper.SaleOrderProductMapper">
+
+	<delete id="deleteByMainId" parameterType="java.lang.String">
+		DELETE 
+		FROM  sale_order_product 
+		WHERE
+			 head_id = #{mainId} 	</delete>
+	
+	<select id="selectByMainId" parameterType="java.lang.String" resultType="org.jeecg.modules.saleCode.entity.SaleOrderProduct">
+		SELECT * 
+		FROM  sale_order_product
+		WHERE
+			 head_id = #{mainId} 	</select>
+</mapper>

+ 16 - 0
srm-module-code/src/main/java/org/jeecg/modules/saleCode/mapper/xml/SaleOrderShipHisMapper.xml

@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="org.jeecg.modules.saleCode.mapper.SaleOrderShipHisMapper">
+
+	<delete id="deleteByMainId" parameterType="java.lang.String">
+		DELETE 
+		FROM  sale_order_ship_his 
+		WHERE
+			 head_id = #{mainId} 	</delete>
+	
+	<select id="selectByMainId" parameterType="java.lang.String" resultType="org.jeecg.modules.saleCode.entity.SaleOrderShipHis">
+		SELECT * 
+		FROM  sale_order_ship_his
+		WHERE
+			 head_id = #{mainId} 	</select>
+</mapper>

Algunos archivos no se mostraron porque demasiados archivos cambiaron en este cambio