From 8892813b4bc8455ae2f08cf47a3feb55fa801435 Mon Sep 17 00:00:00 2001
From: fengyuan_yang <1976974459@qq.com>
Date: Tue, 27 Jan 2026 10:10:14 +0800
Subject: [PATCH] =?UTF-8?q?2026-01-27=20=E4=BC=98=E5=8C=96?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../searchMaterialOnMachineRecord.vue | 2 +-
.../modules/yieldReport/produce_order.vue | 26 ++++++++++++-------
2 files changed, 17 insertions(+), 11 deletions(-)
diff --git a/src/views/modules/schedule/searchMaterialOnMachineRecord.vue b/src/views/modules/schedule/searchMaterialOnMachineRecord.vue
index 4375076..4ceb7c3 100644
--- a/src/views/modules/schedule/searchMaterialOnMachineRecord.vue
+++ b/src/views/modules/schedule/searchMaterialOnMachineRecord.vue
@@ -196,7 +196,7 @@
label="操作">
打印
- 异常退料
+ 异常退料
- *机台编号:
+ 机台编号:
@@ -46,7 +46,7 @@
-
+
{{ labels.showFinishedSeqNo }}
@@ -1808,9 +1808,11 @@ export default {
/* 查询派工单 */
getProduceScheduleList() {
- // 校验机台编号必填
- if (!this.searchData.resourceId || this.searchData.resourceId.trim() === '') {
- this.$message.warning('请输入机台编号!')
+ // 校验:派工单号和机台必须填一个
+ const hasResourceId = this.searchData.resourceId && this.searchData.resourceId.trim() !== ''
+ const hasSeqNo = this.searchData.seqNo && this.searchData.seqNo.trim() !== ''
+ if (!hasResourceId && !hasSeqNo) {
+ this.$message.warning('派工单号和机台必须填一个!')
return
}
// 开始真的查询;
@@ -2229,9 +2231,11 @@ export default {
//导出excel
async createExportData() {
- // 校验机台编号必填
- if (!this.searchData.resourceId || this.searchData.resourceId.trim() === '') {
- this.$message.warning('请输入机台编号!')
+ // 校验:派工单号和机台必须填一个
+ const hasResourceId = this.searchData.resourceId && this.searchData.resourceId.trim() !== ''
+ const hasSeqNo = this.searchData.seqNo && this.searchData.seqNo.trim() !== ''
+ if (!hasResourceId && !hasSeqNo) {
+ this.$message.warning('派工单号和机台必须填一个!')
return []
}
// 开始真的查询;
@@ -2268,8 +2272,10 @@ export default {
}
// 等待getResourceByUser执行完成后,再查询生产排程列表
- // 只有当机台编号有值时才查询
- if (this.searchData.resourceId && this.searchData.resourceId.trim() !== '') {
+ // 只有当机台编号或派工单号有值时才查询
+ const hasResourceId = this.searchData.resourceId && this.searchData.resourceId.trim() !== ''
+ const hasSeqNo = this.searchData.seqNo && this.searchData.seqNo.trim() !== ''
+ if (hasResourceId || hasSeqNo) {
this.searchData.searchFlag = true;
getProduceScheduleList(this.searchData).then(({data}) => {
// 设置查询数据