lamphua 7 månader sedan
förälder
incheckning
fead824fc4
22 ändrade filer med 1744 tillägg och 18 borttagningar
  1. 97
    0
      oa-back/ruoyi-admin/src/main/java/com/ruoyi/web/controller/oa/CmcProcureApprovalController.java
  2. 97
    0
      oa-back/ruoyi-admin/src/main/java/com/ruoyi/web/controller/oa/CmcProcurePlanController.java
  3. 210
    0
      oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/domain/CmcProcureApproval.java
  4. 165
    0
      oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/domain/CmcProcurePlan.java
  5. 61
    0
      oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/mapper/CmcProcureApprovalMapper.java
  6. 61
    0
      oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/mapper/CmcProcurePlanMapper.java
  7. 61
    0
      oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/service/ICmcProcureApprovalService.java
  8. 61
    0
      oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/service/ICmcProcurePlanService.java
  9. 93
    0
      oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/service/impl/CmcProcureApprovalServiceImpl.java
  10. 93
    0
      oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/service/impl/CmcProcurePlanServiceImpl.java
  11. 113
    0
      oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcProcureApprovalMapper.xml
  12. 100
    0
      oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcProcurePlanMapper.xml
  13. 1
    1
      oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcTechnicalMapper.xml
  14. 44
    0
      oa-ui/src/api/oa/procure/procureApproval.js
  15. 44
    0
      oa-ui/src/api/oa/procure/procurePlan.js
  16. 8
    8
      oa-ui/src/views/flowable/form/settleForm.vue
  17. 2
    2
      oa-ui/src/views/oa/car/index.vue
  18. 2
    2
      oa-ui/src/views/oa/device/detail.vue
  19. 2
    2
      oa-ui/src/views/oa/device/index.vue
  20. 426
    0
      oa-ui/src/views/oa/procure/approval.vue
  21. 1
    1
      oa-ui/src/views/oa/supply/deviceList.vue
  22. 2
    2
      oa-ui/src/views/oa/supply/index.vue

+ 97
- 0
oa-back/ruoyi-admin/src/main/java/com/ruoyi/web/controller/oa/CmcProcureApprovalController.java Visa fil

@@ -0,0 +1,97 @@
1
+package com.ruoyi.web.controller.oa;
2
+
3
+import java.util.List;
4
+import javax.servlet.http.HttpServletResponse;
5
+import org.springframework.beans.factory.annotation.Autowired;
6
+import org.springframework.web.bind.annotation.GetMapping;
7
+import org.springframework.web.bind.annotation.PostMapping;
8
+import org.springframework.web.bind.annotation.PutMapping;
9
+import org.springframework.web.bind.annotation.DeleteMapping;
10
+import org.springframework.web.bind.annotation.PathVariable;
11
+import org.springframework.web.bind.annotation.RequestBody;
12
+import org.springframework.web.bind.annotation.RequestMapping;
13
+import org.springframework.web.bind.annotation.RestController;
14
+import com.ruoyi.common.annotation.Log;
15
+import com.ruoyi.common.core.controller.BaseController;
16
+import com.ruoyi.common.core.domain.AjaxResult;
17
+import com.ruoyi.common.enums.BusinessType;
18
+import com.ruoyi.oa.domain.CmcProcureApproval;
19
+import com.ruoyi.oa.service.ICmcProcureApprovalService;
20
+import com.ruoyi.common.utils.poi.ExcelUtil;
21
+import com.ruoyi.common.core.page.TableDataInfo;
22
+
23
+/**
24
+ * 采购审批Controller
25
+ * 
26
+ * @author cmc
27
+ * @date 2024-09-18
28
+ */
29
+@RestController
30
+@RequestMapping("/oa/procureApproval")
31
+public class CmcProcureApprovalController extends BaseController
32
+{
33
+    @Autowired
34
+    private ICmcProcureApprovalService cmcProcureApprovalService;
35
+
36
+    /**
37
+     * 查询采购审批列表
38
+     */
39
+    @GetMapping("/list")
40
+    public TableDataInfo list(CmcProcureApproval cmcProcureApproval)
41
+    {
42
+        startPage();
43
+        List<CmcProcureApproval> list = cmcProcureApprovalService.selectCmcProcureApprovalList(cmcProcureApproval);
44
+        return getDataTable(list);
45
+    }
46
+
47
+    /**
48
+     * 导出采购审批列表
49
+     */
50
+    @Log(title = "采购审批", businessType = BusinessType.EXPORT)
51
+    @PostMapping("/export")
52
+    public void export(HttpServletResponse response, CmcProcureApproval cmcProcureApproval)
53
+    {
54
+        List<CmcProcureApproval> list = cmcProcureApprovalService.selectCmcProcureApprovalList(cmcProcureApproval);
55
+        ExcelUtil<CmcProcureApproval> util = new ExcelUtil<CmcProcureApproval>(CmcProcureApproval.class);
56
+        util.exportExcel(response, list, "采购审批数据");
57
+    }
58
+
59
+    /**
60
+     * 获取采购审批详细信息
61
+     */
62
+    @GetMapping(value = "/{procureApplyId}")
63
+    public AjaxResult getInfo(@PathVariable("procureApplyId") String procureApplyId)
64
+    {
65
+        return success(cmcProcureApprovalService.selectCmcProcureApprovalByProcureApplyId(procureApplyId));
66
+    }
67
+
68
+    /**
69
+     * 新增采购审批
70
+     */
71
+    @Log(title = "采购审批", businessType = BusinessType.INSERT)
72
+    @PostMapping
73
+    public AjaxResult add(@RequestBody CmcProcureApproval cmcProcureApproval)
74
+    {
75
+        return toAjax(cmcProcureApprovalService.insertCmcProcureApproval(cmcProcureApproval));
76
+    }
77
+
78
+    /**
79
+     * 修改采购审批
80
+     */
81
+    @Log(title = "采购审批", businessType = BusinessType.UPDATE)
82
+    @PutMapping
83
+    public AjaxResult edit(@RequestBody CmcProcureApproval cmcProcureApproval)
84
+    {
85
+        return toAjax(cmcProcureApprovalService.updateCmcProcureApproval(cmcProcureApproval));
86
+    }
87
+
88
+    /**
89
+     * 删除采购审批
90
+     */
91
+    @Log(title = "采购审批", businessType = BusinessType.DELETE)
92
+	@DeleteMapping("/{procureApplyIds}")
93
+    public AjaxResult remove(@PathVariable String[] procureApplyIds)
94
+    {
95
+        return toAjax(cmcProcureApprovalService.deleteCmcProcureApprovalByProcureApplyIds(procureApplyIds));
96
+    }
97
+}

+ 97
- 0
oa-back/ruoyi-admin/src/main/java/com/ruoyi/web/controller/oa/CmcProcurePlanController.java Visa fil

@@ -0,0 +1,97 @@
1
+package com.ruoyi.web.controller.oa;
2
+
3
+import java.util.List;
4
+import javax.servlet.http.HttpServletResponse;
5
+import org.springframework.beans.factory.annotation.Autowired;
6
+import org.springframework.web.bind.annotation.GetMapping;
7
+import org.springframework.web.bind.annotation.PostMapping;
8
+import org.springframework.web.bind.annotation.PutMapping;
9
+import org.springframework.web.bind.annotation.DeleteMapping;
10
+import org.springframework.web.bind.annotation.PathVariable;
11
+import org.springframework.web.bind.annotation.RequestBody;
12
+import org.springframework.web.bind.annotation.RequestMapping;
13
+import org.springframework.web.bind.annotation.RestController;
14
+import com.ruoyi.common.annotation.Log;
15
+import com.ruoyi.common.core.controller.BaseController;
16
+import com.ruoyi.common.core.domain.AjaxResult;
17
+import com.ruoyi.common.enums.BusinessType;
18
+import com.ruoyi.oa.domain.CmcProcurePlan;
19
+import com.ruoyi.oa.service.ICmcProcurePlanService;
20
+import com.ruoyi.common.utils.poi.ExcelUtil;
21
+import com.ruoyi.common.core.page.TableDataInfo;
22
+
23
+/**
24
+ * 采购计划Controller
25
+ * 
26
+ * @author cmc
27
+ * @date 2024-09-18
28
+ */
29
+@RestController
30
+@RequestMapping("/oa/procurePlan")
31
+public class CmcProcurePlanController extends BaseController
32
+{
33
+    @Autowired
34
+    private ICmcProcurePlanService cmcProcurePlanService;
35
+
36
+    /**
37
+     * 查询采购计划列表
38
+     */
39
+    @GetMapping("/list")
40
+    public TableDataInfo list(CmcProcurePlan cmcProcurePlan)
41
+    {
42
+        startPage();
43
+        List<CmcProcurePlan> list = cmcProcurePlanService.selectCmcProcurePlanList(cmcProcurePlan);
44
+        return getDataTable(list);
45
+    }
46
+
47
+    /**
48
+     * 导出采购计划列表
49
+     */
50
+    @Log(title = "采购计划", businessType = BusinessType.EXPORT)
51
+    @PostMapping("/export")
52
+    public void export(HttpServletResponse response, CmcProcurePlan cmcProcurePlan)
53
+    {
54
+        List<CmcProcurePlan> list = cmcProcurePlanService.selectCmcProcurePlanList(cmcProcurePlan);
55
+        ExcelUtil<CmcProcurePlan> util = new ExcelUtil<CmcProcurePlan>(CmcProcurePlan.class);
56
+        util.exportExcel(response, list, "采购计划数据");
57
+    }
58
+
59
+    /**
60
+     * 获取采购计划详细信息
61
+     */
62
+    @GetMapping(value = "/{procurePlanId}")
63
+    public AjaxResult getInfo(@PathVariable("procurePlanId") Integer procurePlanId)
64
+    {
65
+        return success(cmcProcurePlanService.selectCmcProcurePlanByProcurePlanId(procurePlanId));
66
+    }
67
+
68
+    /**
69
+     * 新增采购计划
70
+     */
71
+    @Log(title = "采购计划", businessType = BusinessType.INSERT)
72
+    @PostMapping
73
+    public AjaxResult add(@RequestBody CmcProcurePlan cmcProcurePlan)
74
+    {
75
+        return toAjax(cmcProcurePlanService.insertCmcProcurePlan(cmcProcurePlan));
76
+    }
77
+
78
+    /**
79
+     * 修改采购计划
80
+     */
81
+    @Log(title = "采购计划", businessType = BusinessType.UPDATE)
82
+    @PutMapping
83
+    public AjaxResult edit(@RequestBody CmcProcurePlan cmcProcurePlan)
84
+    {
85
+        return toAjax(cmcProcurePlanService.updateCmcProcurePlan(cmcProcurePlan));
86
+    }
87
+
88
+    /**
89
+     * 删除采购计划
90
+     */
91
+    @Log(title = "采购计划", businessType = BusinessType.DELETE)
92
+	@DeleteMapping("/{procurePlanIds}")
93
+    public AjaxResult remove(@PathVariable Integer[] procurePlanIds)
94
+    {
95
+        return toAjax(cmcProcurePlanService.deleteCmcProcurePlanByProcurePlanIds(procurePlanIds));
96
+    }
97
+}

