From e0fc86fda41a8777a0cec5a9de7aa9f1474f5dc8 Mon Sep 17 00:00:00 2001
From: spring <2396852758@qq.com>
Date: 星期四, 08 十月 2026 17:09:52 +0800
Subject: [PATCH] fix: 库存操作原型绘制。单丝领用,添加字段
---
src/pages/production/twist/report/index.vue | 22 ++++++++++++++++++++++
1 files changed, 22 insertions(+), 0 deletions(-)
diff --git a/src/pages/production/twist/report/index.vue b/src/pages/production/twist/report/index.vue
index 7a90a68..18ef6a4 100644
--- a/src/pages/production/twist/report/index.vue
+++ b/src/pages/production/twist/report/index.vue
@@ -221,7 +221,29 @@
}
};
+// 蹇呴』鏈夌洏鍏烽鐢ㄨ褰曟墠鑳芥姤宸ワ細鎺ュ彛寮傚父鏃朵笉鎷︽埅锛堥伩鍏嶇綉缁滈棶棰橀樆鏂敓浜э級锛�
+// 鍙湁鏄庣‘鏌ヨ鎴愬姛涓旀病鏈変换浣曠洏鍏烽鐢ㄦ椂鎵嶆嫤鎴��
+const ensureReelDish = async () => {
+ try {
+ const { code, data } = await ManageApi.getStrandedWireDish({
+ wireId: paramsId.value,
+ type: "鐩樺叿",
+ });
+ if (code !== 200) return true;
+ const list = Array.isArray(data) ? data : [];
+ if (list.length === 0) {
+ toast.warning("璇峰厛鍦ㄣ�愮洏鍏烽鐢ㄣ�戜腑鎵爜棰嗙敤鐩樺叿锛屽啀杩涜缁炵嚎鎶ュ伐");
+ return false;
+ }
+ return true;
+ } catch (error) {
+ return true;
+ }
+};
+
const addReport = async () => {
+ // 蹇呴』鏈夌洏鍏烽鐢ㄨ褰曟墠鑳界粸绾挎姤宸�
+ if (!(await ensureReelDish())) return;
// 妫�鏌ユ槸鍚︽墍鏈夋暟鎹兘宸蹭繚瀛橈紙閮芥湁id锛�
if (twistReportList.value.length > 0 && twistReportList.value.every((item) => item.id)) {
// 纭繚涓昏〃鏁版嵁宸茶幏鍙�
--
Gitblit v1.9.3