From 51a095555dd95515aadc83c9be1b3dcef4533997 Mon Sep 17 00:00:00 2001 From: zzyuan <781948537@qq.com> Date: Fri, 13 Dec 2024 13:30:22 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8A=A5=E5=BA=9F=E7=AE=A1=E7=90=86=E4=B8=80?= =?UTF-8?q?=E7=BA=A7=E5=88=97=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/repair/scrapManage.js | 20 ++ .../scrapManage/component/homeApply.vue | 185 +++--------------- 2 files changed, 42 insertions(+), 163 deletions(-) create mode 100644 src/api/repair/scrapManage.js diff --git a/src/api/repair/scrapManage.js b/src/api/repair/scrapManage.js new file mode 100644 index 00000000..d28f0b7b --- /dev/null +++ b/src/api/repair/scrapManage.js @@ -0,0 +1,20 @@ +import request from '@/utils/request' + +// 查询报废审核列表 +export function getScrapApplyListApi(query) { + return request({ + url: '/material/scrap_apply_details/list', + method: 'get', + params: query + }) +} + + + + + + + + + + diff --git a/src/views/material/repair/scrapManage/component/homeApply.vue b/src/views/material/repair/scrapManage/component/homeApply.vue index 4d8b90e5..4fbe879a 100644 --- a/src/views/material/repair/scrapManage/component/homeApply.vue +++ b/src/views/material/repair/scrapManage/component/homeApply.vue @@ -21,9 +21,9 @@ - + { - this.typeList = response.rows; + getScrapApplyListApi(params).then((response) => { + this.tableList = response.rows; this.total = response.total; this.loading = false; }); @@ -354,7 +317,7 @@ export default { resetQuery() { this.queryParams.time = []; this.resetForm("queryForm"); - this.queryParams.keyword = ""; + this.queryParams.keyWord = ""; this.handleQuery(); }, /** 通过按钮操作 */ @@ -391,7 +354,6 @@ export default { }); } }, - /** 查看按钮操作 */ handleView(row) { this.$emit("queryTools", row.taskId, row.id, row); @@ -400,66 +362,8 @@ export default { handleUpdate(row) { this.$emit("addTools", row.taskId, row.id,row); }, - - //----消息通知 - getNowTime() { - var today = new Date(); - var year = today.getFullYear(); //获取年份 - var month = today.getMonth() + 1; //获取月份 - var day = today.getDate(); //获取日期 - return year + "-" + month + "-" + day; - }, - - // 表单重置 - reset() { - this.form = { - taskId: "", - remark: "", - }; - this.resetForm("form"); - }, - - //获取验收单数据 - getPrintTable(taskId) { - getAcceptanceForm({ taskId: taskId }).then((response) => { - this.printData = response.data; - this.printTableData = response.data.checkDetailsList; - - let supplierList = []; - this.printTableData.forEach((e) => { - if (e.supplier) { - supplierList.push(e.supplier); - } - }); - supplierList = [...new Set(supplierList)]; - - this.supplierStr = supplierList.join(","); - }); - }, - //查看验收单 - handlePrint(row) { - // this.query.taskId = row.taskId - // this.getPrintTable(row.taskId) - this.openPrint = true; - this.title = "机具设备到货验收单"; - }, - - //打开领料单 - async handleLld(row) { - this.open = true; - var ids = row.id; - const res = await getApplyInfo(ids); - console.log(res); - this.leaseApplyDetails = res.data.leaseApplyDetailsList; - this.leaseApplyData = res.data.leaseApplyInfo; - console.log(this.leaseApplyData); - }, - - //打印 - print() { - this.$refs.remarksPrintRef.print(); - }, - + +// --------------------------------------- /** 删除按钮操作 */ handleDeletePurchase(row) { // console.log(row) @@ -476,8 +380,7 @@ export default { this.$modal.msgSuccess("删除成功"); }) .catch(() => {}); - }, - + }, /** 导出按钮操作 */ handleExport() { this.download( @@ -489,51 +392,7 @@ export default { }, `修试审核_${new Date().getTime()}.xlsx` ); - }, - - //发布按钮 - handleSend(row) { - const param = { id: row.id, taskId: row.taskId }; - this.$modal - .confirm("是否确认发布所选择的数据项?") - .then(function () { - return applySend(param); - }) - .then(() => { - this.getList(); - this.$modal.msgSuccess("发布成功"); - }) - .catch(() => {}); - }, - - handleSendAll() { - if (this.ids.length == 0) { - this.$alert("请至少勾选一个领料申请", "提示", { - type: "warning", - confirmButtonText: "确定", - }); - return; - } else { - applySendAll(this.sendTemp).then((response) => { - if (response.code == 200) { - this.$modal.msgSuccess("发布成功"); - } - this.getList(); - }); - } - }, - }, - - watch: { - $route: { - handler(to) { - if (to.query.keyword) { - this.queryParams.keyword = to.query.keyword; - } - }, - deep: true, - immediate: true, - }, + }, }, };