+ 210
- 0
oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/domain/CmcProcureApproval.java Visa fil

@@ -0,0 +1,210 @@
1
+package com.ruoyi.oa.domain;
2
+
3
+import java.util.Date;
4
+import com.fasterxml.jackson.annotation.JsonFormat;
5
+import org.apache.commons.lang3.builder.ToStringBuilder;
6
+import org.apache.commons.lang3.builder.ToStringStyle;
7
+import com.ruoyi.common.annotation.Excel;
8
+import com.ruoyi.common.core.domain.BaseEntity;
9
+
10
+/**
11
+ * 采购审批对象 cmc_buy_approval
12
+ * 
13
+ * @author cmc
14
+ * @date 2024-09-18
15
+ */
16
+public class CmcProcureApproval extends BaseEntity
17
+{
18
+    private static final long serialVersionUID = 1L;
19
+
20
+    /** 采购申请id */
21
+    private String buyApplyId;
22
+
23
+    /** 购置说明 */
24
+    @Excel(name = "购置说明")
25
+    private String applyReason;
26
+
27
+    /** 申请人 */
28
+    @Excel(name = "申请人")
29
+    private Long applier;
30
+
31
+    /** 申请部门 */
32
+    @Excel(name = "申请部门")
33
+    private Long applyDept;
34
+
35
+    /** 分管审核人 */
36
+    @Excel(name = "分管审核人")
37
+    private Long managerUserId;
38
+
39
+    /** 分管审核意见 */
40
+    @Excel(name = "分管审核意见")
41
+    private String managerComment;
42
+
43
+    /** 分管审核时间 */
44
+    @JsonFormat(pattern = "yyyy-MM-dd")
45
+    @Excel(name = "分管审核时间", width = 30, dateFormat = "yyyy-MM-dd")
46
+    private Date managerTime;
47
+
48
+    /** 总经理审批人 */
49
+    @Excel(name = "总经理审批人")
50
+    private Long zjlUserId;
51
+
52
+    /** 总经理审批意见 */
53
+    @Excel(name = "总经理审批意见")
54
+    private String zjlComment;
55
+
56
+    /** 总经理审批时间 */
57
+    @JsonFormat(pattern = "yyyy-MM-dd")
58
+    @Excel(name = "总经理审批时间", width = 30, dateFormat = "yyyy-MM-dd")
59
+    private Date zjlTime;
60
+
61
+    /** 计划编制人 */
62
+    @Excel(name = "计划编制人")
63
+    private Long planUserId;
64
+
65
+    /** 计划编制时间 */
66
+    @JsonFormat(pattern = "yyyy-MM-dd")
67
+    @Excel(name = "计划编制时间", width = 30, dateFormat = "yyyy-MM-dd")
68
+    private Date planTime;
69
+
70
+    /** 计划编制意见 */
71
+    @Excel(name = "计划编制意见")
72
+    private String planComment;
73
+
74
+    public void setProcureApplyId(String procureApplyId) 
75
+    {
76
+        this.buyApplyId = buyApplyId;
77
+    }
78
+
79
+    public String getProcureApplyId() 
80
+    {
81
+        return buyApplyId;
82
+    }
83
+    public void setApplyReason(String applyReason) 
84
+    {
85
+        this.applyReason = applyReason;
86
+    }
87
+
88
+    public String getApplyReason() 
89
+    {
90
+        return applyReason;
91
+    }
92
+    public void setApplier(Long applier) 
93
+    {
94
+        this.applier = applier;
95
+    }
96
+
97
+    public Long getApplier() 
98
+    {
99
+        return applier;
100
+    }
101
+    public void setApplyDept(Long applyDept) 
102
+    {
103
+        this.applyDept = applyDept;
104
+    }
105
+
106
+    public Long getApplyDept() 
107
+    {
108
+        return applyDept;
109
+    }
110
+    public void setManagerUserId(Long managerUserId) 
111
+    {
112
+        this.managerUserId = managerUserId;
113
+    }
114
+
115
+    public Long getManagerUserId() 
116
+    {
117
+        return managerUserId;
118
+    }
119
+    public void setManagerComment(String managerComment) 
120
+    {
121
+        this.managerComment = managerComment;
122
+    }
123
+
124
+    public String getManagerComment() 
125
+    {
126
+        return managerComment;
127
+    }
128
+    public void setManagerTime(Date managerTime) 
129
+    {
130
+        this.managerTime = managerTime;
131
+    }
132
+
133
+    public Date getManagerTime() 
134
+    {
135
+        return managerTime;
136
+    }
137
+    public void setZjlUserId(Long zjlUserId) 
138
+    {
139
+        this.zjlUserId = zjlUserId;
140
+    }
141
+
142
+    public Long getZjlUserId() 
143
+    {
144
+        return zjlUserId;
145
+    }
146
+    public void setZjlComment(String zjlComment) 
147
+    {
148
+        this.zjlComment = zjlComment;
149
+    }
150
+
151
+    public String getZjlComment() 
152
+    {
153
+        return zjlComment;
154
+    }
155
+    public void setZjlTime(Date zjlTime) 
156
+    {
157
+        this.zjlTime = zjlTime;
158
+    }
159
+
160
+    public Date getZjlTime() 
161
+    {
162
+        return zjlTime;
163
+    }
164
+    public void setPlanUserId(Long planUserId) 
165
+    {
166
+        this.planUserId = planUserId;
167
+    }
168
+
169
+    public Long getPlanUserId() 
170
+    {
171
+        return planUserId;
172
+    }
173
+    public void setPlanTime(Date planTime) 
174
+    {
175
+        this.planTime = planTime;
176
+    }
177
+
178
+    public Date getPlanTime() 
179
+    {
180
+        return planTime;
181
+    }
182
+    public void setPlanComment(String planComment) 
183
+    {
184
+        this.planComment = planComment;
185
+    }
186
+
187
+    public String getPlanComment() 
188
+    {
189
+        return planComment;
190
+    }
191
+
192
+    @Override
193
+    public String toString() {
194
+        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
195
+            .append("buyApplyId", getProcureApplyId())
196
+            .append("applyReason", getApplyReason())
197
+            .append("applier", getApplier())
198
+            .append("applyDept", getApplyDept())
199
+            .append("managerUserId", getManagerUserId())
200
+            .append("managerComment", getManagerComment())
201
+            .append("managerTime", getManagerTime())
202
+            .append("zjlUserId", getZjlUserId())
203
+            .append("zjlComment", getZjlComment())
204
+            .append("zjlTime", getZjlTime())
205
+            .append("planUserId", getPlanUserId())
206
+            .append("planTime", getPlanTime())
207
+            .append("planComment", getPlanComment())
208
+            .toString();
209
+    }
210
+}

+ 165
- 0
oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/domain/CmcProcurePlan.java Visa fil

