suntianwu hace 2 años
padre
commit
5fde31129f
Se han modificado 32 ficheros con 2821 adiciones y 0 borrados
  1. 82 0
      purchase-admin/src/main/java/com/ozs/web/controller/pm/PmDemandController.java
  2. 131 0
      purchase-system/src/main/java/com/ozs/pm/doman/PmDemand.java
  3. 127 0
      purchase-system/src/main/java/com/ozs/pm/doman/PmDemandEngineering.java
  4. 86 0
      purchase-system/src/main/java/com/ozs/pm/doman/PmDemandEquip.java
  5. 112 0
      purchase-system/src/main/java/com/ozs/pm/doman/PmDemandMaterials.java
  6. 82 0
      purchase-system/src/main/java/com/ozs/pm/doman/PmDemandServe.java
  7. 50 0
      purchase-system/src/main/java/com/ozs/pm/doman/vo/requestVo/PmRequestVo.java
  8. 128 0
      purchase-system/src/main/java/com/ozs/pm/doman/vo/responseVo/PmDemandEngineeringResponseVo.java
  9. 87 0
      purchase-system/src/main/java/com/ozs/pm/doman/vo/responseVo/PmDemandEquipResponseVo.java
  10. 113 0
      purchase-system/src/main/java/com/ozs/pm/doman/vo/responseVo/PmDemandMaterialsResponseVo.java
  11. 142 0
      purchase-system/src/main/java/com/ozs/pm/doman/vo/responseVo/PmDemandResponseVo.java
  12. 83 0
      purchase-system/src/main/java/com/ozs/pm/doman/vo/responseVo/PmDemandServeResponseVo.java
  13. 49 0
      purchase-system/src/main/java/com/ozs/pm/mapper/PmDemandEngineeringMapper.java
  14. 49 0
      purchase-system/src/main/java/com/ozs/pm/mapper/PmDemandEquipMapper.java
  15. 49 0
      purchase-system/src/main/java/com/ozs/pm/mapper/PmDemandMapper.java
  16. 49 0
      purchase-system/src/main/java/com/ozs/pm/mapper/PmDemandMaterialsMapper.java
  17. 48 0
      purchase-system/src/main/java/com/ozs/pm/mapper/PmDemandServeMapper.java
  18. 48 0
      purchase-system/src/main/java/com/ozs/pm/service/IPmDemandEngineeringService.java
  19. 47 0
      purchase-system/src/main/java/com/ozs/pm/service/IPmDemandEquipService.java
  20. 48 0
      purchase-system/src/main/java/com/ozs/pm/service/IPmDemandMaterialsService.java
  21. 49 0
      purchase-system/src/main/java/com/ozs/pm/service/IPmDemandServeService.java
  22. 51 0
      purchase-system/src/main/java/com/ozs/pm/service/IPmDemandService.java
  23. 74 0
      purchase-system/src/main/java/com/ozs/pm/service/impl/PmDemandEngineeringServiceImpl.java
  24. 75 0
      purchase-system/src/main/java/com/ozs/pm/service/impl/PmDemandEquipServiceImpl.java
  25. 74 0
      purchase-system/src/main/java/com/ozs/pm/service/impl/PmDemandMaterialsServiceImpl.java
  26. 75 0
      purchase-system/src/main/java/com/ozs/pm/service/impl/PmDemandServeServiceImpl.java
  27. 103 0
      purchase-system/src/main/java/com/ozs/pm/service/impl/PmDemandServiceImpl.java
  28. 172 0
      purchase-system/src/main/resources/mapper/pm/PmDemandEngineeringMapper.xml
  29. 117 0
      purchase-system/src/main/resources/mapper/pm/PmDemandEquipMapper.xml
  30. 186 0
      purchase-system/src/main/resources/mapper/pm/PmDemandMapper.xml
  31. 118 0
      purchase-system/src/main/resources/mapper/pm/PmDemandMaterialsMapper.xml
  32. 117 0
      purchase-system/src/main/resources/mapper/pm/PmDemandServeMapper.xml

+ 82 - 0
purchase-admin/src/main/java/com/ozs/web/controller/pm/PmDemandController.java

@@ -0,0 +1,82 @@
+package com.ozs.web.controller.pm;
+
+import java.util.List;
+
+import com.ozs.pm.doman.PmDemand;
+import com.ozs.pm.doman.vo.requestVo.PmRequestVo;
+import com.ozs.pm.doman.vo.responseVo.PmDemandResponseVo;
+import com.ozs.pm.service.IPmDemandService;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.PutMapping;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+import com.ozs.common.annotation.Log;
+import com.ozs.common.core.controller.BaseController;
+import com.ozs.common.core.domain.AjaxResult;
+import com.ozs.common.enums.BusinessType;
+import com.ozs.common.core.page.TableDataInfo;
+
+/**
+ * 采购需求Controller
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@RestController
+@RequestMapping("/system/demand")
+public class PmDemandController extends BaseController
+{
+    @Autowired
+    private IPmDemandService pmDemandService;
+
+    /**
+     * 查询采购需求列表
+     */
+    @PreAuthorize("@ss.hasPermi('system:demand:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(@RequestBody PmRequestVo pmDemand)
+    {
+        startPage();
+        List<PmDemandResponseVo> list = pmDemandService.selectPmDemandList(pmDemand);
+        return getDataTable(list);
+    }
+
+    /**
+     * 获取采购需求详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('system:demand:query')")
+    @GetMapping(value = "/{demandId}")
+    public AjaxResult getInfo(@PathVariable("demandId") Long demandId)
+    {
+        return success(pmDemandService.selectPmDemandByDemandId(demandId));
+    }
+
+    /**
+     * 新增采购需求
+     */
+    @PreAuthorize("@ss.hasPermi('system:demand:add')")
+    @Log(title = "采购需求", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody PmDemand pmDemand)
+    {
+        return toAjax(pmDemandService.insertPmDemand(pmDemand));
+    }
+
+    /**
+     * 修改采购需求
+     */
+    @PreAuthorize("@ss.hasPermi('system:demand:edit')")
+    @Log(title = "采购需求", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody PmDemand pmDemand)
+    {
+        return toAjax(pmDemandService.updatePmDemand(pmDemand));
+    }
+
+
+}

+ 131 - 0
purchase-system/src/main/java/com/ozs/pm/doman/PmDemand.java

@@ -0,0 +1,131 @@
+package com.ozs.pm.doman;
+
+import java.math.BigDecimal;
+import java.util.Date;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ozs.common.annotation.Excel;
+import com.ozs.common.core.domain.BaseEntity;
+import io.swagger.annotations.ApiModel;
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+/**
+ * 采购需求对象 pm_demand
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Data
+@AllArgsConstructor
+@NoArgsConstructor
+@Builder
+@ApiModel("采购需求对象")
+public class PmDemand extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 主键 */
+    private Long demandId;
+
+    /** 计划ID */
+    @Excel(name = "计划ID")
+    private Long planId;
+
+    /** 采购单位(登录账号的单位) */
+    @Excel(name = "采购单位", readConverterExp = "登=录账号的单位")
+    private Long purchaseDeptId;
+
+    /** 项目名称 */
+    @Excel(name = "项目名称")
+    private String projectName;
+
+    /** 项目类型(0:装备类;1:物资类;2:服务类;3:工程类) */
+    @Excel(name = "项目类型", readConverterExp = "0=:装备类;1:物资类;2:服务类;3:工程类")
+    private String projectType;
+
+    /** 需求概况 */
+    @Excel(name = "需求概况")
+    private String demandOverview;
+
+    /** 概算金额(万元(保留小数点后两位) */
+    @Excel(name = "概算金额(万元", readConverterExp = "保=留小数点后两位")
+    private BigDecimal evaluation;
+
+    /** 是否为超限额计划(0:未超额,1:超额) */
+    @Excel(name = "是否为超限额计划(0:未超额,1:超额)")
+    private Integer isExcess;
+
+    /** 采购服务站 */
+    @Excel(name = "采购服务站")
+    private String purchaseServices;
+
+    /** 采购方式  (0:公开招标, 1:单一来源,2:邀请招标,3:竞争式谈判,4:询价) */
+    @Excel(name = "采购方式  (0:公开招标, 1:单一来源,2:邀请招标,3:竞争式谈判,4:询价)")
+    private String purchaseMode;
+
+    /** 计划提报需求时间--->需求单位成功提报采购需求的日期(具体到月) */
+    @Excel(name = "计划提报需求时间--->需求单位成功提报采购需求的日期", readConverterExp = "具=体到月")
+    private Date planDemandSubTime;
+
+    /** 计划完成采购时间--->公示中标结果的日期,即填制中标信息的日期(具体到月) */
+    @Excel(name = "计划完成采购时间--->公示中标结果的日期,即填制中标信息的日期", readConverterExp = "具=体到月")
+    private Date planPurchaseFinishTime;
+
+    /** 计划交付时间--->供应商完成并交付后,使用单位收到标的日期,即填制建设文档的日期 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "计划交付时间--->供应商完成并交付后,使用单位收到标的日期,即填制建设文档的日期", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date planDeliverTime;
+
+    /** 项目属性(0:应急应战项目, 1:重大规划任务项目, 2:规划任务项目, 3:一般项目) */
+    @Excel(name = "项目属性", readConverterExp = "0=:应急应战项目,,1=:重大规划任务项目,,2=:规划任务项目,,3=:一般项目")
+    private String projectAttr;
+
+    /** 计划调整情况及理由--->如计划需要变更,在填写申请修改时需填写调整情况及理由,审核单位审核通过后显示该信息 */
+    @Excel(name = "计划调整情况及理由--->如计划需要变更,在填写申请修改时需填写调整情况及理由,审核单位审核通过后显示该信息")
+    private String adjustReason;
+
+    /** 备注 */
+    @Excel(name = "备注")
+    private String remarks;
+
+    /** 实际提报需求时间--->需求单位成功提报采购需求的日期(具体到日) */
+    @Excel(name = "实际提报需求时间--->需求单位成功提报采购需求的日期", readConverterExp = "具=体到日")
+    private Date realDemandCommitTime;
+
+    /** 实际完成采购时间--->公示中标结果的日期,即填制中标信息的日期(具体到日) */
+    @Excel(name = "实际完成采购时间--->公示中标结果的日期,即填制中标信息的日期", readConverterExp = "具=体到日")
+    private Date realPurchaseFinishTime;
+
+    /** 实际交付(实施)时间--->供应商完成并交付后,使用单位收到标的日期,即填制建设文档的日期 */
+    @Excel(name = "实际交付", readConverterExp = "实=施")
+    private Date realDeliverTime;
+
+    /** 审核时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "审核时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date auditTime;
+
+    /** 预警状态(0:正常,1:预警) */
+    @Excel(name = "预警状态(0:正常,1:预警)")
+    private String warnStatus;
+
+    /** 项目状态(4:需求待填制,5:需求待提交,6:需求待审核,7:任务待下达,8:任务已下达,9:中标信息待填制,10:中标信息已填制,11:合同待填制,12:合同已填制,13:项目建设中,14:项目建设完成) */
+    @Excel(name = "项目状态(4:需求待填制,5:需求待提交,6:需求待审核,7:任务待下达,8:任务已下达,9:中标信息待填制,10:中标信息已填制,11:合同待填制,12:合同已填制,13:项目建设中,14:项目建设完成)")
+    private Long projectStatus;
+
+    /** 退回原因 */
+    @Excel(name = "退回原因")
+    private String refuseReason;
+
+    /** 滞后原因 */
+    @Excel(name = "滞后原因")
+    private String delayReason;
+
+    /** 调整建议 */
+    @Excel(name = "调整建议")
+    private String adjustAdvice;
+
+
+}

+ 127 - 0
purchase-system/src/main/java/com/ozs/pm/doman/PmDemandEngineering.java

