From 28997825e47018a0d9b3b8e4c003b232f62d241f Mon Sep 17 00:00:00 2001 From: hao <1836460075@qq.com> Date: 星期二, 20 五月 2025 18:49:57 +0800 Subject: [PATCH] 1 --- 夏蒙注塑报工/pages/scbg/scbg.vue | 75 +++++++++++++++++++++++++++++++++++-- 1 files changed, 70 insertions(+), 5 deletions(-) diff --git "a/\345\244\217\350\222\231\346\263\250\345\241\221\346\212\245\345\267\245/pages/scbg/scbg.vue" "b/\345\244\217\350\222\231\346\263\250\345\241\221\346\212\245\345\267\245/pages/scbg/scbg.vue" index 402fc22..9d42411 100644 --- "a/\345\244\217\350\222\231\346\263\250\345\241\221\346\212\245\345\267\245/pages/scbg/scbg.vue" +++ "b/\345\244\217\350\222\231\346\263\250\345\241\221\346\212\245\345\267\245/pages/scbg/scbg.vue" @@ -66,9 +66,13 @@ <text>闇�姹傚崟鎹細</text> <text>{{ orderDetails.requirementDoc }}</text> </view> - <view class="order-details-column"> + <!-- <view class="order-details-column"> <text>鎺ㄨ崘鍖呰鏁帮細</text> <text>{{ orderDetails.bzsl }}</text> + </view> --> + <view class="order-details-column"> + <text>宸ュ崟鐘舵�侊細</text> + <text>{{ orderDetails.gdzt }}</text> </view> </view> <view class="order-details-row"> @@ -189,7 +193,7 @@ <view class="header-item" id="tm">鎵撳嵃鏉$爜</view> <view class="header-item" id="sl">鎵撳嵃鏁伴噺</view> <view class="header-item" id="sj">鎵撳嵃鏃堕棿</view> - <view class="header-item" id="ry">鎵撳嵃浜�</view> + <view class="header-item" id="ry">鎶ュ伐浜�</view> </view> <!-- 琛ㄦ牸鍐呭 --> @@ -284,6 +288,7 @@ orderQuantity: '', // 璁㈠崟鏁伴噺 producedQuantity: '', // 宸茬敓浜ф暟 bzsl: '', // 鎺ㄨ崘鍖呰鏁� + gdzt:'', itemId: '', // 鐗╂枡ID itemNo: '', // 鐗╂枡缂栫爜 itemname: '', // 鐗╂枡鍚嶇О @@ -753,7 +758,7 @@ itemBarcode: record.itemBarcode || '鏈煡鏉$爜', // 纭繚瑙f瀽瀛楁 quantity: record.quantity || '鏈煡鏁伴噺', // 鎵撳嵃鏁伴噺瀛楁 printDate: record.printDate || '鏈煡鏃堕棿', // 鎵撳嵃鏃堕棿 - printedBy: record.printedBy || '鏈煡鐢ㄦ埛' // 鎵撳嵃浜� + printedBy: record.printedBy || '' // 鎶ュ伐浜� })); console.log('History records loaded:', this.historyList); } else { @@ -913,6 +918,7 @@ productionOrder: '', // 鐢熶骇璁㈠崟 orderQuantity: '', // 璁㈠崟鏁伴噺 bzsl: '', // 鎺ㄨ崘鍖呰鏁� + gdzt:'', producedQuantity: '', // 宸茬敓浜ф暟 itemId: '', // 鐗╂枡ID itemNo: '', // 鐗╂枡缂栫爜 @@ -941,6 +947,7 @@ productionOrder: res.data.productionOrder, // 鐢熶骇璁㈠崟 orderQuantity: res.data.orderQuantity, // 璁㈠崟鏁伴噺 bzsl: res.data.bzsl, // 鎺ㄨ崘鍖呰鏁� + gdzt: res.data.gdzt, // 宸ュ崟鐘舵�� producedQuantity: res.data.producedQuantity, // 宸茬敓浜ф暟 itemId: res.data.itemId, // 鐗╂枡ID itemNo: res.data.itemNO, // 鐗╂枡缂栫爜 @@ -1043,6 +1050,61 @@ }); } }); + + // 璋冪敤 API 鑾峰彇宸ュ崟璇︽儏 + uni.request({ + url: `http://192.168.0.107:44380/api/orderDetails?orderNo=${encodeURIComponent(this.orderNo)}`, // 浣跨敤瀛樺偍鐨刼rderNo + method: 'GET', + header: { + 'Content-Type': 'application/json' + }, + success: (res) => { + console.log('gongdanxinx', res.data); + if (res.statusCode === 200) { + this.orderDetails = { + requirementDoc: res.data.requirementDoc, // 闇�姹傚崟鎹� + productionOrder: res.data.productionOrder, // 鐢熶骇璁㈠崟 + orderQuantity: res.data.orderQuantity, // 璁㈠崟鏁伴噺 + bzsl: res.data.bzsl, // 鎺ㄨ崘鍖呰鏁� + gdzt: res.data.gdzt, // 宸ュ崟鐘舵�� + producedQuantity: res.data.producedQuantity, // 宸茬敓浜ф暟 + itemId: res.data.itemId, // 鐗╂枡ID + itemNo: res.data.itemNO, // 鐗╂枡缂栫爜 + itemname: res.data.itemname, // 鐗╂枡鍚嶇О + itemmodel: res.data.itemmodel, // 瑙勬牸鍨嬪彿 + + + }; + // 鏍规嵁 sj 鍜� xj 鐨勫�兼潵璁剧疆棣栨鍜屽贰妫�鐘舵�� + // 鏍规嵁 sj 鍜� xj 鐨勫�兼潵璁剧疆棣栨鍜屽贰妫�鐘舵�� + if (res.data.sj === 1) { + this.checkFirstPass = true; // 棣栨鍚堟牸 + } else if (res.data.sj === 2) { + this.checkFirstPass = false; // 棣栨涓嶅悎鏍� + } else { + this.checkFirstPass = null; // 棣栨鏈仛 + } + + if (res.data.xj === 1) { + this.checkXJ = true; // 宸℃鍚堟牸 + } else if (res.data.xj === 2) { + this.checkXJ = false; // 宸℃涓嶅悎鏍� + } else { + this.checkXJ = null; // 宸℃鏈仛 + } + + + console.log('Order details loaded:', this.orderDetails); + + } else { + console.error('Failed to fetch order details:', res); + } + }, + fail: (err) => { + console.error('Error fetching order details:', err); + } + }); + }, mapStatus(status) { if (status === 3) { @@ -1358,7 +1420,7 @@ // 绗洓閮ㄥ垎锛氭暟閲忎笌闇�姹傚崟鎹彿 command.setText(20, 340, "TSS24.BF2", 1, 1, "鏁伴噺: "); command.setText(120, 340, "TSS24.BF2", 1, 1, this.reportedQuantity); - command.setText(200, 340, "TSS24.BF2", 1, 1, "鎵撳嵃浜�: "); + command.setText(200, 340, "TSS24.BF2", 1, 1, "鎶ュ伐浜�: "); command.setText(290, 340, "TSS24.BF2", 1, 1, this.selectedPerson); @@ -1397,6 +1459,7 @@ } this.oldbgs = this.reportedQuantity; + this.bgr= //浠庢柊鍒锋柊宸ュ崟淇℃伅 loadOrderDetails(); //浠庢柊鍒锋柊鍘嗗彶璁板綍 @@ -1467,7 +1530,7 @@ }); } }); - + this.selectedPerson = this.lastRequestData.printedBy; // 琛ユ墦涓婁竴寮犺褰� this.fetchHistoryRecords(this.orderNo); if (!this.lastRequestData) { @@ -1478,6 +1541,8 @@ }); return; } + //20250507 鏂板姞璧嬪�煎巻鍙叉潯鐮佹姤宸ヤ汉 + this.selectedPerson = this.lastRequestData.printedBy; console.log("鑰佹潯鐮�", this.oldbgs); // 閲嶆柊鎵撳嵃涓婁竴寮犺褰� // async reprintLast() { -- Gitblit v1.9.3