From cd1ce9f919db0a2d7a588cedc81ce4310c3310c4 Mon Sep 17 00:00:00 2001
From: spring <2396852758@qq.com>
Date: 星期二, 18 十一月 2025 16:29:10 +0800
Subject: [PATCH] fix: PDA芯线层可以扫码单丝二维码
---
src/pages/index/index.vue | 9 +++++----
src/pages/production/twist/receive/steelCore/index.vue | 9 +++++++++
2 files changed, 14 insertions(+), 4 deletions(-)
diff --git a/src/pages/index/index.vue b/src/pages/index/index.vue
index 4e045ba..46174fc 100644
--- a/src/pages/index/index.vue
+++ b/src/pages/index/index.vue
@@ -250,14 +250,15 @@
const { data } = await HomeApi.getIndex();
// 鍒ゆ柇鏄惁涓哄贰妫�鍛樿鑹�
- if (isInspector.value) {
- // 濡傛灉鏄贰妫�鍛橈紝鏄剧ず宸℃鑿滃崟
- navList[2].show = true;
- } else if (data.deviceGroupName == "鏃舵晥缁�") {
+ if (data.deviceGroupName == "鏃舵晥缁�") {
navList[1].show = true;
} else {
navList[0].show = true;
}
+ if (isInspector.value) {
+ // 濡傛灉鏄贰妫�鍛橈紝鏄剧ず宸℃鑿滃崟
+ navList[2].show = true;
+ }
};
/**
diff --git a/src/pages/production/twist/receive/steelCore/index.vue b/src/pages/production/twist/receive/steelCore/index.vue
index fd54201..1e6b91c 100644
--- a/src/pages/production/twist/receive/steelCore/index.vue
+++ b/src/pages/production/twist/receive/steelCore/index.vue
@@ -172,6 +172,15 @@
try {
const parseData = JSON.parse(code.code);
+ // 妫�鏌ュ繀闇�瀛楁锛歮odel銆乻upplier銆乨iskMaterial
+ const requiredFields = ["model", "supplier", "diskMaterial"];
+ const missingFields = requiredFields.filter((field) => !parseData[field]);
+
+ if (missingFields.length > 0) {
+ toast.error(`浜岀淮鐮侀敊璇紝璇锋洿鎹簩缁寸爜锛乣);
+ return;
+ }
+
// 鎵撳紑鏂板寮规骞跺~鍏呮壂鐮佽幏鍙栫殑淇℃伅
addDialog.visible = true;
--
Gitblit v1.9.3