@@ -0,0 +1,127 @@
+package com.ozs.pm.doman;
+
+import java.math.BigDecimal;
+import com.ozs.common.annotation.Excel;
+import com.ozs.common.core.domain.BaseEntity;
+import io.swagger.annotations.ApiModel;
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+/**
+ * 采购需求工程类对象 pm_demand_engineering
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Data
+@AllArgsConstructor
+@NoArgsConstructor
+@Builder
+@ApiModel("采购需求工程类对象")
+public class PmDemandEngineering extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 主键 */
+    private Long demandEngineeringId;
+
+    /** 需求ID */
+    @Excel(name = "需求ID")
+    private Long demandId;
+
+    /** 工程项目名称 */
+    @Excel(name = "工程项目名称")
+    private String engineeringName;
+
+    /** 建设地点 */
+    @Excel(name = "建设地点")
+    private String constructionLocation;
+
+    /** 设计任务书批复文号 */
+    @Excel(name = "设计任务书批复文号")
+    private String designAssignmenApprovalNumber;
+
+    /** 工程建设计划文号 */
+    @Excel(name = "工程建设计划文号")
+    private BigDecimal projectConstructionPlanNumber;
+
+    /** 任务书批复规模(㎡): */
+    @Excel(name = "任务书批复规模(㎡):")
+    private BigDecimal tassignmentApprovalScale;
+
+    /** 任务书批复投资 */
+    @Excel(name = "任务书批复投资")
+    private String tassignmentApprovalInvestmen;
+
+    /** 规划许可文号 */
+    @Excel(name = "规划许可文号")
+    private String planningLicenseNumber;
+
+    /** 密级处理 */
+    @Excel(name = "密级处理")
+    private String classifiedTreatment;
+
+    /** 采购项目规模(㎡) */
+    @Excel(name = "采购项目规模(㎡)")
+    private BigDecimal procurementProjectScale;
+
+    /** 采购项目投资(万元) */
+    @Excel(name = "采购项目投资(万元)")
+    private BigDecimal procurementProjectInvestment;
+
+    /** 联系人 */
+    @Excel(name = "联系人")
+    private BigDecimal linkman;
+
+    /** 电话 */
+    @Excel(name = "电话")
+    private BigDecimal phone;
+
+    /** 项目类别 */
+    @Excel(name = "项目类别")
+    private String projectCategory;
+
+    /** 承包方式 */
+    @Excel(name = "承包方式")
+    private String contractingMode;
+
+    /** 施工图是否完成(0未完成,1完成) */
+    @Excel(name = "施工图是否完成(0未完成,1完成)")
+    private String constructionDrawing;
+
+    /** 设计单位 */
+    @Excel(name = "设计单位")
+    private BigDecimal designUnit;
+
+    /** 最高限价 */
+    @Excel(name = "最高限价")
+    private BigDecimal ceilingPrice;
+
+    /** 采购方式建议 */
+    @Excel(name = "采购方式建议")
+    private String procurementMethodSuggest;
+
+    /** 投标(报价)人资质等级要求 */
+    @Excel(name = "投标(报价)人资质等级要求")
+    private String qualificationLevelRequirement;
+
+    /** 供应商 */
+    @Excel(name = "供应商")
+    private Long supplierId;
+
+    /** 备注 */
+    @Excel(name = "备注")
+    private String remarks;
+
+    /** 项目附件 */
+    @Excel(name = "项目附件")
+    private String projectFiles;
+
+    /** 逻辑删除字段--->(0:正常,1:已删除) */
+    @Excel(name = "逻辑删除字段--->", readConverterExp = "0=:正常,1:已删除")
+    private Integer isDelete;
+
+
+}

+ 86 - 0
purchase-system/src/main/java/com/ozs/pm/doman/PmDemandEquip.java

@@ -0,0 +1,86 @@
+package com.ozs.pm.doman;
+
+import java.math.BigDecimal;
+import java.util.Date;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ozs.common.annotation.Excel;
+import com.ozs.common.core.domain.BaseEntity;
+import io.swagger.annotations.ApiModel;
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+/**
+ * 采购需求装备类对象 pm_demand_equip
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Data
+@AllArgsConstructor
+@NoArgsConstructor
+@Builder
+@ApiModel("采购需求装备类对象")
+public class PmDemandEquip extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 主键 */
+    private Long demandEquipId;
+
+    /** 需求ID */
+    @Excel(name = "需求ID")
+    private Long demandId;
+
+    /** 物资类别及品种名称 */
+    @Excel(name = "物资类别及品种名称")
+    private String typeAndName;
+
+    /** 规格型号长*宽*高 */
+    @Excel(name = "规格型号长*宽*高")
+    private String specification;
+
+    /** 质量技术标准(技术参数): */
+    @Excel(name = "质量技术标准(技术参数):")
+    private String qualityTechnicalStandard;
+
+    /** 计量单位 */
+    @Excel(name = "计量单位")
+    private String measurementUnit;
+
+    /** 采购数量 */
+    @Excel(name = "采购数量")
+    private BigDecimal procurementQuantity;
+
+    /** 单价(元) */
+    @Excel(name = "单价(元)")
+    private BigDecimal price;
+
+    /** 预算金额(万元) */
+    @Excel(name = "预算金额(万元)")
+    private BigDecimal budgetAmount;
+
+    /** 需求提报时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "需求提报时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date demandCommitTime;
+
+    /** 采购方式建议 */
+    @Excel(name = "采购方式建议")
+    private String procurementMethodSuggest;
+
+    /** 备注 */
+    @Excel(name = "备注")
+    private String remarks;
+
+    /** 项目附件 */
+    @Excel(name = "项目附件")
+    private String projectFiles;
+
+    /** 逻辑删除字段--->(0:正常,1:已删除) */
+    @Excel(name = "逻辑删除字段--->", readConverterExp = "0=:正常,1:已删除")
+    private Integer isDelete;
+
+
+}

+ 112 - 0
purchase-system/src/main/java/com/ozs/pm/doman/PmDemandMaterials.java

@@ -0,0 +1,112 @@
+package com.ozs.pm.doman;
+
+import java.math.BigDecimal;
+import java.util.Date;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ozs.common.annotation.Excel;
+import com.ozs.common.core.domain.BaseEntity;
+import io.swagger.annotations.ApiModel;
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+/**
+ * 采购需求物资类对象 pm_demand_materials
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Data
+@AllArgsConstructor
+@NoArgsConstructor
+@Builder
+@ApiModel("采购需求物资类对象")
+public class PmDemandMaterials extends BaseEntity {
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 主键
+     */
+    private Long demandMaterialsId;
+
+    /**
+     * 需求ID
+     */
+    @Excel(name = "需求ID")
+    private Long demandId;
+
+    /**
+     * 物资类别及品种名称
+     */
+    @Excel(name = "物资类别及品种名称")
+    private String typeAndName;
+
+    /**
+     * 规格型号长*宽*高
+     */
+    @Excel(name = "规格型号长*宽*高")
+    private String specification;
+
+    /**
+     * 质量技术标准(技术参数):
+     */
+    @Excel(name = "质量技术标准(技术参数):")
+    private String qualityTechnicalStandard;
+
+    /**
+     * 计量单位
+     */
+    @Excel(name = "计量单位")
+    private String measurementUnit;
+
+    /**
+     * 采购数量
+     */
+    @Excel(name = "采购数量")
+    private BigDecimal procurementQuantity;
+
+    /**
+     * 单价(元)
+     */
+    @Excel(name = "单价(元)")
+    private BigDecimal price;
+
+    /**
+     * 预算金额(万元)
+     */
+    @Excel(name = "预算金额(万元)")
+    private BigDecimal budgetAmount;
+
+    /**
+     * 需求提报时间
+     */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "需求提报时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date demandCommitTime;
+
+    /**
+     * 采购方式建议
+     */
+    @Excel(name = "采购方式建议")
+    private String procurementMethodSuggest;
+
+    /**
+     * 备注
+     */
+    @Excel(name = "备注")
+    private String remarks;
+
+    /**
+     * 项目附件
+     */
+    @Excel(name = "项目附件")
+    private String projectFiles;
+
+    /**
+     * 逻辑删除字段--->(0:正常,1:已删除)
+     */
+    @Excel(name = "逻辑删除字段--->", readConverterExp = "0=:正常,1:已删除")
+    private Integer isDelete;
+
+}

+ 82 - 0
purchase-system/src/main/java/com/ozs/pm/doman/PmDemandServe.java

@@ -0,0 +1,82 @@
+package com.ozs.pm.doman;
+
+import java.math.BigDecimal;
+import com.ozs.common.annotation.Excel;
+import com.ozs.common.core.domain.BaseEntity;
+import io.swagger.annotations.ApiModel;
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+/**
+ * 采购需求服务类对象 pm_demand_serve
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Data
+@AllArgsConstructor
+@NoArgsConstructor
+@Builder
+@ApiModel("采购需求服务类对象")
+public class PmDemandServe extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 主键 */
+    private Long demandServeId;
+
+    /** 需求ID */
+    @Excel(name = "需求ID")
+    private Long demandId;
+
+    /** 服务项目名称 */
+    @Excel(name = "服务项目名称")
+    private String serviceName;
+
+    /** 技术服务要求 */
+    @Excel(name = "技术服务要求")
+    private String technicalServiceRequirement;
+
+    /** 计量单位 */
+    @Excel(name = "计量单位")
+    private String measurementUnit;
+
+    /** 采购数量 */
+    @Excel(name = "采购数量")
+    private BigDecimal procurementQuantity;
+
+    /** 单价(元) */
+    @Excel(name = "单价(元)")
+    private BigDecimal price;
+
+    /** 预算金额(万元) */
+    @Excel(name = "预算金额(万元)")
+    private BigDecimal budgetAmount;
+
+    /** 交货期限 */
+    @Excel(name = "交货期限")
+    private String deliveryTimeLimit;
+
+    /** 采购方式建议 */
+    @Excel(name = "采购方式建议")
+    private String procurementMethodSuggest;
+
+    /** 供应商 */
+    @Excel(name = "供应商")
+    private Long supplierId;
+
+    /** 备注 */
+    @Excel(name = "备注")
+    private String remarks;
+
+    /** 项目附件 */
+    @Excel(name = "项目附件")
+    private String projectFiles;
+
+    /** 逻辑删除字段--->(0:正常,1:已删除) */
+    @Excel(name = "逻辑删除字段--->", readConverterExp = "0=:正常,1:已删除")
+    private Integer isDelete;
+
+}

+ 50 - 0
purchase-system/src/main/java/com/ozs/pm/doman/vo/requestVo/PmRequestVo.java

@@ -0,0 +1,50 @@
+package com.ozs.pm.doman.vo.requestVo;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ozs.common.annotation.Excel;
+import com.ozs.common.core.domain.BaseEntity;
+import io.swagger.annotations.ApiModel;
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import java.math.BigDecimal;
+import java.util.Date;
+
+/**
+ * 采购需求对象 pm_demand
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Data
+@AllArgsConstructor
+@NoArgsConstructor
+@Builder
+@ApiModel("采购需求对象")
+public class PmRequestVo
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 项目名称 */
+    @Excel(name = "项目名称")
+    private String projectName;
+
+    /** 采购服务站 */
+    @Excel(name = "采购服务站")
+    private String purchaseServiceStation;
+
+
+    /** 项目状态(4:需求待填制,5:需求待提交,6:需求待审核,7:任务待下达,8:任务已下达,9:中标信息待填制,10:中标信息已填制,11:合同待填制,12:合同已填制,13:项目建设中,14:项目建设完成) */
+    @Excel(name = "项目状态(4:需求待填制,5:需求待提交,6:需求待审核,7:任务待下达,8:任务已下达,9:中标信息待填制,10:中标信息已填制,11:合同待填制,12:合同已填制,13:项目建设中,14:项目建设完成)")
+    private Long projectStatus;
+
+    /** 开始日期 */
+    @Excel(name = "开始日期")
+    private String beginDate;
+
+    /** 结束日期 */
+    @Excel(name = "结束日期")
+    private String endDate;
+}

+ 128 - 0
purchase-system/src/main/java/com/ozs/pm/doman/vo/responseVo/PmDemandEngineeringResponseVo.java

