From c386df0c9982dc91eeb85789f724f9af5321d75b Mon Sep 17 00:00:00 2001 From: liuxiaoxu <1793812695@qq.com> Date: Sat, 23 Nov 2024 09:00:12 +0800 Subject: [PATCH] =?UTF-8?q?[feat]=E9=87=87=E8=B4=AD=E7=AE=A1=E7=90=86=20?= =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=87=87=E8=B4=AD=E6=8A=A5=E4=BB=B7=E5=89=8D?= =?UTF-8?q?=E7=AB=AF=E5=88=97=E8=A1=A8=E9=A1=B5=E9=9D=A2=EF=BC=9A=E8=A1=A8?= =?UTF-8?q?=E5=A4=B4=E3=80=81=E5=88=97=E8=A1=A8=E3=80=81=E6=93=8D=E4=BD=9C?= =?UTF-8?q?=E6=A0=8F=E8=B0=83=E6=95=B4=E4=B8=BA=E7=BB=9F=E4=B8=80=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F=20=E6=96=B0=E5=A2=9E=E9=A1=B5=E9=9D=A2=E3=80=81?= =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=A1=B5=E9=9D=A2=E3=80=81=E5=AE=A1=E6=89=B9?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E5=8E=BB=E6=8E=89=E6=B2=A1=E7=94=A8=E7=9A=84?= =?UTF-8?q?=E5=A4=87=E6=B3=A8=E5=AD=97=E6=AE=B5=20=E9=87=87=E8=B4=AD?= =?UTF-8?q?=E6=8A=A5=E4=BB=B7=E5=AD=90=E8=A1=A8=E6=96=B0=E5=A2=9E=20?= =?UTF-8?q?=E9=80=9A=E8=BF=87=E9=87=87=E8=B4=AD=E6=8A=A5=E4=BB=B7=E7=BC=96?= =?UTF-8?q?=E7=A0=81=E6=9F=A5=E6=89=BE=E6=89=80=E6=9C=89=E9=87=87=E8=B4=AD?= =?UTF-8?q?=E6=8A=A5=E4=BB=B7=E5=AD=90=E8=A1=A8=E9=9B=86=E5=90=88=E6=96=B9?= =?UTF-8?q?=E6=B3=95=20=E4=BF=AE=E5=A4=8D=20=E6=A0=B9=E6=8D=AE=E9=87=87?= =?UTF-8?q?=E8=B4=AD=E6=8A=A5=E4=BB=B7=E4=BF=A1=E6=81=AF=E6=9B=B4=E6=96=B0?= =?UTF-8?q?=E9=87=87=E8=B4=AD=E6=8A=A5=E4=BB=B7=E6=9C=80=E6=96=B0=E6=8A=A5?= =?UTF-8?q?=E4=BB=B7=E8=AE=B0=E5=BD=95=E6=8A=A5=E9=94=99=E9=97=AE=E9=A2=98?= =?UTF-8?q?=20=E4=BF=AE=E6=94=B9=E9=87=87=E8=B4=AD=E6=8A=A5=E4=BB=B7?= =?UTF-8?q?=E5=88=86=E9=A1=B5=E6=9F=A5=E8=AF=A2=E6=96=B9=E6=B3=95=EF=BC=9A?= =?UTF-8?q?=E5=8A=A0=E4=B8=8A=E5=AE=A1=E6=A0=B8=E9=80=9A=E8=BF=87=E5=92=8C?= =?UTF-8?q?=E5=AE=A1=E6=A0=B8=E6=8B=92=E7=BB=9D=E5=AD=97=E6=AE=B5=20?= =?UTF-8?q?=E9=87=87=E8=B4=AD=E6=8A=A5=E4=BB=B7Vo=E7=B1=BB=E5=8A=A0?= =?UTF-8?q?=E4=B8=8A=E5=BD=93=E5=89=8D=E7=8A=B6=E6=80=81=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../purchase/domain/Vo/PurchaseQuoteVo.java | 13 +++++++ .../mapper/PurchaseQuoteChildMapper.java | 4 +++ .../impl/PurchaseQuoteHistoryServiceImpl.java | 5 +-- .../impl/PurchaseQuoteServiceImpl.java | 6 ++++ .../purchase/PurchaseQuoteChildMapper.xml | 5 +++ .../templates/purchase/purchaseQuote/add.html | 1 - .../purchase/purchaseQuote/detail.html | 1 - .../purchase/purchaseQuote/edit.html | 1 - .../purchase/purchaseQuote/purchaseQuote.html | 34 ++++++++++++------- .../purchaseQuote/taskCgjlVerify.html | 1 - .../purchaseQuote/taskFzjlVerify.html | 1 - .../purchaseQuote/taskModifyApply.html | 1 - 12 files changed, 53 insertions(+), 20 deletions(-) diff --git a/ruoyi-admin/src/main/java/com/ruoyi/purchase/domain/Vo/PurchaseQuoteVo.java b/ruoyi-admin/src/main/java/com/ruoyi/purchase/domain/Vo/PurchaseQuoteVo.java index 3468c5cd..153d9b1f 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/purchase/domain/Vo/PurchaseQuoteVo.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/purchase/domain/Vo/PurchaseQuoteVo.java @@ -19,6 +19,11 @@ public class PurchaseQuoteVo extends PurchaseQuote { private String taskId; /** 任务名称 */ private String taskName; + + + // 当前状态 + private String taskStatus; + /** 办理时间 */ private Date doneTime; /** 创建人 */ @@ -96,6 +101,13 @@ public class PurchaseQuoteVo extends PurchaseQuote { this.instanceTypeName = instanceTypeName; } + public String getTaskStatus() { + return taskStatus; + } + + public void setTaskStatus(String taskStatus) { + this.taskStatus = taskStatus; + } @Override public String toString() { @@ -103,6 +115,7 @@ public class PurchaseQuoteVo extends PurchaseQuote { "applyUserName='" + applyUserName + '\'' + ", taskId='" + taskId + '\'' + ", taskName='" + taskName + '\'' + + ", taskStatus='" + taskStatus + '\'' + ", doneTime=" + doneTime + ", createUserName='" + createUserName + '\'' + ", suspendState='" + suspendState + '\'' + diff --git a/ruoyi-admin/src/main/java/com/ruoyi/purchase/mapper/PurchaseQuoteChildMapper.java b/ruoyi-admin/src/main/java/com/ruoyi/purchase/mapper/PurchaseQuoteChildMapper.java index 0a24b429..7cb27f49 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/purchase/mapper/PurchaseQuoteChildMapper.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/purchase/mapper/PurchaseQuoteChildMapper.java @@ -95,4 +95,8 @@ public interface PurchaseQuoteChildMapper * */ List selectQuoteChildBySupplierCode(String supplierCode); + /** + * 通过采购报价编码查找所有采购报价子表集合 + * */ + List selectQuoteChildByPurchaseQuoteCode(String purchaseQuoteCode); } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/purchase/service/impl/PurchaseQuoteHistoryServiceImpl.java b/ruoyi-admin/src/main/java/com/ruoyi/purchase/service/impl/PurchaseQuoteHistoryServiceImpl.java index c7528461..eb478b9d 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/purchase/service/impl/PurchaseQuoteHistoryServiceImpl.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/purchase/service/impl/PurchaseQuoteHistoryServiceImpl.java @@ -18,6 +18,7 @@ import com.ruoyi.purchase.mapper.PurchaseQuoteHistoryMapper; import com.ruoyi.purchase.domain.PurchaseQuoteHistory; import com.ruoyi.purchase.service.IPurchaseQuoteHistoryService; import com.ruoyi.common.core.text.Convert; +import org.springframework.transaction.annotation.Transactional; /** * 采购物料历史报价信息Service业务层处理 @@ -199,9 +200,9 @@ public class PurchaseQuoteHistoryServiceImpl implements IPurchaseQuoteHistorySer String loginName = ShiroUtils.getLoginName(); String supplierCode = purchaseQuoteVo.getSupplierQuoteCode(); String auditStatus = purchaseQuoteVo.getAuditStatus(); - + String purchaseQuoteCode = purchaseQuoteVo.getPurchaseQuoteCode(); // 获取所有的子项 - List purchaseQuoteChildList= purchaseQuoteChildMapper.selectQuoteChildBySupplierCode(supplierCode); + List purchaseQuoteChildList= purchaseQuoteChildMapper.selectQuoteChildByPurchaseQuoteCode(purchaseQuoteCode); for (PurchaseQuoteChild purchaseQuoteChild : purchaseQuoteChildList) { PurchaseQuoteHistory purchaseQuoteHistory = new PurchaseQuoteHistory(); diff --git a/ruoyi-admin/src/main/java/com/ruoyi/purchase/service/impl/PurchaseQuoteServiceImpl.java b/ruoyi-admin/src/main/java/com/ruoyi/purchase/service/impl/PurchaseQuoteServiceImpl.java index dcb4f0b6..05b0836a 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/purchase/service/impl/PurchaseQuoteServiceImpl.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/purchase/service/impl/PurchaseQuoteServiceImpl.java @@ -148,6 +148,12 @@ public class PurchaseQuoteServiceImpl implements IPurchaseQuoteService } else { purchaseQuoteVo.setTaskName("未启动"); } + purchaseQuoteVo.setTaskStatus(purchaseQuoteVo.getTaskName()); + if(purchaseQuoteVo.getAuditStatus()!=null && purchaseQuoteVo.getAuditStatus().equals("1")){ + purchaseQuoteVo.setTaskStatus("审核通过"); + }else if(purchaseQuoteVo.getAuditStatus()!=null && purchaseQuoteVo.getAuditStatus().equals("2")){ + purchaseQuoteVo.setTaskStatus("审核拒绝"); + } returnList.add(purchaseQuoteVo); } returnList.setTotal(CollectionUtils.isEmpty(list) ? 0 : list.getTotal()); diff --git a/ruoyi-admin/src/main/resources/mapper/purchase/PurchaseQuoteChildMapper.xml b/ruoyi-admin/src/main/resources/mapper/purchase/PurchaseQuoteChildMapper.xml index 814e8523..9297bcc3 100644 --- a/ruoyi-admin/src/main/resources/mapper/purchase/PurchaseQuoteChildMapper.xml +++ b/ruoyi-admin/src/main/resources/mapper/purchase/PurchaseQuoteChildMapper.xml @@ -90,6 +90,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" where supplier_code = #{supplierCode} + + insert into purchase_quote_child diff --git a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/add.html b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/add.html index 14f9bb40..76e67e96 100644 --- a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/add.html +++ b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/add.html @@ -201,7 +201,6 @@ {title: '录入时间',field: 'createTime',align: 'center',visible: false }, {title: '更新人',field: 'updateBy',align: 'center',visible: false}, {title: '上次更新时间',field: 'updateTime',align: 'center',visible: false}, - {title: '备注',field: 'remark',align: 'center'}, {title: '操作', align: 'center', formatter: function (value, row, index) { var actions = []; diff --git a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/detail.html b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/detail.html index cd98cb9d..85ce9568 100644 --- a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/detail.html +++ b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/detail.html @@ -218,7 +218,6 @@ {title: '录入时间',field: 'createTime',align: 'center',visible: false }, {title: '更新人',field: 'updateBy',align: 'center',visible: false}, {title: '上次更新时间',field: 'updateTime',align: 'center',visible: false}, - {title: '备注',field: 'remark',align: 'center'}, ], }; $.table.init(options); diff --git a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/edit.html b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/edit.html index 7ff73315..cd658d06 100644 --- a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/edit.html +++ b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/edit.html @@ -240,7 +240,6 @@ {title: '录入时间',field: 'createTime',align: 'center',visible: false }, {title: '更新人',field: 'updateBy',align: 'center',visible: false}, {title: '上次更新时间',field: 'updateTime',align: 'center',visible: false}, - {title: '备注',field: 'remark',align: 'center'}, {title: '操作', align: 'center', formatter: function (value, row, index) { var actions = []; diff --git a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/purchaseQuote.html b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/purchaseQuote.html index 71a93b81..dd12d6ef 100644 --- a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/purchaseQuote.html +++ b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/purchaseQuote.html @@ -109,7 +109,7 @@ columns: [ {checkbox: true}, {title: '采购报价索引id',field: 'purchaseQuoteId',visible: false}, - {title: '审核状态',field: 'auditStatus', + {title: '审核状态',field: 'auditStatus',visible: false, formatter: function (value, row, index) {return $.table.selectDictLabel(auditStatusDatas, value);} }, {title: '流程实例ID',field: 'instanceId',visible: false}, @@ -118,29 +118,39 @@ {title: '流程恢复实例ID',field: 'restoreInstanceId', visible: false}, { title: '流程实例类型', field: 'instanceTypeName',visible: false}, {title: '申请人ID',field: 'applyUser', visible: false}, - { - field: 'applyUserName', - title: '申请人', - formatter: function(value, row, index) { - return '' + (value ? value : "-") + ''; - } - }, - {field: 'applyTime',title: '申请时间' - }, {title: '当前任务ID',field: 'taskId',visible: false}, { title: '待办用户ID',field: 'todoUserId', visible: false}, - { title: '当前任务名称',field: 'taskName', + { title: '当前任务名称',field: 'taskName', visible: false, align: 'center', formatter: function(value, row, index) { return '' + value + ''; } }, - {title: '采购员',field: 'purchaseBuyer',}, + {title: '当前状态',field: 'taskStatus', + formatter: function(value, row, index) { + if(row.auditStatus!="1"&&value != "未启动"){ + return '' + value + ''; + } + if(value === "未启动"){ + return '' + value + ''; + } + return '' + value + '';} + }, {title: '采购报价单号',field: 'purchaseQuoteCode',}, {title: '供应商ID',field: 'supplierQuoteCode',}, {title: '供应商名称',field: 'supplierName',}, {title: '物料合计',field: 'materialAmount',}, {title: '定价时间',field: 'pricingDate',}, + {field: 'applyTime',title: '申请时间' + }, + { + field: 'applyUserName', + title: '申请人', + formatter: function(value, row, index) { + return '' + (value ? value : "-") + ''; + } + }, + {title: '采购员',field: 'purchaseBuyer',}, {title: '录入时间',field: 'createTime',}, {title: '更新人',field: 'updateBy',}, {title: '上次更新时间',field: 'updateTime',}, diff --git a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/taskCgjlVerify.html b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/taskCgjlVerify.html index 7f9ee2e3..b8e0c88d 100644 --- a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/taskCgjlVerify.html +++ b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/taskCgjlVerify.html @@ -261,7 +261,6 @@ {title: '录入时间',field: 'createTime',align: 'center',visible: false }, {title: '更新人',field: 'updateBy',align: 'center',visible: false}, {title: '上次更新时间',field: 'updateTime',align: 'center',visible: false}, - {title: '备注',field: 'remark',align: 'center'}, ], }; $.table.init(options); diff --git a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/taskFzjlVerify.html b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/taskFzjlVerify.html index 09b3962c..70a39820 100644 --- a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/taskFzjlVerify.html +++ b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/taskFzjlVerify.html @@ -263,7 +263,6 @@ {title: '录入时间',field: 'createTime',align: 'center',visible: false }, {title: '更新人',field: 'updateBy',align: 'center',visible: false}, {title: '上次更新时间',field: 'updateTime',align: 'center',visible: false}, - {title: '备注',field: 'remark',align: 'center'}, ], }; $.table.init(options); diff --git a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/taskModifyApply.html b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/taskModifyApply.html index 0740a9a4..298829ef 100644 --- a/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/taskModifyApply.html +++ b/ruoyi-admin/src/main/resources/templates/purchase/purchaseQuote/taskModifyApply.html @@ -257,7 +257,6 @@ {title: '录入时间',field: 'createTime',align: 'center',visible: false }, {title: '更新人',field: 'updateBy',align: 'center',visible: false}, {title: '上次更新时间',field: 'updateTime',align: 'center',visible: false}, - {title: '备注',field: 'remark',align: 'center'}, {title: '操作', align: 'center', formatter: function (value, row, index) { var actions = [];