@@ -0,0 +1,165 @@
1
+package com.ruoyi.oa.domain;
2
+
3
+import java.math.BigDecimal;
4
+import org.apache.commons.lang3.builder.ToStringBuilder;
5
+import org.apache.commons.lang3.builder.ToStringStyle;
6
+import com.ruoyi.common.annotation.Excel;
7
+import com.ruoyi.common.core.domain.BaseEntity;
8
+
9
+/**
10
+ * 采购计划对象 cmc_procure_plan
11
+ * 
12
+ * @author cmc
13
+ * @date 2024-09-18
14
+ */
15
+public class CmcProcurePlan extends BaseEntity
16
+{
17
+    private static final long serialVersionUID = 1L;
18
+
19
+    /** 采购计划id */
20
+    private Integer procurePlanId;
21
+
22
+    /** 采购申请id */
23
+    @Excel(name = "采购申请id")
24
+    private String procureApplyId;
25
+
26
+    /** 名称 */
27
+    @Excel(name = "名称")
28
+    private String name;
29
+
30
+    /** 规格型号 */
31
+    @Excel(name = "规格型号")
32
+    private String series;
33
+
34
+    /** 单位 */
35
+    @Excel(name = "单位")
36
+    private String unit;
37
+
38
+    /** 参考单价 */
39
+    @Excel(name = "参考单价")
40
+    private BigDecimal price;
41
+
42
+    /** 数量 */
43
+    @Excel(name = "数量")
44
+    private Double num;
45
+
46
+    /** 总价 */
47
+    @Excel(name = "总价")
48
+    private BigDecimal amount;
49
+
50
+    /** 购买方式 */
51
+    @Excel(name = "购买方式")
52
+    private String procureWay;
53
+
54
+    /** 用途 */
55
+    @Excel(name = "用途")
56
+    private String usage;
57
+
58
+    public void setProcurePlanId(Integer procurePlanId) 
59
+    {
60
+        this.procurePlanId = procurePlanId;
61
+    }
62
+
63
+    public Integer getProcurePlanId() 
64
+    {
65
+        return procurePlanId;
66
+    }
67
+    public void setProcureApplyId(String procureApplyId) 
68
+    {
69
+        this.procureApplyId = procureApplyId;
70
+    }
71
+
72
+    public String getProcureApplyId() 
73
+    {
74
+        return procureApplyId;
75
+    }
76
+    public void setName(String name) 
77
+    {
78
+        this.name = name;
79
+    }
80
+
81
+    public String getName() 
82
+    {
83
+        return name;
84
+    }
85
+    public void setSeries(String series) 
86
+    {
87
+        this.series = series;
88
+    }
89
+
90
+    public String getSeries() 
91
+    {
92
+        return series;
93
+    }
94
+    public void setUnit(String unit) 
95
+    {
96
+        this.unit = unit;
97
+    }
98
+
99
+    public String getUnit() 
100
+    {
101
+        return unit;
102
+    }
103
+    public void setPrice(BigDecimal price) 
104
+    {
105
+        this.price = price;
106
+    }
107
+
108
+    public BigDecimal getPrice() 
109
+    {
110
+        return price;
111
+    }
112
+    public void setNum(Double num) 
113
+    {
114
+        this.num = num;
115
+    }
116
+
117
+    public Double getNum() 
118
+    {
119
+        return num;
120
+    }
121
+    public void setAmount(BigDecimal amount) 
122
+    {
123
+        this.amount = amount;
124
+    }
125
+
126
+    public BigDecimal getAmount() 
127
+    {
128
+        return amount;
129
+    }
130
+    public void setProcureWay(String procureWay) 
131
+    {
132
+        this.procureWay = procureWay;
133
+    }
134
+
135
+    public String getProcureWay() 
136
+    {
137
+        return procureWay;
138
+    }
139
+    public void setUsage(String usage) 
140
+    {
141
+        this.usage = usage;
142
+    }
143
+
144
+    public String getUsage() 
145
+    {
146
+        return usage;
147
+    }
148
+
149
+    @Override
150
+    public String toString() {
151
+        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
152
+            .append("procurePlanId", getProcurePlanId())
153
+            .append("procureApplyId", getProcureApplyId())
154
+            .append("name", getName())
155
+            .append("series", getSeries())
156
+            .append("unit", getUnit())
157
+            .append("price", getPrice())
158
+            .append("num", getNum())
159
+            .append("amount", getAmount())
160
+            .append("procureWay", getProcureWay())
161
+            .append("usage", getUsage())
162
+            .append("remark", getRemark())
163
+            .toString();
164
+    }
165
+}

+ 61
- 0
oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/mapper/CmcProcureApprovalMapper.java Visa fil

@@ -0,0 +1,61 @@
1
+package com.ruoyi.oa.mapper;
2
+
3
+import java.util.List;
4
+import com.ruoyi.oa.domain.CmcProcureApproval;
5
+
6
+/**
7
+ * 采购审批Mapper接口
8
+ * 
9
+ * @author cmc
10
+ * @date 2024-09-18
11
+ */
12
+public interface CmcProcureApprovalMapper 
13
+{
14
+    /**
15
+     * 查询采购审批
16
+     * 
17
+     * @param procureApplyId 采购审批主键
18
+     * @return 采购审批
19
+     */
20
+    public CmcProcureApproval selectCmcProcureApprovalByProcureApplyId(String procureApplyId);
21
+
22
+    /**
23
+     * 查询采购审批列表
24
+     * 
25
+     * @param cmcProcureApproval 采购审批
26
+     * @return 采购审批集合
27
+     */
28
+    public List<CmcProcureApproval> selectCmcProcureApprovalList(CmcProcureApproval cmcProcureApproval);
29
+
30
+    /**
31
+     * 新增采购审批
32
+     * 
33
+     * @param cmcProcureApproval 采购审批
34
+     * @return 结果
35
+     */
36
+    public int insertCmcProcureApproval(CmcProcureApproval cmcProcureApproval);
37
+
38
+    /**
39
+     * 修改采购审批
40
+     * 
41
+     * @param cmcProcureApproval 采购审批
42
+     * @return 结果
43
+     */
44
+    public int updateCmcProcureApproval(CmcProcureApproval cmcProcureApproval);
45
+
46
+    /**
47
+     * 删除采购审批
48
+     * 
49
+     * @param procureApplyId 采购审批主键
50
+     * @return 结果
51
+     */
52
+    public int deleteCmcProcureApprovalByProcureApplyId(String procureApplyId);
53
+
54
+    /**
55
+     * 批量删除采购审批
56
+     * 
57
+     * @param procureApplyIds 需要删除的数据主键集合
58
+     * @return 结果
59
+     */
60
+    public int deleteCmcProcureApprovalByProcureApplyIds(String[] procureApplyIds);
61
+}

+ 61
- 0
oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/mapper/CmcProcurePlanMapper.java Visa fil

@@ -0,0 +1,61 @@
1
+package com.ruoyi.oa.mapper;
2
+
3
+import java.util.List;
4
+import com.ruoyi.oa.domain.CmcProcurePlan;
5
+
6
+/**
7
+ * 采购计划Mapper接口
8
+ * 
9
+ * @author cmc
10
+ * @date 2024-09-18
11
+ */
12
+public interface CmcProcurePlanMapper 
13
+{
14
+    /**
15
+     * 查询采购计划
16
+     * 
17
+     * @param procurePlanId 采购计划主键
18
+     * @return 采购计划
19
+     */
20
+    public CmcProcurePlan selectCmcProcurePlanByProcurePlanId(Integer procurePlanId);
21
+
22
+    /**
23
+     * 查询采购计划列表
24
+     * 
25
+     * @param cmcProcurePlan 采购计划
26
+     * @return 采购计划集合
27
+     */
28
+    public List<CmcProcurePlan> selectCmcProcurePlanList(CmcProcurePlan cmcProcurePlan);
29
+
30
+    /**
31
+     * 新增采购计划
32
+     * 
33
+     * @param cmcProcurePlan 采购计划
34
+     * @return 结果
35
+     */
36
+    public int insertCmcProcurePlan(CmcProcurePlan cmcProcurePlan);
37
+
38
+    /**
39
+     * 修改采购计划
40
+     * 
41
+     * @param cmcProcurePlan 采购计划
42
+     * @return 结果
43
+     */
44
+    public int updateCmcProcurePlan(CmcProcurePlan cmcProcurePlan);
45
+
46
+    /**
47
+     * 删除采购计划
48
+     * 
49
+     * @param procurePlanId 采购计划主键
50
+     * @return 结果
51
+     */
52
+    public int deleteCmcProcurePlanByProcurePlanId(Integer procurePlanId);
53
+
54
+    /**
55
+     * 批量删除采购计划
56
+     * 
57
+     * @param procurePlanIds 需要删除的数据主键集合
58
+     * @return 结果
59
+     */
60
+    public int deleteCmcProcurePlanByProcurePlanIds(Integer[] procurePlanIds);
61
+}

+ 61
- 0
oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/service/ICmcProcureApprovalService.java Visa fil

@@ -0,0 +1,61 @@
1
+package com.ruoyi.oa.service;
2
+
3
+import java.util.List;
4
+import com.ruoyi.oa.domain.CmcProcureApproval;
5
+
6
+/**
7
+ * 采购审批Service接口
8
+ * 
9
+ * @author cmc
10
+ * @date 2024-09-18
11
+ */
12
+public interface ICmcProcureApprovalService 
13
+{
14
+    /**
15
+     * 查询采购审批
16
+     * 
17
+     * @param procureApplyId 采购审批主键
18
+     * @return 采购审批
19
+     */
20
+    public CmcProcureApproval selectCmcProcureApprovalByProcureApplyId(String procureApplyId);
21
+
22
+    /**
23
+     * 查询采购审批列表
24
+     * 
25
+     * @param cmcProcureApproval 采购审批
26
+     * @return 采购审批集合
27
+     */
28
+    public List<CmcProcureApproval> selectCmcProcureApprovalList(CmcProcureApproval cmcProcureApproval);
29
+
30
+    /**
31
+     * 新增采购审批
32
+     * 
33
+     * @param cmcProcureApproval 采购审批
34
+     * @return 结果
35
+     */
36
+    public int insertCmcProcureApproval(CmcProcureApproval cmcProcureApproval);
37
+
38
+    /**
39
+     * 修改采购审批
40
+     * 
41
+     * @param cmcProcureApproval 采购审批
42
+     * @return 结果
43
+     */
44
+    public int updateCmcProcureApproval(CmcProcureApproval cmcProcureApproval);
45
+
46
+    /**
47
+     * 批量删除采购审批
48
+     * 
49
+     * @param procureApplyIds 需要删除的采购审批主键集合
50
+     * @return 结果
51
+     */
52
+    public int deleteCmcProcureApprovalByProcureApplyIds(String[] procureApplyIds);
53
+
54
+    /**
55
+     * 删除采购审批信息
56
+     * 
57
+     * @param procureApplyId 采购审批主键
58
+     * @return 结果
59
+     */
60
+    public int deleteCmcProcureApprovalByProcureApplyId(String procureApplyId);
61
+}