@@ -0,0 +1,128 @@
+package com.ozs.pm.doman.vo.responseVo;
+
+import com.ozs.common.annotation.Excel;
+import com.ozs.common.core.domain.BaseEntity;
+import io.swagger.annotations.ApiModel;
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import java.math.BigDecimal;
+
+/**
+ * 采购需求工程类对象 pm_demand_engineering
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Data
+@AllArgsConstructor
+@NoArgsConstructor
+@Builder
+@ApiModel("采购需求工程类对象")
+public class PmDemandEngineeringResponseVo extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 主键 */
+    private Long demandEngineeringId;
+
+    /** 需求ID */
+    @Excel(name = "需求ID")
+    private Long demandId;
+
+    /** 工程项目名称 */
+    @Excel(name = "工程项目名称")
+    private String engineeringName;
+
+    /** 建设地点 */
+    @Excel(name = "建设地点")
+    private String constructionLocation;
+
+    /** 设计任务书批复文号 */
+    @Excel(name = "设计任务书批复文号")
+    private String designAssignmenApprovalNumber;
+
+    /** 工程建设计划文号 */
+    @Excel(name = "工程建设计划文号")
+    private BigDecimal projectConstructionPlanNumber;
+
+    /** 任务书批复规模(㎡): */
+    @Excel(name = "任务书批复规模(㎡):")
+    private BigDecimal tassignmentApprovalScale;
+
+    /** 任务书批复投资 */
+    @Excel(name = "任务书批复投资")
+    private String tassignmentApprovalInvestmen;
+
+    /** 规划许可文号 */
+    @Excel(name = "规划许可文号")
+    private String planningLicenseNumber;
+
+    /** 密级处理 */
+    @Excel(name = "密级处理")
+    private String classifiedTreatment;
+
+    /** 采购项目规模(㎡) */
+    @Excel(name = "采购项目规模(㎡)")
+    private BigDecimal procurementProjectScale;
+
+    /** 采购项目投资(万元) */
+    @Excel(name = "采购项目投资(万元)")
+    private BigDecimal procurementProjectInvestment;
+
+    /** 联系人 */
+    @Excel(name = "联系人")
+    private BigDecimal linkman;
+
+    /** 电话 */
+    @Excel(name = "电话")
+    private BigDecimal phone;
+
+    /** 项目类别 */
+    @Excel(name = "项目类别")
+    private String projectCategory;
+
+    /** 承包方式 */
+    @Excel(name = "承包方式")
+    private String contractingMode;
+
+    /** 施工图是否完成(0未完成,1完成) */
+    @Excel(name = "施工图是否完成(0未完成,1完成)")
+    private String constructionDrawing;
+
+    /** 设计单位 */
+    @Excel(name = "设计单位")
+    private BigDecimal designUnit;
+
+    /** 最高限价 */
+    @Excel(name = "最高限价")
+    private BigDecimal ceilingPrice;
+
+    /** 采购方式建议 */
+    @Excel(name = "采购方式建议")
+    private String procurementMethodSuggest;
+
+    /** 投标(报价)人资质等级要求 */
+    @Excel(name = "投标(报价)人资质等级要求")
+    private String qualificationLevelRequirement;
+
+    /** 供应商 */
+    @Excel(name = "供应商")
+    private Long supplierId;
+
+    /** 备注 */
+    @Excel(name = "备注")
+    private String remarks;
+
+    /** 项目附件 */
+    @Excel(name = "项目附件")
+    private String projectFiles;
+
+    /** 逻辑删除字段--->(0:正常,1:已删除) */
+    @Excel(name = "逻辑删除字段--->", readConverterExp = "0=:正常,1:已删除")
+    private Integer isDelete;
+
+
+}

+ 87 - 0
purchase-system/src/main/java/com/ozs/pm/doman/vo/responseVo/PmDemandEquipResponseVo.java

@@ -0,0 +1,87 @@
+package com.ozs.pm.doman.vo.responseVo;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ozs.common.annotation.Excel;
+import com.ozs.common.core.domain.BaseEntity;
+import io.swagger.annotations.ApiModel;
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import java.math.BigDecimal;
+import java.util.Date;
+
+/**
+ * 采购需求装备类对象 pm_demand_equip
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Data
+@AllArgsConstructor
+@NoArgsConstructor
+@Builder
+@ApiModel("采购需求装备类对象")
+public class PmDemandEquipResponseVo extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 主键 */
+    private Long demandEquipId;
+
+    /** 需求ID */
+    @Excel(name = "需求ID")
+    private Long demandId;
+
+    /** 物资类别及品种名称 */
+    @Excel(name = "物资类别及品种名称")
+    private String typeAndName;
+
+    /** 规格型号长*宽*高 */
+    @Excel(name = "规格型号长*宽*高")
+    private String specification;
+
+    /** 质量技术标准(技术参数): */
+    @Excel(name = "质量技术标准(技术参数):")
+    private String qualityTechnicalStandard;
+
+    /** 计量单位 */
+    @Excel(name = "计量单位")
+    private String measurementUnit;
+
+    /** 采购数量 */
+    @Excel(name = "采购数量")
+    private BigDecimal procurementQuantity;
+
+    /** 单价(元) */
+    @Excel(name = "单价(元)")
+    private BigDecimal price;
+
+    /** 预算金额(万元) */
+    @Excel(name = "预算金额(万元)")
+    private BigDecimal budgetAmount;
+
+    /** 需求提报时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "需求提报时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date demandCommitTime;
+
+    /** 采购方式建议 */
+    @Excel(name = "采购方式建议")
+    private String procurementMethodSuggest;
+
+    /** 备注 */
+    @Excel(name = "备注")
+    private String remarks;
+
+    /** 项目附件 */
+    @Excel(name = "项目附件")
+    private String projectFiles;
+
+    /** 逻辑删除字段--->(0:正常,1:已删除) */
+    @Excel(name = "逻辑删除字段--->", readConverterExp = "0=:正常,1:已删除")
+    private Integer isDelete;
+
+
+}

+ 113 - 0
purchase-system/src/main/java/com/ozs/pm/doman/vo/responseVo/PmDemandMaterialsResponseVo.java

@@ -0,0 +1,113 @@
+package com.ozs.pm.doman.vo.responseVo;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ozs.common.annotation.Excel;
+import com.ozs.common.core.domain.BaseEntity;
+import io.swagger.annotations.ApiModel;
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import java.math.BigDecimal;
+import java.util.Date;
+
+/**
+ * 采购需求物资类对象 pm_demand_materials
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Data
+@AllArgsConstructor
+@NoArgsConstructor
+@Builder
+@ApiModel("采购需求物资类对象")
+public class PmDemandMaterialsResponseVo extends BaseEntity {
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 主键
+     */
+    private Long demandMaterialsId;
+
+    /**
+     * 需求ID
+     */
+    @Excel(name = "需求ID")
+    private Long demandId;
+
+    /**
+     * 物资类别及品种名称
+     */
+    @Excel(name = "物资类别及品种名称")
+    private String typeAndName;
+
+    /**
+     * 规格型号长*宽*高
+     */
+    @Excel(name = "规格型号长*宽*高")
+    private String specification;
+
+    /**
+     * 质量技术标准(技术参数):
+     */
+    @Excel(name = "质量技术标准(技术参数):")
+    private String qualityTechnicalStandard;
+
+    /**
+     * 计量单位
+     */
+    @Excel(name = "计量单位")
+    private String measurementUnit;
+
+    /**
+     * 采购数量
+     */
+    @Excel(name = "采购数量")
+    private BigDecimal procurementQuantity;
+
+    /**
+     * 单价(元)
+     */
+    @Excel(name = "单价(元)")
+    private BigDecimal price;
+
+    /**
+     * 预算金额(万元)
+     */
+    @Excel(name = "预算金额(万元)")
+    private BigDecimal budgetAmount;
+
+    /**
+     * 需求提报时间
+     */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "需求提报时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date demandCommitTime;
+
+    /**
+     * 采购方式建议
+     */
+    @Excel(name = "采购方式建议")
+    private String procurementMethodSuggest;
+
+    /**
+     * 备注
+     */
+    @Excel(name = "备注")
+    private String remarks;
+
+    /**
+     * 项目附件
+     */
+    @Excel(name = "项目附件")
+    private String projectFiles;
+
+    /**
+     * 逻辑删除字段--->(0:正常,1:已删除)
+     */
+    @Excel(name = "逻辑删除字段--->", readConverterExp = "0=:正常,1:已删除")
+    private Integer isDelete;
+
+}

+ 142 - 0
purchase-system/src/main/java/com/ozs/pm/doman/vo/responseVo/PmDemandResponseVo.java

@@ -0,0 +1,142 @@
+package com.ozs.pm.doman.vo.responseVo;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ozs.common.annotation.Excel;
+import com.ozs.common.core.domain.BaseEntity;
+import io.swagger.annotations.ApiModel;
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import java.math.BigDecimal;
+import java.util.Date;
+
+/**
+ * 采购需求对象 pm_demand
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Data
+@AllArgsConstructor
+@NoArgsConstructor
+@Builder
+@ApiModel("采购需求对象")
+public class PmDemandResponseVo extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 主键 */
+    private Long demandId;
+
+    /** 计划ID */
+    @Excel(name = "计划ID")
+    private Long planId;
+
+    /** 采购单位(登录账号的单位) */
+    @Excel(name = "采购单位", readConverterExp = "登=录账号的单位")
+    private Long purchaseDeptId;
+
+    /** 项目名称 */
+    @Excel(name = "项目名称")
+    private String projectName;
+
+    /** 项目类型(0:装备类;1:物资类;2:服务类;3:工程类) */
+    @Excel(name = "项目类型", readConverterExp = "0=:装备类;1:物资类;2:服务类;3:工程类")
+    private String projectType;
+
+    /** 需求概况 */
+    @Excel(name = "需求概况")
+    private String demandOverview;
+
+    /** 概算金额(万元(保留小数点后两位) */
+    @Excel(name = "概算金额(万元", readConverterExp = "保=留小数点后两位")
+    private BigDecimal evaluation;
+
+    /** 是否为超限额计划(0:未超额,1:超额) */
+    @Excel(name = "是否为超限额计划(0:未超额,1:超额)")
+    private Integer isExcess;
+
+    /** 采购服务站 */
+    @Excel(name = "采购服务站")
+    private String purchaseServices;
+
+    /** 采购方式  (0:公开招标, 1:单一来源,2:邀请招标,3:竞争式谈判,4:询价) */
+    @Excel(name = "采购方式  (0:公开招标, 1:单一来源,2:邀请招标,3:竞争式谈判,4:询价)")
+    private String purchaseMode;
+
+    /** 计划提报需求时间--->需求单位成功提报采购需求的日期(具体到月) */
+    @Excel(name = "计划提报需求时间--->需求单位成功提报采购需求的日期", readConverterExp = "具=体到月")
+    private Date planDemandSubTime;
+
+    /** 计划完成采购时间--->公示中标结果的日期,即填制中标信息的日期(具体到月) */
+    @Excel(name = "计划完成采购时间--->公示中标结果的日期,即填制中标信息的日期", readConverterExp = "具=体到月")
+    private Date planPurchaseFinishTime;
+
+    /** 计划交付时间--->供应商完成并交付后,使用单位收到标的日期,即填制建设文档的日期 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "计划交付时间--->供应商完成并交付后,使用单位收到标的日期,即填制建设文档的日期", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date planDeliverTime;
+
+    /** 项目属性(0:应急应战项目, 1:重大规划任务项目, 2:规划任务项目, 3:一般项目) */
+    @Excel(name = "项目属性", readConverterExp = "0=:应急应战项目,,1=:重大规划任务项目,,2=:规划任务项目,,3=:一般项目")
+    private String projectAttr;
+
+    /** 计划调整情况及理由--->如计划需要变更,在填写申请修改时需填写调整情况及理由,审核单位审核通过后显示该信息 */
+    @Excel(name = "计划调整情况及理由--->如计划需要变更,在填写申请修改时需填写调整情况及理由,审核单位审核通过后显示该信息")
+    private String adjustReason;
+
+    /** 备注 */
+    @Excel(name = "备注")
+    private String remarks;
+
+    /** 实际提报需求时间--->需求单位成功提报采购需求的日期(具体到日) */
+    @Excel(name = "实际提报需求时间--->需求单位成功提报采购需求的日期", readConverterExp = "具=体到日")
+    private Date realDemandCommitTime;
+
+    /** 实际完成采购时间--->公示中标结果的日期,即填制中标信息的日期(具体到日) */
+    @Excel(name = "实际完成采购时间--->公示中标结果的日期,即填制中标信息的日期", readConverterExp = "具=体到日")
+    private Date realPurchaseFinishTime;
+
+    /** 实际交付(实施)时间--->供应商完成并交付后,使用单位收到标的日期,即填制建设文档的日期 */
+    @Excel(name = "实际交付", readConverterExp = "实=施")
+    private Date realDeliverTime;
+
+    /** 审核时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "审核时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date auditTime;
+
+    /** 预警状态(0:正常,1:预警) */
+    @Excel(name = "预警状态(0:正常,1:预警)")
+    private String warnStatus;
+
+    /** 项目状态(4:需求待填制,5:需求待提交,6:需求待审核,7:任务待下达,8:任务已下达,9:中标信息待填制,10:中标信息已填制,11:合同待填制,12:合同已填制,13:项目建设中,14:项目建设完成) */
+    @Excel(name = "项目状态(4:需求待填制,5:需求待提交,6:需求待审核,7:任务待下达,8:任务已下达,9:中标信息待填制,10:中标信息已填制,11:合同待填制,12:合同已填制,13:项目建设中,14:项目建设完成)")
+    private Long projectStatus;
+
+    /** 退回原因 */
+    @Excel(name = "退回原因")
+    private String refuseReason;
+
+    /** 滞后原因 */
+    @Excel(name = "滞后原因")
+    private String delayReason;
+
+    /** 调整建议 */
+    @Excel(name = "调整建议")
+    private String adjustAdvice;
+
+    /** 采购需求工程类对象 */
+    private PmDemandEngineeringResponseVo pmDemandEngineeringResponseVo;
+
+    /** 采购需求装备类对象 */
+    private PmDemandEquipResponseVo pmDemandEquipResponseVo;
+
+    /** 采购需求物资类对象 */
+    private PmDemandMaterialsResponseVo pmDemandMaterialsResponseVo;
+
+    /** 采购需求服务类对象 */
+    private PmDemandServeResponseVo pmDemandServeResponseVo;
+}

