From 8d93800f5765633ec1c954c94562c036a2c3695b Mon Sep 17 00:00:00 2001 From: hh <2397241381@qq.com> Date: Thu, 17 Aug 2023 00:56:17 +0800 Subject: [PATCH] =?UTF-8?q?=E7=AC=AC=E4=B8=89=E6=A8=A1=E5=9D=97=E5=BC=80?= =?UTF-8?q?=E5=8F=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../purchase/processing/orderProcessing.vue | 34 ++++++++++++- .../purchase/progress/procurementProgress.vue | 51 +++++++++++++++++++ 2 files changed, 84 insertions(+), 1 deletion(-) create mode 100644 src/views/purchase/progress/procurementProgress.vue diff --git a/src/views/purchase/processing/orderProcessing.vue b/src/views/purchase/processing/orderProcessing.vue index 578cd79..ff07bf3 100644 --- a/src/views/purchase/processing/orderProcessing.vue +++ b/src/views/purchase/processing/orderProcessing.vue @@ -9,6 +9,9 @@
采购订单号:HL-{{ item.requirementNumber }}   部门:{{ item.sysOrgCode }}   采购方向:{{ item.procurementDirection }} + + 开始采购 生成订单 取消接单
@@ -152,7 +155,8 @@ export default { getPurchaseSupplier: "Try/purchaseSupplier/list", getdata: "/Try/purchaseOrderConfirmation/joinList", receiveNOurl: "/Try/purchaseOrderConfirmation/cancelReceiving", - editUrl: '/Try/purchaseOrderConfirmation/edit' + editUrl: '/Try/purchaseOrderConfirmation/edit', + finshUrl: '/Try/purchaseOrderConfirmation/finish' }, activeKey: [], username: Vue.ls.get(USER_INFO).username, @@ -183,12 +187,40 @@ export default { editUrl: function () { return `${window._CONFIG['domianURL']}/${this.url.editUrl}`; }, + finshUrl: function () { + return `${window._CONFIG['domianURL']}/${this.url.finshUrl}`; + }, }, created() { this.getSupplierData(); this.getTableData(); }, methods: { + finish(item) { + let newItem = Object.assign({}, item); + newItem.procurementContent = JSON.stringify(newItem.procurementContent); + if (newItem.supplierSelection != null && newItem.supplierSelection != '') { + newItem.supplierSelection = JSON.stringify(newItem.supplierSelection); + } else { + newItem.supplierSelection = ''; + } + // 新增procurementLog为 + newItem.procurementLog = { + '0': newItem.supplierSelection + } + newItem.procurementLog = JSON.stringify(newItem.procurementLog); + //将newItem将requirementNumber修改associationNumber + newItem.associationNumber = newItem.requirementNumber; + postAction(this.finshUrl, newItem).then(res => { + //如果为200,则获取数据 + if (res.code == 200) { + this.$message.success('完成订单成功'); + this.getTableData(); + } else { + this.$message.error(res.message); + } + }) + }, getSupplierData() { getAction(this.getPurchaseSupplier).then(res => { //如果为200,则获取数据 diff --git a/src/views/purchase/progress/procurementProgress.vue b/src/views/purchase/progress/procurementProgress.vue new file mode 100644 index 0000000..e71d4ce --- /dev/null +++ b/src/views/purchase/progress/procurementProgress.vue @@ -0,0 +1,51 @@ + + + \ No newline at end of file