From 4743d5644fb9c1a4d4a8038331526a0890a453e9 Mon Sep 17 00:00:00 2001
From: 张诺 <zhang_12370@163.com>
Date: 星期六, 25 四月 2026 14:21:38 +0800
Subject: [PATCH] feat: 在工艺路线相关界面添加开数、工艺正数和加放数字段
---
src/views/productionManagement/productStructure/Detail/index.vue | 3 +
src/views/productionManagement/productionOrder/BindRouteDialog.vue | 19 +++++----
src/views/productionManagement/productionDispatching/components/autoDispatchDia.vue | 2
src/views/productionManagement/workOrder/index.vue | 16 ++++---
src/views/productionManagement/processRoute/processRouteItem/index.vue | 40 +++++++++++++++++++-
src/views/productionManagement/productionOrder/index.vue | 4 +-
6 files changed, 63 insertions(+), 21 deletions(-)
diff --git a/src/views/productionManagement/processRoute/processRouteItem/index.vue b/src/views/productionManagement/processRoute/processRouteItem/index.vue
index c1c490c..141dba4 100644
--- a/src/views/productionManagement/processRoute/processRouteItem/index.vue
+++ b/src/views/productionManagement/processRoute/processRouteItem/index.vue
@@ -81,6 +81,9 @@
</el-table-column>
<el-table-column label="浜у搧鍚嶇О" prop="productName" min-width="160" />
<el-table-column label="瑙勬牸鍚嶇О" prop="model" min-width="140" />
+ <el-table-column label="寮�鏁�" prop="processRouteOpenNum" min-width="140" />
+ <el-table-column label="宸ヨ壓姝f暟" prop="processRouteNum" min-width="140" />
+ <el-table-column label="鍔犳斁鏁�" prop="processRouteAddNum" min-width="140" />
<el-table-column label="鍗曚綅" prop="unit" width="100" />
<el-table-column label="鏄惁璐ㄦ" prop="isQuality" width="100">
<template #default="scope">
@@ -186,7 +189,6 @@
: '閫夋嫨浜у搧' }}
</el-button>
</el-form-item>
-
<el-form-item label="鍗曚綅" prop="unit">
<el-input
v-model="form.unit"
@@ -271,6 +273,10 @@
productModelId: undefined,
productName: "",
model: "",
+ processName: "",
+ openCount: "",
+ processPositive: "",
+ allowanceQty: "",
unit: "",
isQuality: false,
});
@@ -329,7 +335,12 @@
productName: route.query.productName || '',
model: route.query.model || '',
bomNo: route.query.bomNo || '',
- description: route.query.description || ''
+ description: route.query.description || '',
+ processRouteAddNum:route.query.processRouteAddNum || '',
+ processRouteNum:route.query.processRouteNum || '',
+ processRouteName:route.query.processRouteName || '',
+ processRouteOpenNum:route.query.processRouteOpenNum || '',
+
};
};
@@ -350,6 +361,10 @@
productModelId: row.productModelId,
productName: row.productName || "",
model: row.model || "",
+ processName: row.processName || "",
+ openCount: row.openCount || "",
+ processPositive: row.processPositive || "",
+ allowanceQty: row.allowanceQty || "",
unit: row.unit || "",
isQuality: row.isQuality,
};
@@ -414,6 +429,10 @@
productRouteId: routeId.value,
processId: form.value.processId,
productModelId: form.value.productModelId,
+ processName: form.value.processName,
+ openCount: form.value.openCount,
+ processPositive: form.value.processPositive,
+ allowanceQty: form.value.allowanceQty,
isQuality: form.value.isQuality,
dragSort,
})
@@ -421,6 +440,10 @@
routeId: routeId.value,
processId: form.value.processId,
productModelId: form.value.productModelId,
+ processName: form.value.processName,
+ openCount: form.value.openCount,
+ processPositive: form.value.processPositive,
+ allowanceQty: form.value.allowanceQty,
isQuality: form.value.isQuality,
dragSort,
});
@@ -446,6 +469,10 @@
id: form.value.id,
processId: form.value.processId,
productModelId: form.value.productModelId,
+ processName: form.value.processName,
+ openCount: form.value.openCount,
+ processPositive: form.value.processPositive,
+ allowanceQty: form.value.allowanceQty,
isQuality: form.value.isQuality,
})
: addOrUpdateProcessRouteItem({
@@ -453,6 +480,10 @@
processId: form.value.processId,
productModelId: form.value.productModelId,
id: form.value.id,
+ processName: form.value.processName,
+ openCount: form.value.openCount,
+ processPositive: form.value.processPositive,
+ allowanceQty: form.value.allowanceQty,
isQuality: form.value.isQuality,
});
@@ -482,7 +513,12 @@
productModelId: undefined,
productName: "",
model: "",
+ processName: "",
+ openCount: "",
+ processPositive: "",
+ allowanceQty: "",
unit: "",
+ isQuality: false,
};
formRef.value?.resetFields();
};
diff --git a/src/views/productionManagement/productStructure/Detail/index.vue b/src/views/productionManagement/productStructure/Detail/index.vue
index e437a44..8feabe9 100644
--- a/src/views/productionManagement/productStructure/Detail/index.vue
+++ b/src/views/productionManagement/productStructure/Detail/index.vue
@@ -78,6 +78,9 @@
</el-form-item>
</template>
</el-table-column>
+ <el-table-column label="寮�鏁�" prop="processRouteOpenNum"/>
+ <el-table-column label="宸ヨ壓姝f暟" prop="processRouteNum"/>
+ <el-table-column label="鍔犳斁鏁�" prop="processRouteAddNum"/>
<el-table-column prop="unitQuantity"
label="鍗曚綅鐢ㄩ噺">
<template #default="{ row, $index }">
diff --git a/src/views/productionManagement/productionDispatching/components/autoDispatchDia.vue b/src/views/productionManagement/productionDispatching/components/autoDispatchDia.vue
index b4a76f6..8f17679 100644
--- a/src/views/productionManagement/productionDispatching/components/autoDispatchDia.vue
+++ b/src/views/productionManagement/productionDispatching/components/autoDispatchDia.vue
@@ -16,7 +16,7 @@
:row-class-name="tableRowClassName"
>
<el-table-column label="搴忓彿" type="index" width="60" align="center" />
- <el-table-column label="鍚堝悓鍙�" prop="salesContractNo" width="200" />
+ <el-table-column label="璁㈠崟缂栧彿" prop="salesContractNo" width="200" />
<el-table-column label="瀹㈡埛鍚嶇О" prop="customerName" width="200" />
<!-- <el-table-column label="椤圭洰鍚嶇О" prop="projectName" width="250" /> -->
<el-table-column label="浜у搧澶х被" prop="productCategory" width="150" />
diff --git a/src/views/productionManagement/productionOrder/BindRouteDialog.vue b/src/views/productionManagement/productionOrder/BindRouteDialog.vue
index e2b6337..c09754a 100644
--- a/src/views/productionManagement/productionOrder/BindRouteDialog.vue
+++ b/src/views/productionManagement/productionOrder/BindRouteDialog.vue
@@ -155,9 +155,9 @@
</el-descriptions-item>
</el-descriptions>
<!-- ================= 鍒囨枡鍥剧ず ================= -->
- <div class="section-title" v-if="formData.cuttingFileVo.length > 0">鍒囨枡鍥剧ず</div>
+ <div class="section-title" v-if="type === 'add' || (type === 'detail' && formData.cuttingFileVo.length > 0)">鍒囨枡鍥剧ず</div>
<ActionFileUpload
- v-if="formData.cuttingFileVo.length > 0"
+ v-if="type === 'add' || (type === 'detail' && formData.cuttingFileVo.length > 0)"
style="width: 50%;float: left;"
v-model:file-list="formData.cuttingFileVo"
:action="upload.url"
@@ -171,7 +171,7 @@
:onDownload="onDownload"
:onRemove="onRemove"
:onPreview="onPreview"
- :onView="type === 'detail' ? false : true"
+ :onView="type!=='detail'"
:tip-text="type === 'detail' ? '' : '鏀寔鍥剧墖锛坖pg, jpeg, png锛夋牸寮�'"
/>
<el-image
@@ -192,7 +192,7 @@
<el-input v-model="formData.cutNum" placeholder="鍒囨枡灏哄" :disabled="isDetail" />
</el-descriptions-item>
<el-descriptions-item label="鍒囨枡鏁伴噺" align="center">
- <el-input v-model="formData.cutSize" placeholder="鍒囨枡灏哄" :disabled="isDetail" />
+ <el-input v-model="formData.cutSize" placeholder="鍒囨枡鏁伴噺" :disabled="isDetail" />
</el-descriptions-item>
<el-descriptions-item label="涓洅鏁伴噺" align="center">
<el-input v-model="formData.mediumBoxQty" placeholder="涓洅鏁伴噺" :disabled="isDetail" />
@@ -451,6 +451,10 @@
headers: { Authorization: 'Bearer ' + getToken() }
})
+const showCuttingFile = computed(() => {
+ return props.type === 'detail' && Array.isArray(formData.cuttingFileVo) && formData.cuttingFileVo.length > 0
+})
+
const filePreviewRef = ref()
const formData = reactive({
productOrderList:null,
@@ -462,6 +466,7 @@
no: "",
productName: "",
productDescription: "",
+ cuttingDiagramCheckout:"",
clientName: "",
finishedSize: "",
cutNum: "",
@@ -484,7 +489,6 @@
],
processContent: [
{
- id: "1",
processId: "",
processName: "",
mediumBoxQty: "",
@@ -500,7 +504,6 @@
],
materialInfo: [
{
- id: "1",
productId: "",
name: "",
productModelId: "",
@@ -558,6 +561,7 @@
no: "",
productName: "",
productDescription: "",
+ cuttingDiagramCheckout:"骞冲紶",
clientName: "",
finishedSize: "",
cutNum: "",
@@ -580,7 +584,6 @@
],
processContent: [
{
- id: "1",
processId: "",
processName: "",
mediumBoxQty: "",
@@ -596,7 +599,6 @@
],
materialInfo: [
{
- id: "1",
productId: "",
name: "",
productModelId: "",
@@ -892,7 +894,6 @@
const addProcessRow = () => {
formData.processContent.push({
- id: Date.now().toString(),
processId: "",
processName: "",
openCount: "",
diff --git a/src/views/productionManagement/productionOrder/index.vue b/src/views/productionManagement/productionOrder/index.vue
index 0ad9ba4..ecf90d3 100644
--- a/src/views/productionManagement/productionOrder/index.vue
+++ b/src/views/productionManagement/productionOrder/index.vue
@@ -218,7 +218,7 @@
{
name: "缁戝畾宸ヨ壓璺嚎",
type: "text",
- showHide: row => !row.processRouteCode,
+ showHide: row => !row.printId,
clickFun: row => {
openBindRouteDialog(row);
},
@@ -226,7 +226,7 @@
{
name: "鏌ョ湅宸ヨ壓璺嚎",
type: "text",
- showHide: row => row.processRouteCode,
+ showHide: row => row.printId,
clickFun: row => {
openBindRouteDialog(row,"view");
},
diff --git a/src/views/productionManagement/workOrder/index.vue b/src/views/productionManagement/workOrder/index.vue
index fbb21cb..3834751 100644
--- a/src/views/productionManagement/workOrder/index.vue
+++ b/src/views/productionManagement/workOrder/index.vue
@@ -217,7 +217,7 @@
style="width: 300px"
>
<el-option
- v-for="user in userOptions"
+ v-for="user in userTeamOptions"
:key="user.userId"
:label="user.nickName"
:value="{ userId: user.userId, userName: user.nickName }"
@@ -305,6 +305,7 @@
<script setup>
import { onMounted, ref, nextTick, computed } from "vue";
+ import { deepClone } from "@/utils/index.js"
import { ElMessageBox, ElMessage } from "element-plus";
import dayjs from "dayjs";
import {
@@ -544,6 +545,7 @@
const workOrderFilesRef = ref(null);
const reportFormRef = ref(null);
const userOptions = ref([]);
+ const userTeamOptions = ref([]);
const reportForm = reactive({
planQuantity: 0,
quantity: null,
@@ -978,12 +980,12 @@
userListNoPageByTenantId()
.then(res => {
if (res.code === 200) {
- userOptions.value = res.data || [];
- console.log(userOptions.value)
- userOptions.value.unshift({
- nickName:"浠绘剰鐢ㄦ埛",
- userId:"-1",
- })
+ const list = Array.isArray(res.data) ? res.data : []
+ userOptions.value = [
+ { nickName: "浠绘剰鐢ㄦ埛", userId: "-1" },
+ ...deepClone(list)
+ ]
+ userTeamOptions.value = deepClone(list)
}
})
.catch(err => {
--
Gitblit v1.9.3