+ 61
- 0
oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/service/ICmcProcurePlanService.java Visa fil

@@ -0,0 +1,61 @@
1
+package com.ruoyi.oa.service;
2
+
3
+import java.util.List;
4
+import com.ruoyi.oa.domain.CmcProcurePlan;
5
+
6
+/**
7
+ * 采购计划Service接口
8
+ * 
9
+ * @author cmc
10
+ * @date 2024-09-18
11
+ */
12
+public interface ICmcProcurePlanService 
13
+{
14
+    /**
15
+     * 查询采购计划
16
+     * 
17
+     * @param procurePlanId 采购计划主键
18
+     * @return 采购计划
19
+     */
20
+    public CmcProcurePlan selectCmcProcurePlanByProcurePlanId(Integer procurePlanId);
21
+
22
+    /**
23
+     * 查询采购计划列表
24
+     * 
25
+     * @param cmcProcurePlan 采购计划
26
+     * @return 采购计划集合
27
+     */
28
+    public List<CmcProcurePlan> selectCmcProcurePlanList(CmcProcurePlan cmcProcurePlan);
29
+
30
+    /**
31
+     * 新增采购计划
32
+     * 
33
+     * @param cmcProcurePlan 采购计划
34
+     * @return 结果
35
+     */
36
+    public int insertCmcProcurePlan(CmcProcurePlan cmcProcurePlan);
37
+
38
+    /**
39
+     * 修改采购计划
40
+     * 
41
+     * @param cmcProcurePlan 采购计划
42
+     * @return 结果
43
+     */
44
+    public int updateCmcProcurePlan(CmcProcurePlan cmcProcurePlan);
45
+
46
+    /**
47
+     * 批量删除采购计划
48
+     * 
49
+     * @param procurePlanIds 需要删除的采购计划主键集合
50
+     * @return 结果
51
+     */
52
+    public int deleteCmcProcurePlanByProcurePlanIds(Integer[] procurePlanIds);
53
+
54
+    /**
55
+     * 删除采购计划信息
56
+     * 
57
+     * @param procurePlanId 采购计划主键
58
+     * @return 结果
59
+     */
60
+    public int deleteCmcProcurePlanByProcurePlanId(Integer procurePlanId);
61
+}

+ 93
- 0
oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/service/impl/CmcProcureApprovalServiceImpl.java Visa fil

@@ -0,0 +1,93 @@
1
+package com.ruoyi.oa.service.impl;
2
+
3
+import java.util.List;
4
+import org.springframework.beans.factory.annotation.Autowired;
5
+import org.springframework.stereotype.Service;
6
+import com.ruoyi.oa.mapper.CmcProcureApprovalMapper;
7
+import com.ruoyi.oa.domain.CmcProcureApproval;
8
+import com.ruoyi.oa.service.ICmcProcureApprovalService;
9
+
10
+/**
11
+ * 采购审批Service业务层处理
12
+ * 
13
+ * @author cmc
14
+ * @date 2024-09-18
15
+ */
16
+@Service
17
+public class CmcProcureApprovalServiceImpl implements ICmcProcureApprovalService
18
+{
19
+    @Autowired
20
+    private CmcProcureApprovalMapper cmcProcureApprovalMapper;
21
+
22
+    /**
23
+     * 查询采购审批
24
+     * 
25
+     * @param procureApplyId 采购审批主键
26
+     * @return 采购审批
27
+     */
28
+    @Override
29
+    public CmcProcureApproval selectCmcProcureApprovalByProcureApplyId(String procureApplyId)
30
+    {
31
+        return cmcProcureApprovalMapper.selectCmcProcureApprovalByProcureApplyId(procureApplyId);
32
+    }
33
+
34
+    /**
35
+     * 查询采购审批列表
36
+     * 
37
+     * @param cmcProcureApproval 采购审批
38
+     * @return 采购审批
39
+     */
40
+    @Override
41
+    public List<CmcProcureApproval> selectCmcProcureApprovalList(CmcProcureApproval cmcProcureApproval)
42
+    {
43
+        return cmcProcureApprovalMapper.selectCmcProcureApprovalList(cmcProcureApproval);
44
+    }
45
+
46
+    /**
47
+     * 新增采购审批
48
+     * 
49
+     * @param cmcProcureApproval 采购审批
50
+     * @return 结果
51
+     */
52
+    @Override
53
+    public int insertCmcProcureApproval(CmcProcureApproval cmcProcureApproval)
54
+    {
55
+        return cmcProcureApprovalMapper.insertCmcProcureApproval(cmcProcureApproval);
56
+    }
57
+
58
+    /**
59
+     * 修改采购审批
60
+     * 
61
+     * @param cmcProcureApproval 采购审批
62
+     * @return 结果
63
+     */
64
+    @Override
65
+    public int updateCmcProcureApproval(CmcProcureApproval cmcProcureApproval)
66
+    {
67
+        return cmcProcureApprovalMapper.updateCmcProcureApproval(cmcProcureApproval);
68
+    }
69
+
70
+    /**
71
+     * 批量删除采购审批
72
+     * 
73
+     * @param procureApplyIds 需要删除的采购审批主键
74
+     * @return 结果
75
+     */
76
+    @Override
77
+    public int deleteCmcProcureApprovalByProcureApplyIds(String[] procureApplyIds)
78
+    {
79
+        return cmcProcureApprovalMapper.deleteCmcProcureApprovalByProcureApplyIds(procureApplyIds);
80
+    }
81
+
82
+    /**
83
+     * 删除采购审批信息
84
+     * 
85
+     * @param procureApplyId 采购审批主键
86
+     * @return 结果
87
+     */
88
+    @Override
89
+    public int deleteCmcProcureApprovalByProcureApplyId(String procureApplyId)
90
+    {
91
+        return cmcProcureApprovalMapper.deleteCmcProcureApprovalByProcureApplyId(procureApplyId);
92
+    }
93
+}

+ 93
- 0
oa-back/ruoyi-system/src/main/java/com/ruoyi/oa/service/impl/CmcProcurePlanServiceImpl.java Visa fil

@@ -0,0 +1,93 @@
1
+package com.ruoyi.oa.service.impl;
2
+
3
+import java.util.List;
4
+import org.springframework.beans.factory.annotation.Autowired;
5
+import org.springframework.stereotype.Service;
6
+import com.ruoyi.oa.mapper.CmcProcurePlanMapper;
7
+import com.ruoyi.oa.domain.CmcProcurePlan;
8
+import com.ruoyi.oa.service.ICmcProcurePlanService;
9
+
10
+/**
11
+ * 采购计划Service业务层处理
12
+ * 
13
+ * @author cmc
14
+ * @date 2024-09-18
15
+ */
16
+@Service
17
+public class CmcProcurePlanServiceImpl implements ICmcProcurePlanService
18
+{
19
+    @Autowired
20
+    private CmcProcurePlanMapper cmcProcurePlanMapper;
21
+
22
+    /**
23
+     * 查询采购计划
24
+     * 
25
+     * @param procurePlanId 采购计划主键
26
+     * @return 采购计划
27
+     */
28
+    @Override
29
+    public CmcProcurePlan selectCmcProcurePlanByProcurePlanId(Integer procurePlanId)
30
+    {
31
+        return cmcProcurePlanMapper.selectCmcProcurePlanByProcurePlanId(procurePlanId);
32
+    }
33
+
34
+    /**
35
+     * 查询采购计划列表
36
+     * 
37
+     * @param cmcProcurePlan 采购计划
38
+     * @return 采购计划
39
+     */
40
+    @Override
41
+    public List<CmcProcurePlan> selectCmcProcurePlanList(CmcProcurePlan cmcProcurePlan)
42
+    {
43
+        return cmcProcurePlanMapper.selectCmcProcurePlanList(cmcProcurePlan);
44
+    }
45
+
46
+    /**
47
+     * 新增采购计划
48
+     * 
49
+     * @param cmcProcurePlan 采购计划
50
+     * @return 结果
51
+     */
52
+    @Override
53
+    public int insertCmcProcurePlan(CmcProcurePlan cmcProcurePlan)
54
+    {
55
+        return cmcProcurePlanMapper.insertCmcProcurePlan(cmcProcurePlan);
56
+    }
57
+
58
+    /**
59
+     * 修改采购计划
60
+     * 
61
+     * @param cmcProcurePlan 采购计划
62
+     * @return 结果
63
+     */
64
+    @Override
65
+    public int updateCmcProcurePlan(CmcProcurePlan cmcProcurePlan)
66
+    {
67
+        return cmcProcurePlanMapper.updateCmcProcurePlan(cmcProcurePlan);
68
+    }
69
+
70
+    /**
71
+     * 批量删除采购计划
72
+     * 
73
+     * @param procurePlanIds 需要删除的采购计划主键
74
+     * @return 结果
75
+     */
76
+    @Override
77
+    public int deleteCmcProcurePlanByProcurePlanIds(Integer[] procurePlanIds)
78
+    {
79
+        return cmcProcurePlanMapper.deleteCmcProcurePlanByProcurePlanIds(procurePlanIds);
80
+    }
81
+
82
+    /**
83
+     * 删除采购计划信息
84
+     * 
85
+     * @param procurePlanId 采购计划主键
86
+     * @return 结果
87
+     */
88
+    @Override
89
+    public int deleteCmcProcurePlanByProcurePlanId(Integer procurePlanId)
90
+    {
91
+        return cmcProcurePlanMapper.deleteCmcProcurePlanByProcurePlanId(procurePlanId);
92
+    }
93
+}