+ 83 - 0
purchase-system/src/main/java/com/ozs/pm/doman/vo/responseVo/PmDemandServeResponseVo.java

@@ -0,0 +1,83 @@
+package com.ozs.pm.doman.vo.responseVo;
+
+import com.ozs.common.annotation.Excel;
+import com.ozs.common.core.domain.BaseEntity;
+import io.swagger.annotations.ApiModel;
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import java.math.BigDecimal;
+
+/**
+ * 采购需求服务类对象 pm_demand_serve
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Data
+@AllArgsConstructor
+@NoArgsConstructor
+@Builder
+@ApiModel("采购需求服务类对象")
+public class PmDemandServeResponseVo extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 主键 */
+    private Long demandServeId;
+
+    /** 需求ID */
+    @Excel(name = "需求ID")
+    private Long demandId;
+
+    /** 服务项目名称 */
+    @Excel(name = "服务项目名称")
+    private String serviceName;
+
+    /** 技术服务要求 */
+    @Excel(name = "技术服务要求")
+    private String technicalServiceRequirement;
+
+    /** 计量单位 */
+    @Excel(name = "计量单位")
+    private String measurementUnit;
+
+    /** 采购数量 */
+    @Excel(name = "采购数量")
+    private BigDecimal procurementQuantity;
+
+    /** 单价(元) */
+    @Excel(name = "单价(元)")
+    private BigDecimal price;
+
+    /** 预算金额(万元) */
+    @Excel(name = "预算金额(万元)")
+    private BigDecimal budgetAmount;
+
+    /** 交货期限 */
+    @Excel(name = "交货期限")
+    private String deliveryTimeLimit;
+
+    /** 采购方式建议 */
+    @Excel(name = "采购方式建议")
+    private String procurementMethodSuggest;
+
+    /** 供应商 */
+    @Excel(name = "供应商")
+    private Long supplierId;
+
+    /** 备注 */
+    @Excel(name = "备注")
+    private String remarks;
+
+    /** 项目附件 */
+    @Excel(name = "项目附件")
+    private String projectFiles;
+
+    /** 逻辑删除字段--->(0:正常,1:已删除) */
+    @Excel(name = "逻辑删除字段--->", readConverterExp = "0=:正常,1:已删除")
+    private Integer isDelete;
+
+}

+ 49 - 0
purchase-system/src/main/java/com/ozs/pm/mapper/PmDemandEngineeringMapper.java

@@ -0,0 +1,49 @@
+package com.ozs.pm.mapper;
+
+import com.ozs.pm.doman.PmDemandEngineering;
+
+import java.util.List;
+
+
+/**
+ * 采购需求工程类Mapper接口
+ * 
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+public interface PmDemandEngineeringMapper 
+{
+    /**
+     * 查询采购需求工程类
+     * 
+     * @param demandEngineeringId 采购需求工程类主键
+     * @return 采购需求工程类
+     */
+    public PmDemandEngineering selectPmDemandEngineeringByDemandEngineeringId(Long demandEngineeringId);
+
+    /**
+     * 查询采购需求工程类列表
+     * 
+     * @param pmDemandEngineering 采购需求工程类
+     * @return 采购需求工程类集合
+     */
+    public List<PmDemandEngineering> selectPmDemandEngineeringList(PmDemandEngineering pmDemandEngineering);
+
+    /**
+     * 新增采购需求工程类
+     * 
+     * @param pmDemandEngineering 采购需求工程类
+     * @return 结果
+     */
+    public int insertPmDemandEngineering(PmDemandEngineering pmDemandEngineering);
+
+    /**
+     * 修改采购需求工程类
+     * 
+     * @param pmDemandEngineering 采购需求工程类
+     * @return 结果
+     */
+    public int updatePmDemandEngineering(PmDemandEngineering pmDemandEngineering);
+
+
+}

+ 49 - 0
purchase-system/src/main/java/com/ozs/pm/mapper/PmDemandEquipMapper.java

@@ -0,0 +1,49 @@
+package com.ozs.pm.mapper;
+
+import com.ozs.pm.doman.PmDemandEquip;
+
+import java.util.List;
+
+
+/**
+ * 采购需求装备类Mapper接口
+ * 
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+public interface PmDemandEquipMapper 
+{
+    /**
+     * 查询采购需求装备类
+     * 
+     * @param demandEquipId 采购需求装备类主键
+     * @return 采购需求装备类
+     */
+    public PmDemandEquip selectPmDemandEquipByDemandEquipId(Long demandEquipId);
+
+    /**
+     * 查询采购需求装备类列表
+     * 
+     * @param pmDemandEquip 采购需求装备类
+     * @return 采购需求装备类集合
+     */
+    public List<PmDemandEquip> selectPmDemandEquipList(PmDemandEquip pmDemandEquip);
+
+    /**
+     * 新增采购需求装备类
+     * 
+     * @param pmDemandEquip 采购需求装备类
+     * @return 结果
+     */
+    public int insertPmDemandEquip(PmDemandEquip pmDemandEquip);
+
+    /**
+     * 修改采购需求装备类
+     * 
+     * @param pmDemandEquip 采购需求装备类
+     * @return 结果
+     */
+    public int updatePmDemandEquip(PmDemandEquip pmDemandEquip);
+
+
+}

+ 49 - 0
purchase-system/src/main/java/com/ozs/pm/mapper/PmDemandMapper.java

@@ -0,0 +1,49 @@
+package com.ozs.pm.mapper;
+
+import com.ozs.pm.doman.PmDemand;
+
+import java.util.List;
+
+
+/**
+ * 采购需求Mapper接口
+ * 
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+public interface PmDemandMapper 
+{
+    /**
+     * 查询采购需求
+     * 
+     * @param demandId 采购需求主键
+     * @return 采购需求
+     */
+    public PmDemand selectPmDemandByDemandId(Long demandId);
+
+    /**
+     * 查询采购需求列表
+     * 
+     * @param pmDemand 采购需求
+     * @return 采购需求集合
+     */
+    public List<PmDemand> selectPmDemandList(PmDemand pmDemand);
+
+    /**
+     * 新增采购需求
+     * 
+     * @param pmDemand 采购需求
+     * @return 结果
+     */
+    public int insertPmDemand(PmDemand pmDemand);
+
+    /**
+     * 修改采购需求
+     * 
+     * @param pmDemand 采购需求
+     * @return 结果
+     */
+    public int updatePmDemand(PmDemand pmDemand);
+
+
+}

+ 49 - 0
purchase-system/src/main/java/com/ozs/pm/mapper/PmDemandMaterialsMapper.java

@@ -0,0 +1,49 @@
+package com.ozs.pm.mapper;
+
+import com.ozs.pm.doman.PmDemandMaterials;
+
+import java.util.List;
+
+
+/**
+ * 采购需求物资类Mapper接口
+ * 
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+public interface PmDemandMaterialsMapper 
+{
+    /**
+     * 查询采购需求物资类
+     * 
+     * @param demandMaterialsId 采购需求物资类主键
+     * @return 采购需求物资类
+     */
+    public PmDemandMaterials selectPmDemandMaterialsByDemandMaterialsId(Long demandMaterialsId);
+
+    /**
+     * 查询采购需求物资类列表
+     * 
+     * @param pmDemandMaterials 采购需求物资类
+     * @return 采购需求物资类集合
+     */
+    public List<PmDemandMaterials> selectPmDemandMaterialsList(PmDemandMaterials pmDemandMaterials);
+
+    /**
+     * 新增采购需求物资类
+     * 
+     * @param pmDemandMaterials 采购需求物资类
+     * @return 结果
+     */
+    public int insertPmDemandMaterials(PmDemandMaterials pmDemandMaterials);
+
+    /**
+     * 修改采购需求物资类
+     * 
+     * @param pmDemandMaterials 采购需求物资类
+     * @return 结果
+     */
+    public int updatePmDemandMaterials(PmDemandMaterials pmDemandMaterials);
+
+
+}

+ 48 - 0
purchase-system/src/main/java/com/ozs/pm/mapper/PmDemandServeMapper.java

@@ -0,0 +1,48 @@
+package com.ozs.pm.mapper;
+
+import com.ozs.pm.doman.PmDemandServe;
+
+import java.util.List;
+
+/**
+ * 采购需求服务类Mapper接口
+ * 
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+public interface PmDemandServeMapper 
+{
+    /**
+     * 查询采购需求服务类
+     * 
+     * @param demandServeId 采购需求服务类主键
+     * @return 采购需求服务类
+     */
+    public PmDemandServe selectPmDemandServeByDemandServeId(Long demandServeId);
+
+    /**
+     * 查询采购需求服务类列表
+     * 
+     * @param pmDemandServe 采购需求服务类
+     * @return 采购需求服务类集合
+     */
+    public List<PmDemandServe> selectPmDemandServeList(PmDemandServe pmDemandServe);
+
+    /**
+     * 新增采购需求服务类
+     * 
+     * @param pmDemandServe 采购需求服务类
+     * @return 结果
+     */
+    public int insertPmDemandServe(PmDemandServe pmDemandServe);
+
+    /**
+     * 修改采购需求服务类
+     * 
+     * @param pmDemandServe 采购需求服务类
+     * @return 结果
+     */
+    public int updatePmDemandServe(PmDemandServe pmDemandServe);
+
+
+}

+ 48 - 0
purchase-system/src/main/java/com/ozs/pm/service/IPmDemandEngineeringService.java

@@ -0,0 +1,48 @@
+package com.ozs.pm.service;
+
+import com.ozs.pm.doman.PmDemandEngineering;
+
+import java.util.List;
+
+
+/**
+ * 采购需求工程类Service接口
+ * 
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+public interface IPmDemandEngineeringService 
+{
+    /**
+     * 查询采购需求工程类
+     * 
+     * @param demandEngineeringId 采购需求工程类主键
+     * @return 采购需求工程类
+     */
+    public PmDemandEngineering selectPmDemandEngineeringByDemandEngineeringId(Long demandEngineeringId);
+
+    /**
+     * 查询采购需求工程类列表
+     * 
+     * @param pmDemandEngineering 采购需求工程类
+     * @return 采购需求工程类集合
+     */
+    public List<PmDemandEngineering> selectPmDemandEngineeringList(PmDemandEngineering pmDemandEngineering);
+
+    /**
+     * 新增采购需求工程类
+     * 
+     * @param pmDemandEngineering 采购需求工程类
+     * @return 结果
+     */
+    public int insertPmDemandEngineering(PmDemandEngineering pmDemandEngineering);
+
+    /**
+     * 修改采购需求工程类
+     * 
+     * @param pmDemandEngineering 采购需求工程类
+     * @return 结果
+     */
+    public int updatePmDemandEngineering(PmDemandEngineering pmDemandEngineering);
+
+}

+ 47 - 0
purchase-system/src/main/java/com/ozs/pm/service/IPmDemandEquipService.java

