From 29ef871aa6793a8f3e808dfa0702fd8ce8e6dae2 Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期一, 03 三月 2025 16:29:49 +0800
Subject: [PATCH] 检验任务不合格处理报错修改
---
src/views/business/unpass/components/unPassDialog.vue | 21 +++++++++------------
src/views/business/inspectionTask/inspection.vue | 14 ++++++++++++--
src/router/index.js | 2 +-
3 files changed, 22 insertions(+), 15 deletions(-)
diff --git a/src/router/index.js b/src/router/index.js
index eb196f1..180cdb2 100644
--- a/src/router/index.js
+++ b/src/router/index.js
@@ -149,7 +149,7 @@
path: "inspection",
component: () => import("@/views/business/inspectionTask/inspection"),
name: "inspection",
- meta: { title: "妫�楠屽崟璇︽儏", activeMenu: "/business/inspectionTask" },
+ meta: { title: "妫�楠屽崟璇︽儏", activeMenu: "/business/inspectionTask", keepAlive: false },
},
],
},
diff --git a/src/views/business/inspectionTask/inspection.vue b/src/views/business/inspectionTask/inspection.vue
index be6876c..e4b841e 100644
--- a/src/views/business/inspectionTask/inspection.vue
+++ b/src/views/business/inspectionTask/inspection.vue
@@ -515,7 +515,7 @@
<script>
import excelFunction from "@/utils/excelFountion";
import limsTable from "@/components/Table/lims-table.vue";
-import UnPassDialog from "../unpass/components/addUnPass.vue";
+import UnPassDialog from "../unpass/components/unPassDialog.vue";
import AddUnPass from "../unpass/components/addUnPass.vue";
import InspectionWord from "./components/InspectionWord.vue";
import PurchaseVerification from "../unpass/components/PurchaseVerification.vue";
@@ -543,7 +543,7 @@
import html2canvas from "html2canvas";
import { mapGetters } from "vuex";
export default {
- name: 'inspection',
+ name: 'Inspection',
components: {
PurchaseVerification,
AddUnPass,
@@ -789,6 +789,16 @@
// this.getList0() // 浠诲姟鍒囨崲
this.scrollInit();
},
+ activated() {
+ this.getTypeDicts(); // 鑾峰彇绱ф�ョ▼搴︿笅鎷夋閫夐」
+ this.getInsStateDicts();
+ this.getComparisonList();
+ this.getAuthorizedPerson();
+ // this.getPower();
+ this.startWorker();
+ // this.getList0() // 浠诲姟鍒囨崲
+ this.scrollInit();
+ },
watch: {
// 鐩戝惉浠诲姟id锛岃幏鍙栦换鍔′俊鎭�
id(val) {
diff --git a/src/views/business/unpass/components/unPassDialog.vue b/src/views/business/unpass/components/unPassDialog.vue
index 39a57b1..abb940f 100644
--- a/src/views/business/unpass/components/unPassDialog.vue
+++ b/src/views/business/unpass/components/unPassDialog.vue
@@ -62,7 +62,7 @@
</el-form-item>
</el-form>
<el-upload v-if="type === 'add'" ref="upload" :action="action2" :on-change="beforeUpload" :on-error="onError"
- :on-remove="handleRemoveFile" :on-success="getUnpassUrl" :headers="headers" :file-list="unPassFilesList">
+ :on-remove="handleRemoveFile" :on-success="getUnpassUrl" :headers="uploadHeader" :file-list="unPassFilesList">
<el-button size="small" type="primary" style="text-align: left">闄勪欢涓婁紶</el-button>
</el-upload>
<div v-if="type !== 'add'">
@@ -84,6 +84,7 @@
<script>
import { getInsOrder, getUnqualifiedHandler, downFile, addUnqualifiedHandler } from '@/api/business/unpass.js'
+import {mapGetters} from "vuex";
export default {
name: "unPassDialog",
// import 寮曞叆鐨勭粍浠堕渶瑕佹敞鍏ュ埌瀵硅薄涓墠鑳戒娇鐢�
@@ -148,17 +149,17 @@
orderId: this.orderId
}).then(res => {
if (res.code === 200) {
- this.unPassForm.headline = `No.0005-涓ぉ瑁呭鐢电嚎-澶栬喘鍝佷笉鍚堟牸鍙嶉璇勫鍙婄籂姝i闃叉祦绋�(姝e紡鐗�)-${JSON.parse(localStorage.getItem("user")).name}-${new Date().toISOString().substring(0, 10)}` // 鏍囬
- this.unPassForm.inventoryQuantityId = res.data.insOrderTemplate.inventoryQuantityId // 鍘熸潗鏂檌d
+ this.unPassForm.headline = `No.0005-涓ぉ瑁呭鐢电嚎-澶栬喘鍝佷笉鍚堟牸鍙嶉璇勫鍙婄籂姝i闃叉祦绋�(姝e紡鐗�)-${this.nickName}-${new Date().toISOString().substring(0, 10)}` // 鏍囬
+ this.unPassForm.feedbackTime = new Date().toISOString().substring(0, 10) // 鎶ユ鏃堕棿
+ this.unPassForm.feedbackUser = this.nickName // 鍙嶉浜�
this.unPassForm.insOrderId = res.data.insOrder.id // 璁㈠崟id
- this.unPassForm.supplierName = res.data.insOrderTemplate.supplierName // 渚涘簲鍟嗗悕绉�
this.unPassForm.materialName = res.data.insOrder.sampleType // 鐗╂枡鍚嶇О
+ this.unPassForm.specsModels = res.data.insOrder.partDetail // 瑙勬牸鍨嬪彿
+ this.unPassForm.inventoryQuantityId = res.data.insOrderTemplate.inventoryQuantityId // 鍘熸潗鏂檌d
+ this.unPassForm.supplierName = res.data.insOrderTemplate.supplierName // 渚涘簲鍟嗗悕绉�
this.unPassForm.productionBatch = res.data.insOrderTemplate.updateBatchNo // 鐢熶骇鎵规
this.unPassForm.cargoQuantity = res.data.insOrderTemplate.qtyArrived + res.data.insOrderTemplate.buyUnitMeas // 鍒拌揣鏁伴噺
- this.unPassForm.specsModels = res.data.insOrder.partDetail // 瑙勬牸鍨嬪彿
this.unPassForm.inspectTime = res.data.insOrderTemplate.sendTime.substring(0, 10) // 鎶ユ鏃堕棿
- this.unPassForm.feedbackTime = new Date().toISOString().substring(0, 10) // 鎶ユ鏃堕棿
- this.unPassForm.feedbackUser = JSON.parse(localStorage.getItem("user")).name // 鍙嶉浜�
}
})
} else {
@@ -256,11 +257,7 @@
},
},
computed: {
- headers() {
- return {
- 'token': sessionStorage.getItem('token')
- }
- },
+ ...mapGetters(["nickName"]),
action2() {
return this.javaApi + '/unqualifiedHandler/uploadFileByUnqualified'
}
--
Gitblit v1.9.3