+ 113
- 0
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcProcureApprovalMapper.xml Visa fil

@@ -0,0 +1,113 @@
1
+<?xml version="1.0" encoding="UTF-8" ?>
2
+<!DOCTYPE mapper
3
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
4
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
5
+<mapper namespace="com.ruoyi.oa.mapper.CmcProcureApprovalMapper">
6
+    
7
+    <resultMap type="CmcProcureApproval" id="CmcProcureApprovalResult">
8
+        <result property="procureApplyId"    column="procure_apply_id"    />
9
+        <result property="applyReason"    column="apply_reason"    />
10
+        <result property="applier"    column="applier"    />
11
+        <result property="applyDept"    column="apply_dept"    />
12
+        <result property="managerUserId"    column="manager_user_id"    />
13
+        <result property="managerComment"    column="manager_comment"    />
14
+        <result property="managerTime"    column="manager_time"    />
15
+        <result property="zjlUserId"    column="zjl_user_id"    />
16
+        <result property="zjlComment"    column="zjl_comment"    />
17
+        <result property="zjlTime"    column="zjl_time"    />
18
+        <result property="planUserId"    column="plan_user_id"    />
19
+        <result property="planTime"    column="plan_time"    />
20
+        <result property="planComment"    column="plan_comment"    />
21
+    </resultMap>
22
+
23
+    <sql id="selectCmcProcureApprovalVo">
24
+        select procure_apply_id, apply_reason, applier, apply_dept, manager_user_id, manager_comment, manager_time, zjl_user_id, zjl_comment, zjl_time, plan_user_id, plan_time, plan_comment from cmc_procure_approval
25
+    </sql>
26
+
27
+    <select id="selectCmcProcureApprovalList" parameterType="CmcProcureApproval" resultMap="CmcProcureApprovalResult">
28
+        <include refid="selectCmcProcureApprovalVo"/>
29
+        <where>  
30
+            <if test="applyReason != null  and applyReason != ''"> and apply_reason = #{applyReason}</if>
31
+            <if test="applier != null "> and applier = #{applier}</if>
32
+            <if test="applyDept != null "> and apply_dept = #{applyDept}</if>
33
+            <if test="managerUserId != null "> and manager_user_id = #{managerUserId}</if>
34
+            <if test="managerComment != null  and managerComment != ''"> and manager_comment = #{managerComment}</if>
35
+            <if test="managerTime != null "> and manager_time = #{managerTime}</if>
36
+            <if test="zjlUserId != null "> and zjl_user_id = #{zjlUserId}</if>
37
+            <if test="zjlComment != null  and zjlComment != ''"> and zjl_comment = #{zjlComment}</if>
38
+            <if test="zjlTime != null "> and zjl_time = #{zjlTime}</if>
39
+            <if test="planUserId != null "> and plan_user_id = #{planUserId}</if>
40
+            <if test="planTime != null "> and plan_time = #{planTime}</if>
41
+            <if test="planComment != null  and planComment != ''"> and plan_comment = #{planComment}</if>
42
+        </where>
43
+    </select>
44
+    
45
+    <select id="selectCmcProcureApprovalByProcureApplyId" parameterType="String" resultMap="CmcProcureApprovalResult">
46
+        <include refid="selectCmcProcureApprovalVo"/>
47
+        where procure_apply_id = #{procureApplyId}
48
+    </select>
49
+        
50
+    <insert id="insertCmcProcureApproval" parameterType="CmcProcureApproval">
51
+        insert into cmc_procure_approval
52
+        <trim prefix="(" suffix=")" suffixOverrides=",">
53
+            <if test="procureApplyId != null">procure_apply_id,</if>
54
+            <if test="applyReason != null">apply_reason,</if>
55
+            <if test="applier != null">applier,</if>
56
+            <if test="applyDept != null">apply_dept,</if>
57
+            <if test="managerUserId != null">manager_user_id,</if>
58
+            <if test="managerComment != null">manager_comment,</if>
59
+            <if test="managerTime != null">manager_time,</if>
60
+            <if test="zjlUserId != null">zjl_user_id,</if>
61
+            <if test="zjlComment != null">zjl_comment,</if>
62
+            <if test="zjlTime != null">zjl_time,</if>
63
+            <if test="planUserId != null">plan_user_id,</if>
64
+            <if test="planTime != null">plan_time,</if>
65
+            <if test="planComment != null">plan_comment,</if>
66
+         </trim>
67
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
68
+            <if test="procureApplyId != null">#{procureApplyId},</if>
69
+            <if test="applyReason != null">#{applyReason},</if>
70
+            <if test="applier != null">#{applier},</if>
71
+            <if test="applyDept != null">#{applyDept},</if>
72
+            <if test="managerUserId != null">#{managerUserId},</if>
73
+            <if test="managerComment != null">#{managerComment},</if>
74
+            <if test="managerTime != null">#{managerTime},</if>
75
+            <if test="zjlUserId != null">#{zjlUserId},</if>
76
+            <if test="zjlComment != null">#{zjlComment},</if>
77
+            <if test="zjlTime != null">#{zjlTime},</if>
78
+            <if test="planUserId != null">#{planUserId},</if>
79
+            <if test="planTime != null">#{planTime},</if>
80
+            <if test="planComment != null">#{planComment},</if>
81
+         </trim>
82
+    </insert>
83
+
84
+    <update id="updateCmcProcureApproval" parameterType="CmcProcureApproval">
85
+        update cmc_procure_approval
86
+        <trim prefix="SET" suffixOverrides=",">
87
+            <if test="applyReason != null">apply_reason = #{applyReason},</if>
88
+            <if test="applier != null">applier = #{applier},</if>
89
+            <if test="applyDept != null">apply_dept = #{applyDept},</if>
90
+            <if test="managerUserId != null">manager_user_id = #{managerUserId},</if>
91
+            <if test="managerComment != null">manager_comment = #{managerComment},</if>
92
+            <if test="managerTime != null">manager_time = #{managerTime},</if>
93
+            <if test="zjlUserId != null">zjl_user_id = #{zjlUserId},</if>
94
+            <if test="zjlComment != null">zjl_comment = #{zjlComment},</if>
95
+            <if test="zjlTime != null">zjl_time = #{zjlTime},</if>
96
+            <if test="planUserId != null">plan_user_id = #{planUserId},</if>
97
+            <if test="planTime != null">plan_time = #{planTime},</if>
98
+            <if test="planComment != null">plan_comment = #{planComment},</if>
99
+        </trim>
100
+        where procure_apply_id = #{procureApplyId}
101
+    </update>
102
+
103
+    <delete id="deleteCmcProcureApprovalByProcureApplyId" parameterType="String">
104
+        delete from cmc_procure_approval where procure_apply_id = #{procureApplyId}
105
+    </delete>
106
+
107
+    <delete id="deleteCmcProcureApprovalByProcureApplyIds" parameterType="String">
108
+        delete from cmc_procure_approval where procure_apply_id in 
109
+        <foreach item="procureApplyId" collection="array" open="(" separator="," close=")">
110
+            #{procureApplyId}
111
+        </foreach>
112
+    </delete>
113
+</mapper>

+ 100
- 0
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcProcurePlanMapper.xml Visa fil