@@ -0,0 +1,47 @@
+package com.ozs.pm.service;
+
+import com.ozs.pm.doman.PmDemandEquip;
+
+import java.util.List;
+
+/**
+ * 采购需求装备类Service接口
+ * 
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+public interface IPmDemandEquipService 
+{
+    /**
+     * 查询采购需求装备类
+     * 
+     * @param demandEquipId 采购需求装备类主键
+     * @return 采购需求装备类
+     */
+    public PmDemandEquip selectPmDemandEquipByDemandEquipId(Long demandEquipId);
+
+    /**
+     * 查询采购需求装备类列表
+     * 
+     * @param pmDemandEquip 采购需求装备类
+     * @return 采购需求装备类集合
+     */
+    public List<PmDemandEquip> selectPmDemandEquipList(PmDemandEquip pmDemandEquip);
+
+    /**
+     * 新增采购需求装备类
+     * 
+     * @param pmDemandEquip 采购需求装备类
+     * @return 结果
+     */
+    public int insertPmDemandEquip(PmDemandEquip pmDemandEquip);
+
+    /**
+     * 修改采购需求装备类
+     * 
+     * @param pmDemandEquip 采购需求装备类
+     * @return 结果
+     */
+    public int updatePmDemandEquip(PmDemandEquip pmDemandEquip);
+
+}

+ 48 - 0
purchase-system/src/main/java/com/ozs/pm/service/IPmDemandMaterialsService.java

@@ -0,0 +1,48 @@
+package com.ozs.pm.service;
+
+import com.ozs.pm.doman.PmDemandMaterials;
+
+import java.util.List;
+
+/**
+ * 采购需求物资类Service接口
+ * 
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+public interface IPmDemandMaterialsService 
+{
+    /**
+     * 查询采购需求物资类
+     * 
+     * @param demandMaterialsId 采购需求物资类主键
+     * @return 采购需求物资类
+     */
+    public PmDemandMaterials selectPmDemandMaterialsByDemandMaterialsId(Long demandMaterialsId);
+
+    /**
+     * 查询采购需求物资类列表
+     * 
+     * @param pmDemandMaterials 采购需求物资类
+     * @return 采购需求物资类集合
+     */
+    public List<PmDemandMaterials> selectPmDemandMaterialsList(PmDemandMaterials pmDemandMaterials);
+
+    /**
+     * 新增采购需求物资类
+     * 
+     * @param pmDemandMaterials 采购需求物资类
+     * @return 结果
+     */
+    public int insertPmDemandMaterials(PmDemandMaterials pmDemandMaterials);
+
+    /**
+     * 修改采购需求物资类
+     * 
+     * @param pmDemandMaterials 采购需求物资类
+     * @return 结果
+     */
+    public int updatePmDemandMaterials(PmDemandMaterials pmDemandMaterials);
+
+
+}

+ 49 - 0
purchase-system/src/main/java/com/ozs/pm/service/IPmDemandServeService.java

@@ -0,0 +1,49 @@
+package com.ozs.pm.service;
+
+import com.ozs.pm.doman.PmDemandServe;
+
+import java.util.List;
+
+
+/**
+ * 采购需求服务类Service接口
+ * 
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+public interface IPmDemandServeService 
+{
+    /**
+     * 查询采购需求服务类
+     * 
+     * @param demandServeId 采购需求服务类主键
+     * @return 采购需求服务类
+     */
+    public PmDemandServe selectPmDemandServeByDemandServeId(Long demandServeId);
+
+    /**
+     * 查询采购需求服务类列表
+     * 
+     * @param pmDemandServe 采购需求服务类
+     * @return 采购需求服务类集合
+     */
+    public List<PmDemandServe> selectPmDemandServeList(PmDemandServe pmDemandServe);
+
+    /**
+     * 新增采购需求服务类
+     * 
+     * @param pmDemandServe 采购需求服务类
+     * @return 结果
+     */
+    public int insertPmDemandServe(PmDemandServe pmDemandServe);
+
+    /**
+     * 修改采购需求服务类
+     * 
+     * @param pmDemandServe 采购需求服务类
+     * @return 结果
+     */
+    public int updatePmDemandServe(PmDemandServe pmDemandServe);
+
+
+}

+ 51 - 0
purchase-system/src/main/java/com/ozs/pm/service/IPmDemandService.java

@@ -0,0 +1,51 @@
+package com.ozs.pm.service;
+
+import com.ozs.pm.doman.PmDemand;
+import com.ozs.pm.doman.vo.requestVo.PmRequestVo;
+import com.ozs.pm.doman.vo.responseVo.PmDemandResponseVo;
+
+import java.util.List;
+
+
+/**
+ * 采购需求Service接口
+ * 
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+public interface IPmDemandService 
+{
+    /**
+     * 查询采购需求
+     * 
+     * @param demandId 采购需求主键
+     * @return 采购需求
+     */
+    public PmDemandResponseVo selectPmDemandByDemandId(Long demandId);
+
+    /**
+     * 查询采购需求列表
+     * 
+     * @param pmDemand 采购需求
+     * @return 采购需求集合
+     */
+    public List<PmDemandResponseVo> selectPmDemandList(PmRequestVo pmDemand);
+
+    /**
+     * 新增采购需求
+     * 
+     * @param pmDemand 采购需求
+     * @return 结果
+     */
+    public int insertPmDemand(PmDemand pmDemand);
+
+    /**
+     * 修改采购需求
+     * 
+     * @param pmDemand 采购需求
+     * @return 结果
+     */
+    public int updatePmDemand(PmDemand pmDemand);
+
+
+}

+ 74 - 0
purchase-system/src/main/java/com/ozs/pm/service/impl/PmDemandEngineeringServiceImpl.java

@@ -0,0 +1,74 @@
+package com.ozs.pm.service.impl;
+
+import java.util.List;
+import com.ozs.common.utils.DateUtils;
+import com.ozs.pm.doman.PmDemandEngineering;
+import com.ozs.pm.mapper.PmDemandEngineeringMapper;
+import com.ozs.pm.service.IPmDemandEngineeringService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+
+/**
+ * 采购需求工程类Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Service
+public class PmDemandEngineeringServiceImpl implements IPmDemandEngineeringService
+{
+    @Autowired
+    private PmDemandEngineeringMapper pmDemandEngineeringMapper;
+
+    /**
+     * 查询采购需求工程类
+     *
+     * @param demandEngineeringId 采购需求工程类主键
+     * @return 采购需求工程类
+     */
+    @Override
+    public PmDemandEngineering selectPmDemandEngineeringByDemandEngineeringId(Long demandEngineeringId)
+    {
+        return pmDemandEngineeringMapper.selectPmDemandEngineeringByDemandEngineeringId(demandEngineeringId);
+    }
+
+    /**
+     * 查询采购需求工程类列表
+     *
+     * @param pmDemandEngineering 采购需求工程类
+     * @return 采购需求工程类
+     */
+    @Override
+    public List<PmDemandEngineering> selectPmDemandEngineeringList(PmDemandEngineering pmDemandEngineering)
+    {
+        return pmDemandEngineeringMapper.selectPmDemandEngineeringList(pmDemandEngineering);
+    }
+
+    /**
+     * 新增采购需求工程类
+     *
+     * @param pmDemandEngineering 采购需求工程类
+     * @return 结果
+     */
+    @Override
+    public int insertPmDemandEngineering(PmDemandEngineering pmDemandEngineering)
+    {
+        pmDemandEngineering.setCreateTime(DateUtils.getNowDate());
+        return pmDemandEngineeringMapper.insertPmDemandEngineering(pmDemandEngineering);
+    }
+
+    /**
+     * 修改采购需求工程类
+     *
+     * @param pmDemandEngineering 采购需求工程类
+     * @return 结果
+     */
+    @Override
+    public int updatePmDemandEngineering(PmDemandEngineering pmDemandEngineering)
+    {
+        pmDemandEngineering.setUpdateTime(DateUtils.getNowDate());
+        return pmDemandEngineeringMapper.updatePmDemandEngineering(pmDemandEngineering);
+    }
+
+}

+ 75 - 0
purchase-system/src/main/java/com/ozs/pm/service/impl/PmDemandEquipServiceImpl.java

@@ -0,0 +1,75 @@
+package com.ozs.pm.service.impl;
+
+import java.util.List;
+import com.ozs.common.utils.DateUtils;
+import com.ozs.pm.doman.PmDemandEquip;
+import com.ozs.pm.mapper.PmDemandEquipMapper;
+import com.ozs.pm.service.IPmDemandEquipService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+
+/**
+ * 采购需求装备类Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Service
+public class PmDemandEquipServiceImpl implements IPmDemandEquipService
+{
+    @Autowired
+    private PmDemandEquipMapper pmDemandEquipMapper;
+
+    /**
+     * 查询采购需求装备类
+     *
+     * @param demandEquipId 采购需求装备类主键
+     * @return 采购需求装备类
+     */
+    @Override
+    public PmDemandEquip selectPmDemandEquipByDemandEquipId(Long demandEquipId)
+    {
+        return pmDemandEquipMapper.selectPmDemandEquipByDemandEquipId(demandEquipId);
+    }
+
+    /**
+     * 查询采购需求装备类列表
+     *
+     * @param pmDemandEquip 采购需求装备类
+     * @return 采购需求装备类
+     */
+    @Override
+    public List<PmDemandEquip> selectPmDemandEquipList(PmDemandEquip pmDemandEquip)
+    {
+        return pmDemandEquipMapper.selectPmDemandEquipList(pmDemandEquip);
+    }
+
+    /**
+     * 新增采购需求装备类
+     *
+     * @param pmDemandEquip 采购需求装备类
+     * @return 结果
+     */
+    @Override
+    public int insertPmDemandEquip(PmDemandEquip pmDemandEquip)
+    {
+        pmDemandEquip.setCreateTime(DateUtils.getNowDate());
+        return pmDemandEquipMapper.insertPmDemandEquip(pmDemandEquip);
+    }
+
+    /**
+     * 修改采购需求装备类
+     *
+     * @param pmDemandEquip 采购需求装备类
+     * @return 结果
+     */
+    @Override
+    public int updatePmDemandEquip(PmDemandEquip pmDemandEquip)
+    {
+        pmDemandEquip.setUpdateTime(DateUtils.getNowDate());
+        return pmDemandEquipMapper.updatePmDemandEquip(pmDemandEquip);
+    }
+
+
+}

+ 74 - 0
purchase-system/src/main/java/com/ozs/pm/service/impl/PmDemandMaterialsServiceImpl.java

@@ -0,0 +1,74 @@
+package com.ozs.pm.service.impl;
+
+import java.util.List;
+import com.ozs.common.utils.DateUtils;
+import com.ozs.pm.doman.PmDemandMaterials;
+import com.ozs.pm.mapper.PmDemandMaterialsMapper;
+import com.ozs.pm.service.IPmDemandMaterialsService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+
+/**
+ * 采购需求物资类Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Service
+public class PmDemandMaterialsServiceImpl implements IPmDemandMaterialsService
+{
+    @Autowired
+    private PmDemandMaterialsMapper pmDemandMaterialsMapper;
+
+    /**
+     * 查询采购需求物资类
+     *
+     * @param demandMaterialsId 采购需求物资类主键
+     * @return 采购需求物资类
+     */
+    @Override
+    public PmDemandMaterials selectPmDemandMaterialsByDemandMaterialsId(Long demandMaterialsId)
+    {
+        return pmDemandMaterialsMapper.selectPmDemandMaterialsByDemandMaterialsId(demandMaterialsId);
+    }
+
+    /**
+     * 查询采购需求物资类列表
+     *
+     * @param pmDemandMaterials 采购需求物资类
+     * @return 采购需求物资类
+     */
+    @Override
+    public List<PmDemandMaterials> selectPmDemandMaterialsList(PmDemandMaterials pmDemandMaterials)
+    {
+        return pmDemandMaterialsMapper.selectPmDemandMaterialsList(pmDemandMaterials);
+    }
+
+    /**
+     * 新增采购需求物资类
+     *
+     * @param pmDemandMaterials 采购需求物资类
+     * @return 结果
+     */
+    @Override
+    public int insertPmDemandMaterials(PmDemandMaterials pmDemandMaterials)
+    {
+        pmDemandMaterials.setCreateTime(DateUtils.getNowDate());
+        return pmDemandMaterialsMapper.insertPmDemandMaterials(pmDemandMaterials);
+    }
+
+    /**
+     * 修改采购需求物资类
+     *
+     * @param pmDemandMaterials 采购需求物资类
+     * @return 结果
+     */
+    @Override
+    public int updatePmDemandMaterials(PmDemandMaterials pmDemandMaterials)
+    {
+        pmDemandMaterials.setUpdateTime(DateUtils.getNowDate());
+        return pmDemandMaterialsMapper.updatePmDemandMaterials(pmDemandMaterials);
+    }
+
+}

+ 75 - 0
purchase-system/src/main/java/com/ozs/pm/service/impl/PmDemandServeServiceImpl.java

