From 371db4016dcfc8c35c44c9bfce4611443d836580 Mon Sep 17 00:00:00 2001
From: huminmin <mac@MacBook-Pro.local>
Date: 星期四, 26 三月 2026 16:08:08 +0800
Subject: [PATCH] 指标维护和不合格类别去掉原材料检验,出厂改成成品
---
src/views/qualityManagement/nonconformingManagement/index.vue | 37 ++++++++++++++++++++++++++-----------
1 files changed, 26 insertions(+), 11 deletions(-)
diff --git a/src/views/qualityManagement/nonconformingManagement/index.vue b/src/views/qualityManagement/nonconformingManagement/index.vue
index c0fd2ca..33c1ee3 100644
--- a/src/views/qualityManagement/nonconformingManagement/index.vue
+++ b/src/views/qualityManagement/nonconformingManagement/index.vue
@@ -5,9 +5,8 @@
<div>
<span class="search_title">绫诲瀷锛�</span>
<el-select v-model="searchForm.inspectType" clearable style="width: 200px" @change="handleQuery">
- <el-option label="鍘熸潗鏂欐楠�" :value="0" />
<el-option label="杩囩▼妫�楠�" :value="1" />
- <el-option label="鍑哄巶妫�楠�" :value="2" />
+ <el-option label="鎴愬搧妫�楠�" :value="2" />
</el-select>
</div>
<div style="margin-left: 10px">
@@ -60,10 +59,10 @@
<script setup>
import { Search } from "@element-plus/icons-vue";
-import {onMounted, ref} from "vue";
+import {onMounted, ref, reactive, toRefs, nextTick, getCurrentInstance} from "vue";
import FormDia from "@/views/qualityManagement/nonconformingManagement/components/formDia.vue";
import {ElMessageBox} from "element-plus";
-import {qualityUnqualifiedDel, qualityUnqualifiedListPage} from "@/api/qualityManagement/nonconformingManagement.js";
+import {qualityUnqualifiedDel, qualityUnqualifiedListPage, liftTheQuarantineQualityUnqualified} from "@/api/qualityManagement/nonconformingManagement.js";
import InspectionFormDia from "@/views/qualityManagement/nonconformingManagement/components/inspectionFormDia.vue";
import dayjs from "dayjs";
@@ -113,12 +112,10 @@
dataType: "tag",
width: 120,
formatData: (params) => {
- if (params == 0) {
- return "鍘熸潗鏂欐楠�";
- } else if (params == 1) {
+ if (params == 1) {
return "杩囩▼妫�楠�";
} else {
- return '鍑哄巶妫�楠�';
+ return '鎴愬搧妫�楠�';
}
},
formatType: (params) => {
@@ -177,14 +174,15 @@
label: "鎿嶄綔",
align: "center",
fixed: "right",
- width: 120,
+ width: 100,
operation: [
{
- name: "缂栬緫",
+ name: "鍙栨秷闅旂",
type: "text",
clickFun: (row) => {
- openForm("edit", row);
+ liftTheQuarantine(row);
},
+ showHide: (row) => row.dealResult === '闅旂' && !row.quarantineLifted
},
{
name: "澶勭悊",
@@ -192,6 +190,7 @@
clickFun: (row) => {
openInspectionForm("edit", row);
},
+ disabled: (row) => row.inspectState === 1,
},
],
},
@@ -247,17 +246,33 @@
// 鎵撳紑寮规
const openForm = (type, row) => {
+ if (type !== 'add' && row?.inspectState === 1) {
+ proxy.$modal.msgWarning("宸插鐞嗙殑鏁版嵁涓嶈兘鍐嶇紪杈�");
+ return;
+ }
nextTick(() => {
formDia.value?.openDialog(type, row)
})
};
// 鎵撳紑澶勭悊寮规
const openInspectionForm = (type, row) => {
+ if (row?.inspectState === 1) {
+ proxy.$modal.msgWarning("宸插鐞嗙殑鏁版嵁涓嶈兘鍐嶅鐞�");
+ return;
+ }
nextTick(() => {
inspectionFormDia.value?.openDialog(type, row)
})
};
+const liftTheQuarantine = (row) => {
+ proxy.$modal.confirm("鏄惁纭鍙栨秷闅旂?").then(function () {
+ return liftTheQuarantineQualityUnqualified(row)
+ }).then(() => {
+ proxy.$modal.msgSuccess("鍙栨秷闅旂鎴愬姛");
+ getList();
+ }).catch(() => {})
+}
// 鍒犻櫎
const handleDelete = () => {
let ids = [];
--
Gitblit v1.9.3