@@ -0,0 +1,100 @@
1
+<?xml version="1.0" encoding="UTF-8" ?>
2
+<!DOCTYPE mapper
3
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
4
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
5
+<mapper namespace="com.ruoyi.oa.mapper.CmcProcurePlanMapper">
6
+    
7
+    <resultMap type="CmcProcurePlan" id="CmcProcurePlanResult">
8
+        <result property="procurePlanId"    column="procure_plan_id"    />
9
+        <result property="procureApplyId"    column="procure_apply_id"    />
10
+        <result property="name"    column="name"    />
11
+        <result property="series"    column="series"    />
12
+        <result property="unit"    column="unit"    />
13
+        <result property="price"    column="price"    />
14
+        <result property="num"    column="num"    />
15
+        <result property="amount"    column="amount"    />
16
+        <result property="procureWay"    column="procure_way"    />
17
+        <result property="usage"    column="usage"    />
18
+        <result property="remark"    column="remark"    />
19
+    </resultMap>
20
+
21
+    <sql id="selectCmcProcurePlanVo">
22
+        select procure_plan_id, procure_apply_id, name, series, unit, price, num, amount, procure_way, usage, remark from cmc_procure_plan
23
+    </sql>
24
+
25
+    <select id="selectCmcProcurePlanList" parameterType="CmcProcurePlan" resultMap="CmcProcurePlanResult">
26
+        <include refid="selectCmcProcurePlanVo"/>
27
+        <where>  
28
+            <if test="procureApplyId != null  and procureApplyId != ''"> and procure_apply_id = #{procureApplyId}</if>
29
+            <if test="name != null  and name != ''"> and name like concat('%', #{name}, '%')</if>
30
+            <if test="series != null  and series != ''"> and series = #{series}</if>
31
+            <if test="unit != null  and unit != ''"> and unit = #{unit}</if>
32
+            <if test="price != null "> and price = #{price}</if>
33
+            <if test="num != null "> and num = #{num}</if>
34
+            <if test="amount != null "> and amount = #{amount}</if>
35
+            <if test="procureWay != null  and procureWay != ''"> and procure_way = #{procureWay}</if>
36
+            <if test="usage != null  and usage != ''"> and usage = #{usage}</if>
37
+        </where>
38
+    </select>
39
+    
40
+    <select id="selectCmcProcurePlanByProcurePlanId" parameterType="Integer" resultMap="CmcProcurePlanResult">
41
+        <include refid="selectCmcProcurePlanVo"/>
42
+        where procure_plan_id = #{procurePlanId}
43
+    </select>
44
+        
45
+    <insert id="insertCmcProcurePlan" parameterType="CmcProcurePlan" useGeneratedKeys="true" keyProperty="procurePlanId">
46
+        insert into cmc_procure_plan
47
+        <trim prefix="(" suffix=")" suffixOverrides=",">
48
+            <if test="procureApplyId != null">procure_apply_id,</if>
49
+            <if test="name != null">name,</if>
50
+            <if test="series != null">series,</if>
51
+            <if test="unit != null">unit,</if>
52
+            <if test="price != null">price,</if>
53
+            <if test="num != null">num,</if>
54
+            <if test="amount != null">amount,</if>
55
+            <if test="procureWay != null">procure_way,</if>
56
+            <if test="usage != null">usage,</if>
57
+            <if test="remark != null">remark,</if>
58
+         </trim>
59
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
60
+            <if test="procureApplyId != null">#{procureApplyId},</if>
61
+            <if test="name != null">#{name},</if>
62
+            <if test="series != null">#{series},</if>
63
+            <if test="unit != null">#{unit},</if>
64
+            <if test="price != null">#{price},</if>
65
+            <if test="num != null">#{num},</if>
66
+            <if test="amount != null">#{amount},</if>
67
+            <if test="procureWay != null">#{procureWay},</if>
68
+            <if test="usage != null">#{usage},</if>
69
+            <if test="remark != null">#{remark},</if>
70
+         </trim>
71
+    </insert>
72
+
73
+    <update id="updateCmcProcurePlan" parameterType="CmcProcurePlan">
74
+        update cmc_procure_plan
75
+        <trim prefix="SET" suffixOverrides=",">
76
+            <if test="procureApplyId != null">procure_apply_id = #{procureApplyId},</if>
77
+            <if test="name != null">name = #{name},</if>
78
+            <if test="series != null">series = #{series},</if>
79
+            <if test="unit != null">unit = #{unit},</if>
80
+            <if test="price != null">price = #{price},</if>
81
+            <if test="num != null">num = #{num},</if>
82
+            <if test="amount != null">amount = #{amount},</if>
83
+            <if test="procureWay != null">procure_way = #{procureWay},</if>
84
+            <if test="usage != null">usage = #{usage},</if>
85
+            <if test="remark != null">remark = #{remark},</if>
86
+        </trim>
87
+        where procure_plan_id = #{procurePlanId}
88
+    </update>
89
+
90
+    <delete id="deleteCmcProcurePlanByProcurePlanId" parameterType="Integer">
91
+        delete from cmc_procure_plan where procure_plan_id = #{procurePlanId}
92
+    </delete>
93
+
94
+    <delete id="deleteCmcProcurePlanByProcurePlanIds" parameterType="String">
95
+        delete from cmc_procure_plan where procure_plan_id in 
96
+        <foreach item="procurePlanId" collection="array" open="(" separator="," close=")">
97
+            #{procurePlanId}
98
+        </foreach>
99
+    </delete>
100
+</mapper>

+ 1
- 1
oa-back/ruoyi-system/src/main/resources/mapper/oa/CmcTechnicalMapper.xml Visa fil

@@ -112,7 +112,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
112 112
             <if test="projectId != null">project_id = #{projectId},</if>
113 113
             <if test="accepter != null">accepter = #{accepter},</if>
114 114
             <if test="disclosurer != null">disclosurer = #{disclosurer},</if>
115
-            <if test="confirmer != null">confirmer = #confirmer},</if>
115
+            <if test="confirmer != null">confirmer = #{confirmer},</if>
116 116
             <if test="content != null">content = #{content},</if>
117 117
             <if test="document != null">document = #{document},</if>
118 118
             <if test="disclosureComment != null">disclosure_comment = #{disclosureComment},</if>

+ 44
- 0
oa-ui/src/api/oa/procure/procureApproval.js Visa fil

@@ -0,0 +1,44 @@
1
+import request from '@/utils/request'
2
+
3
+// 查询采购审批列表
4
+export function listProcureApproval(query) {
5
+  return request({
6
+    url: '/oa/procureApproval/list',
7
+    method: 'get',
8
+    params: query
9
+  })
10
+}
11
+
12
+// 查询采购审批详细
13
+export function getProcureApproval(procureApplyId) {
14
+  return request({
15
+    url: '/oa/procureApproval/' + procureApplyId,
16
+    method: 'get'
17
+  })
18
+}
19
+
20
+// 新增采购审批
21
+export function addProcureApproval(data) {
22
+  return request({
23
+    url: '/oa/procureApproval',
24
+    method: 'post',
25
+    data: data
26
+  })
27
+}
28
+
29
+// 修改采购审批
30
+export function updateProcureApproval(data) {
31
+  return request({
32
+    url: '/oa/procureApproval',
33
+    method: 'put',
34
+    data: data
35
+  })
36
+}
37
+
38
+// 删除采购审批
39
+export function delProcureApproval(procureApplyId) {
40
+  return request({
41
+    url: '/oa/procureApproval/' + procureApplyId,
42
+    method: 'delete'
43
+  })
44
+}

+ 44
- 0
oa-ui/src/api/oa/procure/procurePlan.js Visa fil

@@ -0,0 +1,44 @@
1
+import request from '@/utils/request'
2
+
3
+// 查询采购计划列表
4
+export function listProcurePlan(query) {
5
+  return request({
6
+    url: '/oa/procurePlan/list',
7
+    method: 'get',
8
+    params: query
9
+  })
10
+}
11
+
12
+// 查询采购计划详细
13
+export function getProcurePlan(procurePlanId) {
14
+  return request({
15
+    url: '/oa/procurePlan/' + procurePlanId,
16
+    method: 'get'
17
+  })
18
+}
19
+
20
+// 新增采购计划
21
+export function addProcurePlan(data) {
22
+  return request({
23
+    url: '/oa/procurePlan',
24
+    method: 'post',
25
+    data: data
26
+  })
27
+}
28
+
29
+// 修改采购计划
30
+export function updateProcurePlan(data) {
31
+  return request({
32
+    url: '/oa/procurePlan',
33
+    method: 'put',
34
+    data: data
35
+  })
36
+}
37
+
38
+// 删除采购计划
39
+export function delProcurePlan(procurePlanId) {
40
+  return request({
41
+    url: '/oa/procurePlan/' + procurePlanId,
42
+    method: 'delete'
43
+  })
44
+}

+ 8
- 8
oa-ui/src/views/flowable/form/settleForm.vue Visa fil

@@ -1,8 +1,8 @@
1 1
 <!--
2 2
  * @Author: ysh
3 3
  * @Date: 2024-04-30 09:03:14
4
- * @LastEditors: Please set LastEditors
5
- * @LastEditTime: 2024-09-13 10:01:22
4
+ * @LastEditors: wrh
5
+ * @LastEditTime: 2024-09-18 15:23:24
6 6
 -->
7 7
 <template>
8 8
   <div class="app-container" v-loading="loading">
@@ -353,7 +353,7 @@
353 353
             <el-row>
354 354
               <el-col :span="6" :xs="24" :offset="12">
355 355
                 <el-form-item label="签名:" label-width="120px">
356
-                  <span class="auditor"> {{ form.zhUserName ? "" : getUserName(form.zhUserId) }} </span>
356
+                  <span class="auditor"> {{ form.zhUserName ? form.zhUserName : getUserName(form.zhUserId) }} </span>
357 357
                 </el-form-item>
358 358
               </el-col>
359 359
               <el-col :span="6">
@@ -370,7 +370,7 @@
370 370
             <el-row>
371 371
               <el-col :span="6" :xs="24" :offset="12">
372 372
                 <el-form-item label="签名:" label-width="120px">
373
-                  <span class="auditor"> {{ form.jsUserName ? "" : getUserName(form.jsUserId) }} </span>
373
+                  <span class="auditor"> {{ form.jsUserName ? form.jsUserName : getUserName(form.jsUserId) }} </span>
374 374
                 </el-form-item>
375 375
               </el-col>
376 376
               <el-col :span="6">
@@ -387,7 +387,7 @@
387 387
             <el-row>
388 388
               <el-col :span="6" :xs="24" :offset="12">
389 389
                 <el-form-item label="签名:" label-width="120px">
390
-                  <span class="auditor"> {{ form.jyUserName ? "" : getUserName(form.jyUserId) }} </span>
390
+                  <span class="auditor"> {{ form.jyUserName ? form.jyUserName : getUserName(form.jyUserId) }} </span>
391 391
                 </el-form-item>
392 392
               </el-col>
393 393
               <el-col :span="6">
@@ -404,7 +404,7 @@
404 404
             <el-row>
405 405
               <el-col :span="6" :xs="24" :offset="12">
406 406
                 <el-form-item label="签名:" label-width="120px">
407
-                  <span class="auditor"> {{ form.managerUserName ? "" : getUserName(form.managerUserId) }} </span>
407
+                  <span class="auditor"> {{ form.managerUserName ? form.managerUserName : getUserName(form.managerUserId) }} </span>
408 408
                 </el-form-item>
409 409
               </el-col>
410 410
               <el-col :span="6">
@@ -421,7 +421,7 @@
421 421
             <el-row>
422 422
               <el-col :span="6" :xs="24" :offset="12">
423 423
                 <el-form-item label="签名:" label-width="120px">
424
-                  <span class="auditor"> {{ form.gmUserName ? "" : getUserName(form.gmUserId) }} </span>
424
+                  <span class="auditor"> {{ form.gmUserName ? form.gmUserName : getUserName(form.gmUserId) }} </span>
425 425
                 </el-form-item>
426 426
               </el-col>
427 427
               <el-col :span="6">
@@ -439,7 +439,7 @@
439 439
             <el-row v-if="exceed">
440 440
               <el-col :span="6" :xs="24" :offset="12">
441 441
                 <el-form-item label="签名:" label-width="120px">
442
-                  <span class="auditor"> {{ form.dszUserName ? "" : getUserName(form.dszUserId) }} </span>
442
+                  <span class="auditor"> {{ form.dszUserName ? form.dszUserName : getUserName(form.dszUserId) }} </span>
443 443
                 </el-form-item>
444 444
               </el-col>
445 445
               <el-col :span="6">

+ 2
- 2
oa-ui/src/views/oa/car/index.vue Visa fil

@@ -328,10 +328,10 @@ export default {
328 328
         return 'success'
329 329
       }
330 330
       if (row == '2') {
331
-        return 'danger'
331
+        return 'primary'
332 332
       }
333 333
       if (row == '3') {
334
-        return 'primary'
334
+        return 'danger'
335 335
       }
336 336
       if (row == '4') {
337 337
         return 'info'

+ 2
- 2
oa-ui/src/views/oa/device/detail.vue Visa fil

@@ -899,10 +899,10 @@ export default {
899 899
         return 'success'
900 900
       }
901 901
       if (row == '2') {
902
-        return 'danger'
902
+        return 'primary'
903 903
       }
904 904
       if (row == '3') {
905
-        return 'primary'
905
+        return 'danger'
906 906
       }
907 907
       if (row == '4') {
908 908
         return 'info'

+ 2
- 2
oa-ui/src/views/oa/device/index.vue Visa fil

@@ -397,10 +397,10 @@ export default {
397 397
         return 'success'
398 398
       }
399 399
       if (row == '2') {
400
-        return 'danger'
400
+        return 'primary'
401 401
       }
402 402
       if (row == '3') {
403
-        return 'primary'
403
+        return 'danger'
404 404
       }
405 405
       if (row == '4') {
406 406
         return 'info'

+ 426
- 0
oa-ui/src/views/oa/procure/approval.vue Visa fil

@@ -0,0 +1,426 @@
1
+<template>
2
+  <div class="app-container">
3
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
4
+      <el-form-item label="购置说明" prop="applyReason">
5
+        <el-input
6
+          v-model="queryParams.applyReason"
7
+          placeholder="请输入购置说明"
8
+          clearable
9
+          @keyup.enter.native="handleQuery"
10
+        />
11
+      </el-form-item>
12
+      <el-form-item label="申请人" prop="applier">
13
+        <el-input
14
+          v-model="queryParams.applier"
15
+          placeholder="请输入申请人"
16
+          clearable
17
+          @keyup.enter.native="handleQuery"
18
+        />
19
+      </el-form-item>
20
+      <el-form-item label="申请部门" prop="applyDept">
21
+        <el-input
22
+          v-model="queryParams.applyDept"
23
+          placeholder="请输入申请部门"
24
+          clearable
25
+          @keyup.enter.native="handleQuery"
26
+        />
27
+      </el-form-item>
28
+      <el-form-item label="分管审核人" prop="managerUserId">
29
+        <el-input
30
+          v-model="queryParams.managerUserId"
31
+          placeholder="请输入分管审核人"
32
+          clearable
33
+          @keyup.enter.native="handleQuery"
34
+        />
35
+      </el-form-item>
36
+      <el-form-item label="分管审核意见" prop="managerComment">
37
+        <el-input
38
+          v-model="queryParams.managerComment"
39
+          placeholder="请输入分管审核意见"
40
+          clearable
41
+          @keyup.enter.native="handleQuery"
42
+        />
43
+      </el-form-item>
44
+      <el-form-item label="分管审核时间" prop="managerTime">
45
+        <el-date-picker clearable
46
+          v-model="queryParams.managerTime"
47
+          type="date"
48
+          value-format="yyyy-MM-dd"
49
+          placeholder="请选择分管审核时间">
50
+        </el-date-picker>
51
+      </el-form-item>
52
+      <el-form-item label="总经理审批人" prop="zjlUserId">
53
+        <el-input
54
+          v-model="queryParams.zjlUserId"
55
+          placeholder="请输入总经理审批人"
56
+          clearable
57
+          @keyup.enter.native="handleQuery"
58
+        />
59
+      </el-form-item>
60
+      <el-form-item label="总经理审批意见" prop="zjlComment">
61
+        <el-input
62
+          v-model="queryParams.zjlComment"
63
+          placeholder="请输入总经理审批意见"
64
+          clearable
65
+          @keyup.enter.native="handleQuery"
66
+        />
67
+      </el-form-item>
68
+      <el-form-item label="总经理审批时间" prop="zjlTime">
69
+        <el-date-picker clearable
70
+          v-model="queryParams.zjlTime"
71
+          type="date"
72
+          value-format="yyyy-MM-dd"
73
+          placeholder="请选择总经理审批时间">
74
+        </el-date-picker>
75
+      </el-form-item>
76
+      <el-form-item label="计划编制人" prop="planUserId">
77
+        <el-input
78
+          v-model="queryParams.planUserId"
79
+          placeholder="请输入计划编制人"
80
+          clearable
81
+          @keyup.enter.native="handleQuery"
82
+        />
83
+      </el-form-item>
84
+      <el-form-item label="计划编制时间" prop="planTime">
85
+        <el-date-picker clearable
86
+          v-model="queryParams.planTime"
87
+          type="date"
88
+          value-format="yyyy-MM-dd"
89
+          placeholder="请选择计划编制时间">
90
+        </el-date-picker>
91
+      </el-form-item>
92
+      <el-form-item label="计划编制意见" prop="planComment">
93
+        <el-input
94
+          v-model="queryParams.planComment"
95
+          placeholder="请输入计划编制意见"
96
+          clearable
97
+          @keyup.enter.native="handleQuery"
98
+        />
99
+      </el-form-item>
100
+      <el-form-item>
101
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
102
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
103
+      </el-form-item>
104
+    </el-form>
105
+
106
+    <el-row :gutter="10" class="mb8">
107
+      <el-col :span="1.5">
108
+        <el-button
109
+          type="primary"
110
+          plain
111
+          icon="el-icon-plus"
112
+          size="mini"
113
+          @click="handleAdd"
114
+          v-hasPermi="['oa:procureApproval:add']"
115
+        >新增</el-button>
116
+      </el-col>
117
+      <el-col :span="1.5">
118
+        <el-button
119
+          type="success"
120
+          plain
121
+          icon="el-icon-edit"
122
+          size="mini"
123
+          :disabled="single"
124
+          @click="handleUpdate"
125
+          v-hasPermi="['oa:procureApproval:edit']"
126
+        >修改</el-button>
127
+      </el-col>
128
+      <el-col :span="1.5">
129
+        <el-button
130
+          type="danger"
131
+          plain
132
+          icon="el-icon-delete"
133
+          size="mini"
134
+          :disabled="multiple"
135
+          @click="handleDelete"
136
+          v-hasPermi="['oa:procureApproval:remove']"
137
+        >删除</el-button>
138
+      </el-col>
139
+      <el-col :span="1.5">
140
+        <el-button
141
+          type="warning"
142
+          plain
143
+          icon="el-icon-download"
144
+          size="mini"
145
+          @click="handleExport"
146
+          v-hasPermi="['oa:procureApproval:export']"
147
+        >导出</el-button>
148
+      </el-col>
149
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
150
+    </el-row>
151
+
152
+    <el-table v-loading="loading" :data="procureApprovalList" @selection-change="handleSelectionChange">
153
+      <el-table-column type="selection" width="55" align="center" />
154
+      <el-table-column label="采购申请id" align="center" prop="procureApplyId" />
155
+      <el-table-column label="购置说明" align="center" prop="applyReason" />
156
+      <el-table-column label="申请人" align="center" prop="applier" />
157
+      <el-table-column label="申请部门" align="center" prop="applyDept" />
158
+      <el-table-column label="分管审核人" align="center" prop="managerUserId" />
159
+      <el-table-column label="分管审核意见" align="center" prop="managerComment" />
160
+      <el-table-column label="分管审核时间" align="center" prop="managerTime" width="180">
161
+        <template slot-scope="scope">
162
+          <span>{{ parseTime(scope.row.managerTime, '{y}-{m}-{d}') }}</span>
163
+        </template>
164
+      </el-table-column>
165
+      <el-table-column label="总经理审批人" align="center" prop="zjlUserId" />
166
+      <el-table-column label="总经理审批意见" align="center" prop="zjlComment" />
167
+      <el-table-column label="总经理审批时间" align="center" prop="zjlTime" width="180">
168
+        <template slot-scope="scope">
169
+          <span>{{ parseTime(scope.row.zjlTime, '{y}-{m}-{d}') }}</span>
170
+        </template>
171
+      </el-table-column>
172
+      <el-table-column label="计划编制人" align="center" prop="planUserId" />
173
+      <el-table-column label="计划编制时间" align="center" prop="planTime" width="180">
174
+        <template slot-scope="scope">
175
+          <span>{{ parseTime(scope.row.planTime, '{y}-{m}-{d}') }}</span>
176
+        </template>
177
+      </el-table-column>
178
+      <el-table-column label="计划编制意见" align="center" prop="planComment" />
179
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
180
+        <template slot-scope="scope">
181
+          <el-button
182
+            size="mini"
183
+            type="text"
184
+            icon="el-icon-edit"
185
+            @click="handleUpdate(scope.row)"
186
+            v-hasPermi="['oa:procureApproval:edit']"
187
+          >修改</el-button>
188
+          <el-button
189
+            size="mini"
190
+            type="text"
191
+            icon="el-icon-delete"
192
+            @click="handleDelete(scope.row)"
193
+            v-hasPermi="['oa:procureApproval:remove']"
194
+          >删除</el-button>
195
+        </template>
196
+      </el-table-column>
197
+    </el-table>
198
+    
199
+    <pagination
200
+      v-show="total>0"
201
+      :total="total"
202
+      :page.sync="queryParams.pageNum"
203
+      :limit.sync="queryParams.pageSize"
204
+      @pagination="getList"
205
+    />
206
+
207
+    <!-- 添加或修改采购审批对话框 -->
208
+    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
209
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
210
+        <el-form-item label="购置说明" prop="applyReason">
211
+          <el-input v-model="form.applyReason" placeholder="请输入购置说明" />
212
+        </el-form-item>
213
+        <el-form-item label="申请人" prop="applier">
214
+          <el-input v-model="form.applier" placeholder="请输入申请人" />
215
+        </el-form-item>
216
+        <el-form-item label="申请部门" prop="applyDept">
217
+          <el-input v-model="form.applyDept" placeholder="请输入申请部门" />
218
+        </el-form-item>
219
+        <el-form-item label="分管审核人" prop="managerUserId">
220
+          <el-input v-model="form.managerUserId" placeholder="请输入分管审核人" />
221
+        </el-form-item>
222
+        <el-form-item label="分管审核意见" prop="managerComment">
223
+          <el-input v-model="form.managerComment" placeholder="请输入分管审核意见" />
224
+        </el-form-item>
225
+        <el-form-item label="分管审核时间" prop="managerTime">
226
+          <el-date-picker clearable
227
+            v-model="form.managerTime"
228
+            type="date"
229
+            value-format="yyyy-MM-dd"
230
+            placeholder="请选择分管审核时间">
231
+          </el-date-picker>
232
+        </el-form-item>
233
+        <el-form-item label="总经理审批人" prop="zjlUserId">
234
+          <el-input v-model="form.zjlUserId" placeholder="请输入总经理审批人" />
235
+        </el-form-item>
236
+        <el-form-item label="总经理审批意见" prop="zjlComment">
237
+          <el-input v-model="form.zjlComment" placeholder="请输入总经理审批意见" />
238
+        </el-form-item>
239
+        <el-form-item label="总经理审批时间" prop="zjlTime">
240
+          <el-date-picker clearable
241
+            v-model="form.zjlTime"
242
+            type="date"
243
+            value-format="yyyy-MM-dd"
244
+            placeholder="请选择总经理审批时间">
245
+          </el-date-picker>
246
+        </el-form-item>
247
+        <el-form-item label="计划编制人" prop="planUserId">
248
+          <el-input v-model="form.planUserId" placeholder="请输入计划编制人" />
249
+        </el-form-item>
250
+        <el-form-item label="计划编制时间" prop="planTime">
251
+          <el-date-picker clearable
252
+            v-model="form.planTime"
253
+            type="date"
254
+            value-format="yyyy-MM-dd"
255
+            placeholder="请选择计划编制时间">
256
+          </el-date-picker>
257
+        </el-form-item>
258
+        <el-form-item label="计划编制意见" prop="planComment">
259
+          <el-input v-model="form.planComment" placeholder="请输入计划编制意见" />
260
+        </el-form-item>
261
+      </el-form>
262
+      <div slot="footer" class="dialog-footer">
263
+        <el-button type="primary" @click="submitForm">确 定</el-button>
264
+        <el-button @click="cancel">取 消</el-button>
265
+      </div>
266
+    </el-dialog>
267
+  </div>
268
+</template>
269
+
270
+<script>
271
+import { listProcureApproval, getProcureApproval, delProcureApproval, addProcureApproval, updateProcureApproval } from "@/api/oa/procure/procureApproval";
272
+
273
+export default {
274
+  name: "ProcureApproval",
275
+  data() {
276
+    return {
277
+      // 遮罩层
278
+      loading: true,
279
+      // 选中数组
280
+      ids: [],
281
+      // 非单个禁用
282
+      single: true,
283
+      // 非多个禁用
284
+      multiple: true,
285
+      // 显示搜索条件
286
+      showSearch: true,
287
+      // 总条数
288
+      total: 0,
289
+      // 采购审批表格数据
290
+      procureApprovalList: [],
291
+      // 弹出层标题
292
+      title: "",
293
+      // 是否显示弹出层
294
+      open: false,
295
+      // 查询参数
296
+      queryParams: {
297
+        pageNum: 1,
298
+        pageSize: 10,
299
+        applyReason: null,
300
+        applier: null,
301
+        applyDept: null,
302
+        managerUserId: null,
303
+        managerComment: null,
304
+        managerTime: null,
305
+        zjlUserId: null,
306
+        zjlComment: null,
307
+        zjlTime: null,
308
+        planUserId: null,
309
+        planTime: null,
310
+        planComment: null
311
+      },
312
+      // 表单参数
313
+      form: {},
314
+      // 表单校验
315
+      rules: {
316
+      }
317
+    };
318
+  },
319
+  created() {
320
+    this.getList();
321
+  },
322
+  methods: {
323
+    /** 查询采购审批列表 */
324
+    getList() {
325
+      this.loading = true;
326
+      listProcureApproval(this.queryParams).then(response => {
327
+        this.procureApprovalList = response.rows;
328
+        this.total = response.total;
329
+        this.loading = false;
330
+      });
331
+    },
332
+    // 取消按钮
333
+    cancel() {
334
+      this.open = false;
335
+      this.reset();
336
+    },
337
+    // 表单重置
338
+    reset() {
339
+      this.form = {
340
+        procureApplyId: null,
341
+        applyReason: null,
342
+        applier: null,
343
+        applyDept: null,
344
+        managerUserId: null,
345
+        managerComment: null,
346
+        managerTime: null,
347
+        zjlUserId: null,
348
+        zjlComment: null,
349
+        zjlTime: null,
350
+        planUserId: null,
351
+        planTime: null,
352
+        planComment: null
353
+      };
354
+      this.resetForm("form");
355
+    },
356
+    /** 搜索按钮操作 */
357
+    handleQuery() {
358
+      this.queryParams.pageNum = 1;
359
+      this.getList();
360
+    },
361
+    /** 重置按钮操作 */
362
+    resetQuery() {
363
+      this.resetForm("queryForm");
364
+      this.handleQuery();
365
+    },
366
+    // 多选框选中数据
367
+    handleSelectionChange(selection) {
368
+      this.ids = selection.map(item => item.procureApplyId)
369
+      this.single = selection.length!==1
370
+      this.multiple = !selection.length
371
+    },
372
+    /** 新增按钮操作 */
373
+    handleAdd() {
374
+      this.reset();
375
+      this.open = true;
376
+      this.title = "添加采购审批";
377
+    },
378
+    /** 修改按钮操作 */
379
+    handleUpdate(row) {
380
+      this.reset();
381
+      const procureApplyId = row.procureApplyId || this.ids
382
+      getProcureApproval(procureApplyId).then(response => {
383
+        this.form = response.data;
384
+        this.open = true;
385
+        this.title = "修改采购审批";
386
+      });
387
+    },
388
+    /** 提交按钮 */
389
+    submitForm() {
390
+      this.$refs["form"].validate(valid => {
391
+        if (valid) {
392
+          if (this.form.procureApplyId != null) {
393
+            updateProcureApproval(this.form).then(response => {
394
+              this.$modal.msgSuccess("修改成功");
395
+              this.open = false;
396
+              this.getList();
397
+            });
398
+          } else {
399
+            addProcureApproval(this.form).then(response => {
400
+              this.$modal.msgSuccess("新增成功");
401
+              this.open = false;
402
+              this.getList();
403
+            });
404
+          }
405
+        }
406
+      });
407
+    },
408
+    /** 删除按钮操作 */
409
+    handleDelete(row) {
410
+      const procureApplyIds = row.procureApplyId || this.ids;
411
+      this.$modal.confirm('是否确认删除采购审批编号为"' + procureApplyIds + '"的数据项?').then(function() {
412
+        return delProcureApproval(procureApplyIds);
413
+      }).then(() => {
414
+        this.getList();
415
+        this.$modal.msgSuccess("删除成功");
416
+      }).catch(() => {});
417
+    },
418
+    /** 导出按钮操作 */
419
+    handleExport() {
420
+      this.download('oa/procureApproval/export', {
421
+        ...this.queryParams
422
+      }, `procureApproval_${new Date().getTime()}.xlsx`)
423
+    }
424
+  }
425
+};
426
+</script>

+ 1
- 1
oa-ui/src/views/oa/supply/deviceList.vue Visa fil

@@ -187,7 +187,7 @@ export default {
187 187
         return 'success'
188 188
       }
189 189
       if (row == '2') {
190
-        return 'info'
190
+        return 'primary'
191 191
       }
192 192
       if (row == '3') {
193 193
         return 'danger'

+ 2
- 2
oa-ui/src/views/oa/supply/index.vue Visa fil

@@ -359,10 +359,10 @@ export default {
359 359
         return 'success'
360 360
       }
361 361
       if (row == '2') {
362
-        return 'danger'
362
+        return 'primary'
363 363
       }
364 364
       if (row == '3') {
365
-        return 'primary'
365
+        return 'danger'
366 366
       }
367 367
       if (row == '4') {
368 368
         return 'info'

Loading…
Avbryt
Spara