@@ -0,0 +1,75 @@
+package com.ozs.pm.service.impl;
+
+import java.util.List;
+import com.ozs.common.utils.DateUtils;
+import com.ozs.pm.doman.PmDemandServe;
+import com.ozs.pm.mapper.PmDemandServeMapper;
+import com.ozs.pm.service.IPmDemandServeService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+
+/**
+ * 采购需求服务类Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Service
+public class PmDemandServeServiceImpl implements IPmDemandServeService
+{
+    @Autowired
+    private PmDemandServeMapper pmDemandServeMapper;
+
+    /**
+     * 查询采购需求服务类
+     *
+     * @param demandServeId 采购需求服务类主键
+     * @return 采购需求服务类
+     */
+    @Override
+    public PmDemandServe selectPmDemandServeByDemandServeId(Long demandServeId)
+    {
+        return pmDemandServeMapper.selectPmDemandServeByDemandServeId(demandServeId);
+    }
+
+    /**
+     * 查询采购需求服务类列表
+     *
+     * @param pmDemandServe 采购需求服务类
+     * @return 采购需求服务类
+     */
+    @Override
+    public List<PmDemandServe> selectPmDemandServeList(PmDemandServe pmDemandServe)
+    {
+        return pmDemandServeMapper.selectPmDemandServeList(pmDemandServe);
+    }
+
+    /**
+     * 新增采购需求服务类
+     *
+     * @param pmDemandServe 采购需求服务类
+     * @return 结果
+     */
+    @Override
+    public int insertPmDemandServe(PmDemandServe pmDemandServe)
+    {
+        pmDemandServe.setCreateTime(DateUtils.getNowDate());
+        return pmDemandServeMapper.insertPmDemandServe(pmDemandServe);
+    }
+
+    /**
+     * 修改采购需求服务类
+     *
+     * @param pmDemandServe 采购需求服务类
+     * @return 结果
+     */
+    @Override
+    public int updatePmDemandServe(PmDemandServe pmDemandServe)
+    {
+        pmDemandServe.setUpdateTime(DateUtils.getNowDate());
+        return pmDemandServeMapper.updatePmDemandServe(pmDemandServe);
+    }
+
+
+}

+ 103 - 0
purchase-system/src/main/java/com/ozs/pm/service/impl/PmDemandServiceImpl.java

@@ -0,0 +1,103 @@
+package com.ozs.pm.service.impl;
+
+import java.util.*;
+
+import com.ozs.common.utils.DateUtils;
+import com.ozs.common.utils.bean.BeanUtils;
+import com.ozs.pm.doman.PmDemand;
+import com.ozs.pm.doman.vo.requestVo.PmRequestVo;
+import com.ozs.pm.doman.vo.responseVo.PmDemandResponseVo;
+import com.ozs.pm.mapper.PmDemandMapper;
+import com.ozs.pm.service.IPmDemandService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+
+/**
+ * 采购需求Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2023-01-16
+ */
+@Service
+public class PmDemandServiceImpl implements IPmDemandService
+{
+    @Autowired
+    private PmDemandMapper pmDemandMapper;
+
+    /**
+     * 查询采购需求
+     *
+     * @param demandId 采购需求主键
+     * @return 采购需求
+     */
+    @Override
+    public PmDemandResponseVo selectPmDemandByDemandId(Long demandId)
+    {
+        PmDemand pmDemand = pmDemandMapper.selectPmDemandByDemandId(demandId);
+        if(pmDemand != null){
+            PmDemandResponseVo vo = new PmDemandResponseVo();
+            BeanUtils.copyProperties(pmDemand, vo);
+
+            return vo;
+        } else {
+            return null;
+        }
+    }
+
+    /**
+     * 查询采购需求列表
+     *
+     * @param requestVo
+     * @return 采购需求
+     */
+    @Override
+    public List<PmDemandResponseVo> selectPmDemandList(PmRequestVo requestVo)
+    {
+        PmDemand pmDemand = new PmDemand();
+        pmDemand.setProjectName(requestVo.getProjectName());
+        pmDemand.setPurchaseServices(requestVo.getPurchaseServiceStation());
+        pmDemand.setProjectStatus(requestVo.getProjectStatus());
+        Map<String,Object> params = new HashMap<>();
+        params.put("beginDate",requestVo.getBeginDate());
+        params.put("endDate",requestVo.getEndDate());
+        pmDemand.setParams(params);
+        List<PmDemand> pmDemandList = pmDemandMapper.selectPmDemandList(pmDemand);
+        List<PmDemandResponseVo> pmDemandResponseVoList = new ArrayList<>();
+        if(pmDemandList != null && !pmDemandList.isEmpty()){
+            for(PmDemand pmDemand1 : pmDemandList){
+                PmDemandResponseVo vo = new PmDemandResponseVo();
+                BeanUtils.copyBeanProp(pmDemand1,vo);
+                pmDemandResponseVoList.add(vo);
+            }
+        }
+        return pmDemandResponseVoList;
+    }
+
+    /**
+     * 新增采购需求
+     *
+     * @param pmDemand 采购需求
+     * @return 结果
+     */
+    @Override
+    public int insertPmDemand(PmDemand pmDemand)
+    {
+        pmDemand.setCreateTime(DateUtils.getNowDate());
+        return pmDemandMapper.insertPmDemand(pmDemand);
+    }
+
+    /**
+     * 修改采购需求
+     *
+     * @param pmDemand 采购需求
+     * @return 结果
+     */
+    @Override
+    public int updatePmDemand(PmDemand pmDemand)
+    {
+        pmDemand.setUpdateTime(DateUtils.getNowDate());
+        return pmDemandMapper.updatePmDemand(pmDemand);
+    }
+
+}

La diferencia del archivo ha sido suprimido porque es demasiado grande
+ 172 - 0
purchase-system/src/main/resources/mapper/pm/PmDemandEngineeringMapper.xml


+ 117 - 0
purchase-system/src/main/resources/mapper/pm/PmDemandEquipMapper.xml

