From 825155dffbd4f39f930ed0a0dfeca59307709019 Mon Sep 17 00:00:00 2001
From: huminmin <mac@MacBook-Pro.local>
Date: 星期一, 02 二月 2026 17:47:08 +0800
Subject: [PATCH] 工序,工艺路线增加是否质检
---
src/views/productionManagement/productionProcess/index.vue | 8 +++++++-
src/views/productionManagement/processRoute/processRouteItem/index.vue | 21 +++++++++++++++++++++
src/views/productionManagement/productionProcess/Edit.vue | 6 ++++++
src/views/productionManagement/productionProcess/New.vue | 4 ++++
4 files changed, 38 insertions(+), 1 deletions(-)
diff --git a/src/views/productionManagement/processRoute/processRouteItem/index.vue b/src/views/productionManagement/processRoute/processRouteItem/index.vue
index 99d89a9..0eb639d 100644
--- a/src/views/productionManagement/processRoute/processRouteItem/index.vue
+++ b/src/views/productionManagement/processRoute/processRouteItem/index.vue
@@ -82,6 +82,11 @@
<el-table-column label="浜у搧鍚嶇О" prop="productName" min-width="160" />
<el-table-column label="瑙勬牸鍚嶇О" prop="model" min-width="140" />
<el-table-column label="鍗曚綅" prop="unit" width="100" />
+ <el-table-column label="鏄惁璐ㄦ" prop="isQuality" width="100">
+ <template #default="scope">
+ {{scope.row.isQuality ? "鏄�" : "鍚�"}}
+ </template>
+ </el-table-column>
<el-table-column label="鎿嶄綔" align="center" fixed="right" width="150">
<template #default="scope">
<el-button type="primary" link size="small" @click="handleEdit(scope.row)" :disabled="scope.row.isComplete">缂栬緫</el-button>
@@ -130,6 +135,7 @@
{{ item.model }}
<!-- <span v-if="item.unit" class="product-unit">{{ item.unit }}</span> -->
</div>
+ <el-tag type="primary" class="product-tag" v-if="item.isQuality">璐ㄦ</el-tag>
</div>
<div v-else class="product-info empty">鏆傛棤浜у搧淇℃伅</div>
</div>
@@ -188,6 +194,10 @@
clearable
:disabled="true"
/>
+ </el-form-item>
+
+ <el-form-item label="鏄惁璐ㄦ" prop="isQuality">
+ <el-switch v-model="form.isQuality" :active-value="true" inactive-value="false"/>
</el-form-item>
</el-form>
@@ -262,6 +272,7 @@
productName: "",
model: "",
unit: "",
+ isQuality: false,
});
const rules = {
@@ -331,6 +342,7 @@
// 缂栬緫
const handleEdit = (row) => {
+ console.log(1111, row.isQuality);
operationType.value = 'edit';
form.value = {
id: row.id,
@@ -340,6 +352,7 @@
productName: row.productName || "",
model: row.model || "",
unit: row.unit || "",
+ isQuality: row.isQuality,
};
dialogVisible.value = true;
};
@@ -402,12 +415,14 @@
productRouteId: routeId.value,
processId: form.value.processId,
productModelId: form.value.productModelId,
+ isQuality: form.value.isQuality,
dragSort,
})
: addOrUpdateProcessRouteItem({
routeId: routeId.value,
processId: form.value.processId,
productModelId: form.value.productModelId,
+ isQuality: form.value.isQuality,
dragSort,
});
@@ -432,12 +447,14 @@
id: form.value.id,
processId: form.value.processId,
productModelId: form.value.productModelId,
+ isQuality: form.value.isQuality,
})
: addOrUpdateProcessRouteItem({
routeId: routeId.value,
processId: form.value.processId,
productModelId: form.value.productModelId,
id: form.value.id,
+ isQuality: form.value.isQuality,
});
updatePromise
@@ -733,6 +750,10 @@
color: #409eff;
}
+.product-tag {
+ margin: 10px 0;
+}
+
.card-footer {
display: flex;
justify-content: space-around;
diff --git a/src/views/productionManagement/productionProcess/Edit.vue b/src/views/productionManagement/productionProcess/Edit.vue
index f979d51..8e92403 100644
--- a/src/views/productionManagement/productionProcess/Edit.vue
+++ b/src/views/productionManagement/productionProcess/Edit.vue
@@ -28,6 +28,9 @@
<el-form-item label="宸ヨ祫瀹氶" prop="salaryQuota">
<el-input v-model="formState.salaryQuota" type="number" :step="0.001" />
</el-form-item>
+ <el-form-item label="鏄惁璐ㄦ" prop="isQuality">
+ <el-switch v-model="formState.isQuality" :active-value="true" inactive-value="false"/>
+ </el-form-item>
<el-form-item label="澶囨敞" prop="remark">
<el-input v-model="formState.remark" type="textarea" />
</el-form-item>
@@ -67,6 +70,7 @@
no: props.record.no,
remark: props.record.remark,
salaryQuota: props.record.salaryQuota,
+ isQuality: props.record.isQuality,
});
const isShow = computed({
@@ -87,6 +91,7 @@
no: newRecord.no || '',
remark: newRecord.remark || '',
salaryQuota: newRecord.salaryQuota || '',
+ isQuality: props.record.isQuality,
};
}
}, { immediate: true, deep: true });
@@ -100,6 +105,7 @@
no: props.record.no || '',
remark: props.record.remark || '',
salaryQuota: props.record.salaryQuota || '',
+ isQuality: props.record.isQuality,
};
}
});
diff --git a/src/views/productionManagement/productionProcess/New.vue b/src/views/productionManagement/productionProcess/New.vue
index 7558ba7..5443e8d 100644
--- a/src/views/productionManagement/productionProcess/New.vue
+++ b/src/views/productionManagement/productionProcess/New.vue
@@ -28,6 +28,9 @@
<el-form-item label="宸ヨ祫瀹氶" prop="salaryQuota">
<el-input v-model="formState.salaryQuota" type="number" :step="0.001" />
</el-form-item>
+ <el-form-item label="鏄惁璐ㄦ" prop="isQuality">
+ <el-switch v-model="formState.isQuality" :active-value="true" inactive-value="false"/>
+ </el-form-item>
<el-form-item label="澶囨敞" prop="remark">
<el-input v-model="formState.remark" type="textarea" />
</el-form-item>
@@ -60,6 +63,7 @@
name: '',
remark: '',
salaryQuota: '',
+ isQuality: false,
});
const isShow = computed({
diff --git a/src/views/productionManagement/productionProcess/index.vue b/src/views/productionManagement/productionProcess/index.vue
index 67430cb..4f3f3ef 100644
--- a/src/views/productionManagement/productionProcess/index.vue
+++ b/src/views/productionManagement/productionProcess/index.vue
@@ -98,12 +98,18 @@
label: "宸ュ簭鍚嶇О",
prop: "name",
},
-
{
label: "宸ヨ祫瀹氶",
prop: "salaryQuota",
},
{
+ label: "鏄惁璐ㄦ",
+ prop: "isQuality",
+ formatData: (params) => {
+ return params ? "鏄�" : "鍚�";
+ },
+ },
+ {
label: "澶囨敞",
prop: "remark",
},
--
Gitblit v1.9.3