@@ -0,0 +1,117 @@
+<?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="com.ozs.pm.mapper.PmDemandEquipMapper">
+    
+    <resultMap type="com.ozs.pm.doman.PmDemandEquip" id="PmDemandEquipResult">
+        <result property="demandEquipId"    column="demand_equip_id"    />
+        <result property="demandId"    column="demand_id"    />
+        <result property="typeAndName"    column="type_and_name"    />
+        <result property="specification"    column="specification"    />
+        <result property="qualityTechnicalStandard"    column="quality_technical_standard"    />
+        <result property="measurementUnit"    column="measurement_unit"    />
+        <result property="procurementQuantity"    column="procurement_quantity"    />
+        <result property="price"    column="price"    />
+        <result property="budgetAmount"    column="budget_amount"    />
+        <result property="demandCommitTime"    column="demand_commit_time"    />
+        <result property="procurementMethodSuggest"    column="procurement_method_suggest"    />
+        <result property="remarks"    column="remarks"    />
+        <result property="projectFiles"    column="project_files"    />
+        <result property="createBy"    column="create_by"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="updateBy"    column="update_by"    />
+        <result property="updateTime"    column="update_time"    />
+    </resultMap>
+
+    <sql id="selectPmDemandEquipVo">
+        select demand_equip_id, demand_id, type_and_name, specification, quality_technical_standard, measurement_unit, procurement_quantity, price, budget_amount, demand_commit_time, procurement_method_suggest, remarks, project_files, create_by, create_time, update_by, update_time from pm_demand_equip
+    </sql>
+
+    <select id="selectPmDemandEquipList" parameterType="com.ozs.pm.doman.PmDemandEquip" resultMap="PmDemandEquipResult">
+        <include refid="selectPmDemandEquipVo"/>
+        <where>  
+            <if test="demandId != null "> and demand_id = #{demandId}</if>
+            <if test="typeAndName != null  and typeAndName != ''"> and type_and_name like concat('%', #{typeAndName}, '%')</if>
+            <if test="specification != null  and specification != ''"> and specification = #{specification}</if>
+            <if test="qualityTechnicalStandard != null  and qualityTechnicalStandard != ''"> and quality_technical_standard = #{qualityTechnicalStandard}</if>
+            <if test="measurementUnit != null  and measurementUnit != ''"> and measurement_unit = #{measurementUnit}</if>
+            <if test="procurementQuantity != null "> and procurement_quantity = #{procurementQuantity}</if>
+            <if test="price != null "> and price = #{price}</if>
+            <if test="budgetAmount != null "> and budget_amount = #{budgetAmount}</if>
+            <if test="demandCommitTime != null "> and demand_commit_time = #{demandCommitTime}</if>
+            <if test="procurementMethodSuggest != null  and procurementMethodSuggest != ''"> and procurement_method_suggest = #{procurementMethodSuggest}</if>
+            <if test="remarks != null  and remarks != ''"> and remarks = #{remarks}</if>
+            <if test="projectFiles != null  and projectFiles != ''"> and project_files = #{projectFiles}</if>
+        </where>
+    </select>
+    
+    <select id="selectPmDemandEquipByDemandEquipId" parameterType="Long" resultMap="PmDemandEquipResult">
+        <include refid="selectPmDemandEquipVo"/>
+        where demand_equip_id = #{demandEquipId}
+    </select>
+        
+    <insert id="insertPmDemandEquip" parameterType="com.ozs.pm.doman.PmDemandEquip" useGeneratedKeys="true" keyProperty="demandEquipId">
+        insert into pm_demand_equip
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="demandId != null">demand_id,</if>
+            <if test="typeAndName != null">type_and_name,</if>
+            <if test="specification != null">specification,</if>
+            <if test="qualityTechnicalStandard != null">quality_technical_standard,</if>
+            <if test="measurementUnit != null and measurementUnit != ''">measurement_unit,</if>
+            <if test="procurementQuantity != null">procurement_quantity,</if>
+            <if test="price != null">price,</if>
+            <if test="budgetAmount != null">budget_amount,</if>
+            <if test="demandCommitTime != null">demand_commit_time,</if>
+            <if test="procurementMethodSuggest != null">procurement_method_suggest,</if>
+            <if test="remarks != null">remarks,</if>
+            <if test="projectFiles != null">project_files,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="demandId != null">#{demandId},</if>
+            <if test="typeAndName != null">#{typeAndName},</if>
+            <if test="specification != null">#{specification},</if>
+            <if test="qualityTechnicalStandard != null">#{qualityTechnicalStandard},</if>
+            <if test="measurementUnit != null and measurementUnit != ''">#{measurementUnit},</if>
+            <if test="procurementQuantity != null">#{procurementQuantity},</if>
+            <if test="price != null">#{price},</if>
+            <if test="budgetAmount != null">#{budgetAmount},</if>
+            <if test="demandCommitTime != null">#{demandCommitTime},</if>
+            <if test="procurementMethodSuggest != null">#{procurementMethodSuggest},</if>
+            <if test="remarks != null">#{remarks},</if>
+            <if test="projectFiles != null">#{projectFiles},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+         </trim>
+    </insert>
+
+    <update id="updatePmDemandEquip" parameterType="com.ozs.pm.doman.PmDemandEquip">
+        update pm_demand_equip
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="demandId != null">demand_id = #{demandId},</if>
+            <if test="typeAndName != null">type_and_name = #{typeAndName},</if>
+            <if test="specification != null">specification = #{specification},</if>
+            <if test="qualityTechnicalStandard != null">quality_technical_standard = #{qualityTechnicalStandard},</if>
+            <if test="measurementUnit != null and measurementUnit != ''">measurement_unit = #{measurementUnit},</if>
+            <if test="procurementQuantity != null">procurement_quantity = #{procurementQuantity},</if>
+            <if test="price != null">price = #{price},</if>
+            <if test="budgetAmount != null">budget_amount = #{budgetAmount},</if>
+            <if test="demandCommitTime != null">demand_commit_time = #{demandCommitTime},</if>
+            <if test="procurementMethodSuggest != null">procurement_method_suggest = #{procurementMethodSuggest},</if>
+            <if test="remarks != null">remarks = #{remarks},</if>
+            <if test="projectFiles != null">project_files = #{projectFiles},</if>
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+        </trim>
+        where demand_equip_id = #{demandEquipId}
+    </update>
+
+</mapper>

+ 186 - 0
purchase-system/src/main/resources/mapper/pm/PmDemandMapper.xml

@@ -0,0 +1,186 @@
+<?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="com.ozs.pm.mapper.PmDemandMapper">
+    
+    <resultMap type="com.ozs.pm.doman.PmDemand" id="PmDemandResult">
+        <result property="demandId"    column="demand_id"    />
+        <result property="planId"    column="plan_id"    />
+        <result property="purchaseDeptId"    column="purchase_dept_id"    />
+        <result property="projectName"    column="project_name"    />
+        <result property="projectType"    column="project_type"    />
+        <result property="demandOverview"    column="demand_overview"    />
+        <result property="evaluation"    column="evaluation"    />
+        <result property="isExcess"    column="is_excess"    />
+        <result property="purchaseServices"    column="purchase_services"    />
+        <result property="purchaseMode"    column="purchase_mode"    />
+        <result property="planDemandSubTime"    column="plan_demand_sub_time"    />
+        <result property="planPurchaseFinishTime"    column="plan_purchase_finish_time"    />
+        <result property="planDeliverTime"    column="plan_deliver_time"    />
+        <result property="projectAttr"    column="project_attr"    />
+        <result property="adjustReason"    column="adjust_reason"    />
+        <result property="remarks"    column="remarks"    />
+        <result property="realDemandCommitTime"    column="real_demand_commit_time"    />
+        <result property="realPurchaseFinishTime"    column="real_purchase_finish_time"    />
+        <result property="realDeliverTime"    column="real_deliver_time"    />
+        <result property="auditTime"    column="audit_time"    />
+        <result property="warnStatus"    column="warn_status"    />
+        <result property="projectStatus"    column="project_status"    />
+        <result property="refuseReason"    column="refuse_reason"    />
+        <result property="delayReason"    column="delay_reason"    />
+        <result property="adjustAdvice"    column="adjust_advice"    />
+        <result property="createBy"    column="create_by"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="updateBy"    column="update_by"    />
+        <result property="updateTime"    column="update_time"    />
+    </resultMap>
+
+    <sql id="selectPmDemandVo">
+        select demand_id, plan_id, purchase_dept_id, project_name, project_type, demand_overview, evaluation, is_excess, purchase_services, purchase_mode, plan_demand_sub_time, plan_purchase_finish_time, plan_deliver_time, project_attr, adjust_reason, remarks, real_demand_commit_time, real_purchase_finish_time, real_deliver_time, audit_time, warn_status, project_status, refuse_reason, delay_reason, adjust_advice, create_by, create_time, update_by, update_time from pm_demand
+    </sql>
+
+    <select id="selectPmDemandList" parameterType="com.ozs.pm.doman.PmDemand" resultMap="PmDemandResult">
+        <include refid="selectPmDemandVo"/>
+        <where>  
+            <if test="planId != null "> and plan_id = #{planId}</if>
+            <if test="purchaseDeptId != null "> and purchase_dept_id = #{purchaseDeptId}</if>
+            <if test="projectName != null  and projectName != ''"> and project_name like concat('%', #{projectName}, '%')</if>
+            <if test="projectType != null  and projectType != ''"> and project_type = #{projectType}</if>
+            <if test="demandOverview != null  and demandOverview != ''"> and demand_overview = #{demandOverview}</if>
+            <if test="evaluation != null "> and evaluation = #{evaluation}</if>
+            <if test="isExcess != null "> and is_excess = #{isExcess}</if>
+            <if test="purchaseServices != null  and purchaseServices != ''"> and purchase_services = #{purchaseServices}</if>
+            <if test="purchaseMode != null  and purchaseMode != ''"> and purchase_mode = #{purchaseMode}</if>
+            <if test="planDemandSubTime != null "> and plan_demand_sub_time = #{planDemandSubTime}</if>
+            <if test="planPurchaseFinishTime != null "> and plan_purchase_finish_time = #{planPurchaseFinishTime}</if>
+            <if test="planDeliverTime != null "> and plan_deliver_time = #{planDeliverTime}</if>
+            <if test="projectAttr != null  and projectAttr != ''"> and project_attr = #{projectAttr}</if>
+            <if test="adjustReason != null  and adjustReason != ''"> and adjust_reason = #{adjustReason}</if>
+            <if test="remarks != null  and remarks != ''"> and remarks = #{remarks}</if>
+            <if test="realDemandCommitTime != null "> and real_demand_commit_time = #{realDemandCommitTime}</if>
+            <if test="realPurchaseFinishTime != null "> and real_purchase_finish_time = #{realPurchaseFinishTime}</if>
+            <if test="realDeliverTime != null "> and real_deliver_time = #{realDeliverTime}</if>
+            <if test="auditTime != null "> and audit_time = #{auditTime}</if>
+            <if test="warnStatus != null  and warnStatus != ''"> and warn_status = #{warnStatus}</if>
+            <if test="projectStatus != null "> and project_status = #{projectStatus}</if>
+            <if test="refuseReason != null  and refuseReason != ''"> and refuse_reason = #{refuseReason}</if>
+            <if test="delayReason != null  and delayReason != ''"> and delay_reason = #{delayReason}</if>
+            <if test="adjustAdvice != null  and adjustAdvice != ''"> and adjust_advice = #{adjustAdvice}</if>
+            <if test="params.beginDate != null  and params.beginDate != ''">
+                and
+                (demand_commit_time >= #{params.beginDate} or purchase_finish_time >= #{params.beginDate} or deliver_time >= #{params.beginDate})
+            </if>
+            <if test="params.endDate != null  and params.endDate != ''">
+                and
+                (demand_commit_time &lt;= #{params.endDate} or purchase_finish_time &lt;= #{params.endDate} or deliver_time &lt;= #{params.endDate})
+            </if>
+            <if test="projectFiles != null  and projectFiles != ''"> and project_files = #{projectFiles}</if>
+        </where>
+    </select>
+    
+    <select id="selectPmDemandByDemandId" parameterType="Long" resultMap="PmDemandResult">
+        <include refid="selectPmDemandVo"/>
+        where demand_id = #{demandId}
+    </select>
+        
+    <insert id="insertPmDemand" parameterType="PmDemand" useGeneratedKeys="true" keyProperty="demandId">
+        insert into pm_demand
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="planId != null">plan_id,</if>
+            <if test="purchaseDeptId != null">purchase_dept_id,</if>
+            <if test="projectName != null and projectName != ''">project_name,</if>
+            <if test="projectType != null and projectType != ''">project_type,</if>
+            <if test="demandOverview != null">demand_overview,</if>
+            <if test="evaluation != null">evaluation,</if>
+            <if test="isExcess != null">is_excess,</if>
+            <if test="purchaseServices != null">purchase_services,</if>
+            <if test="purchaseMode != null and purchaseMode != ''">purchase_mode,</if>
+            <if test="planDemandSubTime != null">plan_demand_sub_time,</if>
+            <if test="planPurchaseFinishTime != null">plan_purchase_finish_time,</if>
+            <if test="planDeliverTime != null">plan_deliver_time,</if>
+            <if test="projectAttr != null and projectAttr != ''">project_attr,</if>
+            <if test="adjustReason != null">adjust_reason,</if>
+            <if test="remarks != null">remarks,</if>
+            <if test="realDemandCommitTime != null">real_demand_commit_time,</if>
+            <if test="realPurchaseFinishTime != null">real_purchase_finish_time,</if>
+            <if test="realDeliverTime != null">real_deliver_time,</if>
+            <if test="auditTime != null">audit_time,</if>
+            <if test="warnStatus != null">warn_status,</if>
+            <if test="projectStatus != null">project_status,</if>
+            <if test="refuseReason != null">refuse_reason,</if>
+            <if test="delayReason != null">delay_reason,</if>
+            <if test="adjustAdvice != null">adjust_advice,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="planId != null">#{planId},</if>
+            <if test="purchaseDeptId != null">#{purchaseDeptId},</if>
+            <if test="projectName != null and projectName != ''">#{projectName},</if>
+            <if test="projectType != null and projectType != ''">#{projectType},</if>
+            <if test="demandOverview != null">#{demandOverview},</if>
+            <if test="evaluation != null">#{evaluation},</if>
+            <if test="isExcess != null">#{isExcess},</if>
+            <if test="purchaseServices != null">#{purchaseServices},</if>
+            <if test="purchaseMode != null and purchaseMode != ''">#{purchaseMode},</if>
+            <if test="planDemandSubTime != null">#{planDemandSubTime},</if>
+            <if test="planPurchaseFinishTime != null">#{planPurchaseFinishTime},</if>
+            <if test="planDeliverTime != null">#{planDeliverTime},</if>
+            <if test="projectAttr != null and projectAttr != ''">#{projectAttr},</if>
+            <if test="adjustReason != null">#{adjustReason},</if>
+            <if test="remarks != null">#{remarks},</if>
+            <if test="realDemandCommitTime != null">#{realDemandCommitTime},</if>
+            <if test="realPurchaseFinishTime != null">#{realPurchaseFinishTime},</if>
+            <if test="realDeliverTime != null">#{realDeliverTime},</if>
+            <if test="auditTime != null">#{auditTime},</if>
+            <if test="warnStatus != null">#{warnStatus},</if>
+            <if test="projectStatus != null">#{projectStatus},</if>
+            <if test="refuseReason != null">#{refuseReason},</if>
+            <if test="delayReason != null">#{delayReason},</if>
+            <if test="adjustAdvice != null">#{adjustAdvice},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+         </trim>
+    </insert>
+
+    <update id="updatePmDemand" parameterType="PmDemand">
+        update pm_demand
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="planId != null">plan_id = #{planId},</if>
+            <if test="purchaseDeptId != null">purchase_dept_id = #{purchaseDeptId},</if>
+            <if test="projectName != null and projectName != ''">project_name = #{projectName},</if>
+            <if test="projectType != null and projectType != ''">project_type = #{projectType},</if>
+            <if test="demandOverview != null">demand_overview = #{demandOverview},</if>
+            <if test="evaluation != null">evaluation = #{evaluation},</if>
+            <if test="isExcess != null">is_excess = #{isExcess},</if>
+            <if test="purchaseServices != null">purchase_services = #{purchaseServices},</if>
+            <if test="purchaseMode != null and purchaseMode != ''">purchase_mode = #{purchaseMode},</if>
+            <if test="planDemandSubTime != null">plan_demand_sub_time = #{planDemandSubTime},</if>
+            <if test="planPurchaseFinishTime != null">plan_purchase_finish_time = #{planPurchaseFinishTime},</if>
+            <if test="planDeliverTime != null">plan_deliver_time = #{planDeliverTime},</if>
+            <if test="projectAttr != null and projectAttr != ''">project_attr = #{projectAttr},</if>
+            <if test="adjustReason != null">adjust_reason = #{adjustReason},</if>
+            <if test="remarks != null">remarks = #{remarks},</if>
+            <if test="realDemandCommitTime != null">real_demand_commit_time = #{realDemandCommitTime},</if>
+            <if test="realPurchaseFinishTime != null">real_purchase_finish_time = #{realPurchaseFinishTime},</if>
+            <if test="realDeliverTime != null">real_deliver_time = #{realDeliverTime},</if>
+            <if test="auditTime != null">audit_time = #{auditTime},</if>
+            <if test="warnStatus != null">warn_status = #{warnStatus},</if>
+            <if test="projectStatus != null">project_status = #{projectStatus},</if>
+            <if test="refuseReason != null">refuse_reason = #{refuseReason},</if>
+            <if test="delayReason != null">delay_reason = #{delayReason},</if>
+            <if test="adjustAdvice != null">adjust_advice = #{adjustAdvice},</if>
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+        </trim>
+        where demand_id = #{demandId}
+    </update>
+
+</mapper>

+ 118 - 0
purchase-system/src/main/resources/mapper/pm/PmDemandMaterialsMapper.xml

@@ -0,0 +1,118 @@
+<?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="com.ozs.pm.mapper.PmDemandMaterialsMapper">
+    
+    <resultMap type="com.ozs.pm.doman.PmDemandMaterials" id="PmDemandMaterialsResult">
+        <result property="demandMaterialsId"    column="demand_materials_id"    />
+        <result property="demandId"    column="demand_id"    />
+        <result property="typeAndName"    column="type_and_name"    />
+        <result property="specification"    column="specification"    />
+        <result property="qualityTechnicalStandard"    column="quality_technical_standard"    />
+        <result property="measurementUnit"    column="measurement_unit"    />
+        <result property="procurementQuantity"    column="procurement_quantity"    />
+        <result property="price"    column="price"    />
+        <result property="budgetAmount"    column="budget_amount"    />
+        <result property="demandCommitTime"    column="demand_commit_time"    />
+        <result property="procurementMethodSuggest"    column="procurement_method_suggest"    />
+        <result property="remarks"    column="remarks"    />
+        <result property="projectFiles"    column="project_files"    />
+        <result property="createBy"    column="create_by"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="updateBy"    column="update_by"    />
+        <result property="updateTime"    column="update_time"    />
+    </resultMap>
+
+    <sql id="selectPmDemandMaterialsVo">
+        select demand_materials_id, demand_id, type_and_name, specification, quality_technical_standard, measurement_unit, procurement_quantity, price, budget_amount, demand_commit_time, procurement_method_suggest, remarks, project_files, create_by, create_time, update_by, update_time from pm_demand_materials
+    </sql>
+
+    <select id="selectPmDemandMaterialsList" parameterType="com.ozs.pm.doman.PmDemandMaterials" resultMap="PmDemandMaterialsResult">
+        <include refid="selectPmDemandMaterialsVo"/>
+        <where>  
+            <if test="demandId != null "> and demand_id = #{demandId}</if>
+            <if test="typeAndName != null  and typeAndName != ''"> and type_and_name like concat('%', #{typeAndName}, '%')</if>
+            <if test="specification != null  and specification != ''"> and specification = #{specification}</if>
+            <if test="qualityTechnicalStandard != null  and qualityTechnicalStandard != ''"> and quality_technical_standard = #{qualityTechnicalStandard}</if>
+            <if test="measurementUnit != null  and measurementUnit != ''"> and measurement_unit = #{measurementUnit}</if>
+            <if test="procurementQuantity != null "> and procurement_quantity = #{procurementQuantity}</if>
+            <if test="price != null "> and price = #{price}</if>
+            <if test="budgetAmount != null "> and budget_amount = #{budgetAmount}</if>
+            <if test="demandCommitTime != null "> and demand_commit_time = #{demandCommitTime}</if>
+            <if test="procurementMethodSuggest != null  and procurementMethodSuggest != ''"> and procurement_method_suggest = #{procurementMethodSuggest}</if>
+            <if test="remarks != null  and remarks != ''"> and remarks = #{remarks}</if>
+            <if test="projectFiles != null  and projectFiles != ''"> and project_files = #{projectFiles}</if>
+
+        </where>
+    </select>
+    
+    <select id="selectPmDemandMaterialsByDemandMaterialsId" parameterType="Long" resultMap="PmDemandMaterialsResult">
+        <include refid="selectPmDemandMaterialsVo"/>
+        where demand_materials_id = #{demandMaterialsId}
+    </select>
+        
+    <insert id="insertPmDemandMaterials" parameterType="com.ozs.pm.doman.PmDemandMaterials" useGeneratedKeys="true" keyProperty="demandMaterialsId">
+        insert into pm_demand_materials
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="demandId != null">demand_id,</if>
+            <if test="typeAndName != null">type_and_name,</if>
+            <if test="specification != null">specification,</if>
+            <if test="qualityTechnicalStandard != null">quality_technical_standard,</if>
+            <if test="measurementUnit != null">measurement_unit,</if>
+            <if test="procurementQuantity != null">procurement_quantity,</if>
+            <if test="price != null">price,</if>
+            <if test="budgetAmount != null">budget_amount,</if>
+            <if test="demandCommitTime != null">demand_commit_time,</if>
+            <if test="procurementMethodSuggest != null">procurement_method_suggest,</if>
+            <if test="remarks != null">remarks,</if>
+            <if test="projectFiles != null">project_files,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="demandId != null">#{demandId},</if>
+            <if test="typeAndName != null">#{typeAndName},</if>
+            <if test="specification != null">#{specification},</if>
+            <if test="qualityTechnicalStandard != null">#{qualityTechnicalStandard},</if>
+            <if test="measurementUnit != null">#{measurementUnit},</if>
+            <if test="procurementQuantity != null">#{procurementQuantity},</if>
+            <if test="price != null">#{price},</if>
+            <if test="budgetAmount != null">#{budgetAmount},</if>
+            <if test="demandCommitTime != null">#{demandCommitTime},</if>
+            <if test="procurementMethodSuggest != null">#{procurementMethodSuggest},</if>
+            <if test="remarks != null">#{remarks},</if>
+            <if test="projectFiles != null">#{projectFiles},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+         </trim>
+    </insert>
+
+    <update id="updatePmDemandMaterials" parameterType="com.ozs.pm.doman.PmDemandMaterials">
+        update pm_demand_materials
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="demandId != null">demand_id = #{demandId},</if>
+            <if test="typeAndName != null">type_and_name = #{typeAndName},</if>
+            <if test="specification != null">specification = #{specification},</if>
+            <if test="qualityTechnicalStandard != null">quality_technical_standard = #{qualityTechnicalStandard},</if>
+            <if test="measurementUnit != null">measurement_unit = #{measurementUnit},</if>
+            <if test="procurementQuantity != null">procurement_quantity = #{procurementQuantity},</if>
+            <if test="price != null">price = #{price},</if>
+            <if test="budgetAmount != null">budget_amount = #{budgetAmount},</if>
+            <if test="demandCommitTime != null">demand_commit_time = #{demandCommitTime},</if>
+            <if test="procurementMethodSuggest != null">procurement_method_suggest = #{procurementMethodSuggest},</if>
+            <if test="remarks != null">remarks = #{remarks},</if>
+            <if test="projectFiles != null">project_files = #{projectFiles},</if>
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+        </trim>
+        where demand_materials_id = #{demandMaterialsId}
+    </update>
+
+</mapper>

+ 117 - 0
purchase-system/src/main/resources/mapper/pm/PmDemandServeMapper.xml

@@ -0,0 +1,117 @@
+<?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="com.ozs.pm.mapper.PmDemandServeMapper">
+    
+    <resultMap type="com.ozs.pm.doman.PmDemandServe" id="PmDemandServeResult">
+        <result property="demandServeId"    column="demand_serve_id"    />
+        <result property="demandId"    column="demand_id"    />
+        <result property="serviceName"    column="service_name"    />
+        <result property="technicalServiceRequirement"    column="technical_service_requirement"    />
+        <result property="measurementUnit"    column="measurement_unit"    />
+        <result property="procurementQuantity"    column="procurement_quantity"    />
+        <result property="price"    column="price"    />
+        <result property="budgetAmount"    column="budget_amount"    />
+        <result property="deliveryTimeLimit"    column="delivery_time_limit"    />
+        <result property="procurementMethodSuggest"    column="procurement_method_suggest"    />
+        <result property="supplierId"    column="supplier_id"    />
+        <result property="remarks"    column="remarks"    />
+        <result property="projectFiles"    column="project_files"    />
+        <result property="createBy"    column="create_by"    />
+        <result property="createTime"    column="create_time"    />
+        <result property="updateBy"    column="update_by"    />
+        <result property="updateTime"    column="update_time"    />
+    </resultMap>
+
+    <sql id="selectPmDemandServeVo">
+        select demand_serve_id, demand_id, service_name, technical_service_requirement, measurement_unit, procurement_quantity, price, budget_amount, delivery_time_limit, procurement_method_suggest, supplier_id, remarks, project_files, create_by, create_time, update_by, update_time from pm_demand_serve
+    </sql>
+
+    <select id="selectPmDemandServeList" parameterType="com.ozs.pm.doman.PmDemandServe" resultMap="PmDemandServeResult">
+        <include refid="selectPmDemandServeVo"/>
+        <where>  
+            <if test="demandId != null "> and demand_id = #{demandId}</if>
+            <if test="serviceName != null  and serviceName != ''"> and service_name like concat('%', #{serviceName}, '%')</if>
+            <if test="technicalServiceRequirement != null  and technicalServiceRequirement != ''"> and technical_service_requirement = #{technicalServiceRequirement}</if>
+            <if test="measurementUnit != null  and measurementUnit != ''"> and measurement_unit = #{measurementUnit}</if>
+            <if test="procurementQuantity != null "> and procurement_quantity = #{procurementQuantity}</if>
+            <if test="price != null "> and price = #{price}</if>
+            <if test="budgetAmount != null "> and budget_amount = #{budgetAmount}</if>
+            <if test="deliveryTimeLimit != null  and deliveryTimeLimit != ''"> and delivery_time_limit = #{deliveryTimeLimit}</if>
+            <if test="procurementMethodSuggest != null  and procurementMethodSuggest != ''"> and procurement_method_suggest = #{procurementMethodSuggest}</if>
+            <if test="supplierId != null "> and supplier_id = #{supplierId}</if>
+            <if test="remarks != null  and remarks != ''"> and remarks = #{remarks}</if>
+            <if test="projectFiles != null  and projectFiles != ''"> and project_files = #{projectFiles}</if>
+        </where>
+    </select>
+    
+    <select id="selectPmDemandServeByDemandServeId" parameterType="Long" resultMap="PmDemandServeResult">
+        <include refid="selectPmDemandServeVo"/>
+        where demand_serve_id = #{demandServeId}
+    </select>
+        
+    <insert id="insertPmDemandServe" parameterType="com.ozs.pm.doman.PmDemandServe" useGeneratedKeys="true" keyProperty="demandServeId">
+        insert into pm_demand_serve
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="demandId != null">demand_id,</if>
+            <if test="serviceName != null">service_name,</if>
+            <if test="technicalServiceRequirement != null">technical_service_requirement,</if>
+            <if test="measurementUnit != null">measurement_unit,</if>
+            <if test="procurementQuantity != null">procurement_quantity,</if>
+            <if test="price != null">price,</if>
+            <if test="budgetAmount != null">budget_amount,</if>
+            <if test="deliveryTimeLimit != null">delivery_time_limit,</if>
+            <if test="procurementMethodSuggest != null">procurement_method_suggest,</if>
+            <if test="supplierId != null">supplier_id,</if>
+            <if test="remarks != null">remarks,</if>
+            <if test="projectFiles != null">project_files,</if>
+            <if test="createBy != null">create_by,</if>
+            <if test="createTime != null">create_time,</if>
+            <if test="updateBy != null">update_by,</if>
+            <if test="updateTime != null">update_time,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="demandId != null">#{demandId},</if>
+            <if test="serviceName != null">#{serviceName},</if>
+            <if test="technicalServiceRequirement != null">#{technicalServiceRequirement},</if>
+            <if test="measurementUnit != null">#{measurementUnit},</if>
+            <if test="procurementQuantity != null">#{procurementQuantity},</if>
+            <if test="price != null">#{price},</if>
+            <if test="budgetAmount != null">#{budgetAmount},</if>
+            <if test="deliveryTimeLimit != null">#{deliveryTimeLimit},</if>
+            <if test="procurementMethodSuggest != null">#{procurementMethodSuggest},</if>
+            <if test="supplierId != null">#{supplierId},</if>
+            <if test="remarks != null">#{remarks},</if>
+            <if test="projectFiles != null">#{projectFiles},</if>
+            <if test="createBy != null">#{createBy},</if>
+            <if test="createTime != null">#{createTime},</if>
+            <if test="updateBy != null">#{updateBy},</if>
+            <if test="updateTime != null">#{updateTime},</if>
+         </trim>
+    </insert>
+
+    <update id="updatePmDemandServe" parameterType="com.ozs.pm.doman.PmDemandServe">
+        update pm_demand_serve
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="demandId != null">demand_id = #{demandId},</if>
+            <if test="serviceName != null">service_name = #{serviceName},</if>
+            <if test="technicalServiceRequirement != null">technical_service_requirement = #{technicalServiceRequirement},</if>
+            <if test="measurementUnit != null">measurement_unit = #{measurementUnit},</if>
+            <if test="procurementQuantity != null">procurement_quantity = #{procurementQuantity},</if>
+            <if test="price != null">price = #{price},</if>
+            <if test="budgetAmount != null">budget_amount = #{budgetAmount},</if>
+            <if test="deliveryTimeLimit != null">delivery_time_limit = #{deliveryTimeLimit},</if>
+            <if test="procurementMethodSuggest != null">procurement_method_suggest = #{procurementMethodSuggest},</if>
+            <if test="supplierId != null">supplier_id = #{supplierId},</if>
+            <if test="remarks != null">remarks = #{remarks},</if>
+            <if test="projectFiles != null">project_files = #{projectFiles},</if>
+            <if test="createBy != null">create_by = #{createBy},</if>
+            <if test="createTime != null">create_time = #{createTime},</if>
+            <if test="updateBy != null">update_by = #{updateBy},</if>
+            <if test="updateTime != null">update_time = #{updateTime},</if>
+        </trim>
+        where demand_serve_id = #{demandServeId}
+    </update>
+
+</mapper>