From 67fcba3d227790dfc9e3a50e35be0cde821c58e3 Mon Sep 17 00:00:00 2001
From: Administrator <2856754968@qq.com>
Date: 星期四, 06 十一月 2025 20:21:21 +0800
Subject: [PATCH] 111

---
 pages/index.vue |  176 ++++++++++++++++++++++++++++++----------------------------
 1 files changed, 91 insertions(+), 85 deletions(-)

diff --git a/pages/index.vue b/pages/index.vue
index fd3d8ad..0a14b72 100644
--- a/pages/index.vue
+++ b/pages/index.vue
@@ -12,23 +12,26 @@
 				璋冩満閫佹
 			</view>
 			<view class="tab-item" :class="{ active: currentTab === 2 }" @click="changeTab(2)">
-				鎹㈡ā
-			</view>
-			<view class="tab-item" :class="{ active: currentTab === 1 }" @click="changeTab(1)">
-				寮�宸ュ畬宸�
+				鍒�鍏风鐞�
 			</view>
 			<view class="tab-item" :class="{ active: currentTab === 4 }" @click="changeTab(4)">
-				鎵撶爜鎶ュ伐
+				鐢熶骇鎶ュ伐
 			</view>
+			<!-- <view class="tab-item" :class="{ active: currentTab === 1 }" @click="changeTab(1)">
+				寮�宸ュ畬宸�
+			</view> -->
 			<view class="tab-item" :class="{ active: currentTab === 5 }" @click="changeTab(5)">
 				e-SOP
 			</view>
 			<view class="tab-item" :class="{ active: currentTab === 6 }" @click="changeTab(6)">
 				宸ヨ壓鍙傛暟
 			</view>
-			<view class="tab-item" :class="{ active: currentTab === 8 }" @click="changeTab(8)">
-				鎵撳嵃鏈鸿缃�
+			<view class="tab-item" :class="{ active: currentTab === 9 }" @click="changeTab(9)">
+				璁惧鐐规
 			</view>
+			<!-- <view class="tab-item" :class="{ active: currentTab === 8 }" @click="changeTab(8)">
+				鎵撳嵃鏈鸿缃�
+			</view> -->
 
 		</view>
 		<view class="font"></view>
@@ -38,9 +41,9 @@
 					<view class="top-right">
 						<button class="refresh-btn" @click="refresh">鍒锋柊</button>
 					</view>
-					<view>
+					<!--<view>
 						<h4>涓�鍙版満鍙板彧鑳介�夋嫨涓�鏉″伐鍗曪紙澶氶�夐粯璁や负鏈�鍚庝竴鏉★級</h4>
-					</view>
+					</view>-->
 					<view class="section top-section">
 						<view class="form-row">
 							<view>
@@ -126,11 +129,10 @@
 					</view>
 
 					<view>
-						<text style="color: red;">
-							璇存槑:鍒濆鐘舵�佹槸锛屾寜榻胯疆鏈烘煡鍑烘墍鏈夌殑鏈畬宸ョ殑宸ュ崟銆傜敤閫夋嫨妗嗘爣璇嗘満鍣ㄨ寮�宸ョ殑宸ュ崟.
-							鍙兘鍚屾椂寮�宸ヤ竴涓伐鍗曪紝澶氶�夐粯璁や负鏈�鍚庝竴涓�傞�夋嫨瀹屾垚锛岀偣鍑讳繚瀛橀�夋嫨銆傜郴缁熶繚鐣欓�変腑鐨勫伐鍗曘��
+						<!--<text style="color: red;">
+							璇存槑:鍙兘鍚屾椂寮�宸ヤ竴涓伐鍗曘�傞�夋嫨瀹屾垚锛岀偣鍑讳繚瀛橀�夋嫨銆傜郴缁熶繚鐣欓�変腑鐨勫伐鍗曘��
 							濡傛灉瑕侀噸閫夛紝鐐瑰嚮娓呯┖閲嶉�夊姛鑳姐��
-						</text>
+						</text>-->
 					</view>
 				</view>
 			</view>
@@ -163,6 +165,10 @@
 			</view>
 			<view v-if="currentTab === 6" class="tab-content">
 				<Technology :orderId="orderId" :orderNo="selectedOrder" :machineNo="machineNo" />
+			</view>
+			<view v-if="currentTab === 9" class="tab-content">
+				<!-- 璁惧鐐规瑙嗗浘 -->
+				<EquipmentInspection :machineNo="machineNo" />
 			</view>
 		</scroll-view>
 
@@ -249,16 +255,17 @@
 </template>
 
 <script>
-	import WorkOrderStatus from '../components/WorkOrderStatus.vue'; // 纭繚璺緞姝g‘
-	import UniTable from "../uni_modules/uni-table/components/uni-table/uni-table.vue";
-	import Mold from "../components/mold.vue";
-	import Machine from "../components/machine.vue";
-	import WorkOrderPrint from "../components/WorkOrderPrint.vue";
-	import WorkOrder from "../components/WorkOrder.vue";
-	import Technology from "../components/Technology.vue";
-	import PDFShow from "../components/PDFShow.vue";
-	import PrintInit from "../components/PrintInit.vue";
-	import PrintTest from "../components/PrintTest.vue";
+import WorkOrderStatus from '../components/WorkOrderStatus.vue'; // 纭繚璺緞姝g‘
+import UniTable from "../uni_modules/uni-table/components/uni-table/uni-table.vue";
+import Mold from "../components/mold.vue";
+import Machine from "../components/machine.vue";
+import WorkOrderPrint from "../components/WorkOrderPrint.vue";
+import WorkOrder from "../components/WorkOrder.vue";
+import Technology from "../components/Technology.vue";
+import PDFShow from "../components/PDFShow.vue";
+import PrintInit from "../components/PrintInit.vue";
+import PrintTest from "../components/PrintTest.vue";
+import EquipmentInspection from "../components/EquipmentInspection.vue";
 
 	export default {
 		components: {
@@ -271,12 +278,16 @@
 			WorkOrderStatus,
 			PDFShow,
 			PrintInit,
-			PrintTest
+			PrintTest,
+			EquipmentInspection
 		},
 		data() {
 			return {
                 orderStatus: '', // 榛樿鍏ㄩ儴
 				currentTab: 7,
+
+                productCode: '', // 浜у搧缂栫爜
+                productSpec: '', // 浜у搧瑙勬牸
 
 				machineList: [],
 
@@ -394,9 +405,9 @@
 				this.getWomdaaIsShow();
 			},
 			getPrintInfo() {
-				var mac = "ac:f4:2c:20:0d:b4";
+				var mac = "";
 				
-				mac = "e8:51:9e:7d:dc:95";
+				mac = "74:24:ca:4f:b7:9b";
 				this.$post({
 					url: "/DevMachine/GetDevMachineByPdaMac",
 					data: {
@@ -414,45 +425,46 @@
 
 					this.getWomdaaIsShow();
 				});
+				return;
 				
 				
-	// 			if (plus.os.name == "Android") {
-	// 				//鑾峰彇鎵嬫満MAC鍦板潃
-	// 				var Context = plus.android.importClass("android.content.Context");
-	// 				var WifiManager = plus.android.importClass("android.net.wifi.WifiManager");
-	// 				var wifiManager = plus.android.runtimeMainActivity().getSystemService(Context.WIFI_SERVICE);
-	// 				var WifiInfo = plus.android.importClass("android.net.wifi.WifiInfo");
-	// 				var wifiInfo = wifiManager.getConnectionInfo();
-	// 				mac = wifiInfo.getMacAddress();
+	 			if (plus.os.name == "Android") {
+	 				//鑾峰彇鎵嬫満MAC鍦板潃
+	 				var Context = plus.android.importClass("android.content.Context");
+	 				var WifiManager = plus.android.importClass("android.net.wifi.WifiManager");
+	 				var wifiManager = plus.android.runtimeMainActivity().getSystemService(Context.WIFI_SERVICE);
+	 				var WifiInfo = plus.android.importClass("android.net.wifi.WifiInfo");
+	 				var wifiInfo = wifiManager.getConnectionInfo();
+	 				mac = wifiInfo.getMacAddress();
 					
-	// 				//濡傛灉mac涓衡��02:00:00:00:00:00鈥濓紝鍒欏彲鑳芥槸瀹夊崜6.0浠ヤ笂鐗堟湰锛屽垯浣跨敤鍙︿竴绉嶆柟娉曡幏鍙杕ac鍦板潃
-	// 				if (mac == "02:00:00:00:00:00") {
-	// 					mac = this.getMacNew();
-	// 				}
-	// 				//濡傛灉mac浣跨敤鏂版柟娉曚緷鐒舵槸鈥�02:00:00:00:00:00鈥濆垯涓嶈繘琛屼繚瀛�
-	// 				if (mac == "02:00:00:00:00:00") {
-	// 					return;
-	// 				}
-	// 				uni.setStorageSync('pdaMac', mac);
+	 				//濡傛灉mac涓衡��02:00:00:00:00:00鈥濓紝鍒欏彲鑳芥槸瀹夊崜6.0浠ヤ笂鐗堟湰锛屽垯浣跨敤鍙︿竴绉嶆柟娉曡幏鍙杕ac鍦板潃
+	 				if (mac == "02:00:00:00:00:00") {
+	 					mac = this.getMacNew();
+	 				}
+	 				//濡傛灉mac浣跨敤鏂版柟娉曚緷鐒舵槸鈥�02:00:00:00:00:00鈥濆垯涓嶈繘琛屼繚瀛�
+	 				if (mac == "02:00:00:00:00:00") {
+	 					return;
+	 				}
+	 				uni.setStorageSync('pdaMac', mac);
 
-	// 				this.$post({
-	// 					url: "/DevMachine/GetDevMachineByPdaMac",
-	// 					data: {
-	// 						pdaMac: mac,
-	// 					}
-	// 				}).then(res => {
-	// 					let devMachine = res.data.tbBillList;
-	// 					this.machineNo = devMachine.machineNo;
-	// 					this.machineName = "褰撳墠鏈哄彴锛�" + this.machineNo + "鍙锋敞濉戞満";
+	 				this.$post({
+	 					url: "/DevMachine/GetDevMachineByPdaMac",
+	 					data: {
+	 						pdaMac: mac,
+	 					}
+	 				}).then(res => {
+	 					let devMachine = res.data.tbBillList;
+	 					this.machineNo = devMachine.machineNo;
+	 					this.machineName = "褰撳墠鏈哄彴锛�" + this.machineNo + "鍙烽娇杞満";
 
-	// 					uni.setStorageSync('machineNo', this.machineNo);
-	// 					uni.setStorageSync('printMac', devMachine.printMac);
+	 					uni.setStorageSync('machineNo', this.machineNo);
+	 					uni.setStorageSync('printMac', devMachine.printMac);
  
 
-	// 					this.getWomdaaIsShow();
+	 					this.getWomdaaIsShow();
 
-	// 				});
-	// 			}
+	 				});
+	 			}
 			},
 			save() {
 				let data = this.selectedItems();
@@ -568,12 +580,8 @@
 				return `${year}-${month}-${day}`; // 杩斿洖鏍煎紡鍖栧悗鐨勫瓧绗︿覆
 			},
 			selectionChange(e) {
-                // 鍙繚鐣欐渶鍚庝竴涓�変腑鐨勫伐鍗�
-                if (Array.isArray(e.detail.index)) {
-                    this.selectedIndexs = [e.detail.index[e.detail.index.length - 1]];
-                } else {
-                    this.selectedIndexs = [e.detail.index];
-                }
+                // 鍗曢�夌洿鎺ヨ祴鍊�
+                this.selectedIndexs = [e.detail.index];
 			},
 
 			selectedItems() {
@@ -637,29 +645,25 @@
 				});
 			},
 
-			isShowTab() {
+            isShowTab() {
+                if (this.isShowTableData.length > 0) {
+                    uni.showToast({
+                        title: '宸叉湁姝e湪鎿嶄綔鐨勫伐鍗曪紝涓嶈兘鍐嶆閫夋嫨',
+                        icon: 'error',
+                        duration: 2000
+                    });
+                    return;
+                }
 
-				if (this.isShowTableData.length > 0) {
-					uni.showToast({
-						title: '宸叉湁姝e湪鎿嶄綔鐨勫伐鍗曪紝涓嶈兘鍐嶆閫夋嫨',
-						//灏嗗�艰缃负 success 鎴栬�呯洿鎺ヤ笉鐢ㄥ啓icon杩欎釜鍙傛暟
-						icon: 'error',
-						//鏄剧ず鎸佺画鏃堕棿涓� 2绉�
-						duration: 2000
-					});
-
-					return;
-				}
-
-				this.isShow = true;
-
-				this.engineeringNo = null;
-				this.tableData = [];
+                this.isShow = true;
+                // 榛樿閫変腑鈥滃緟寮�宸モ��
+                this.engineeringNo = '寰呭紑宸�';
+                this.tableData = [];
                 // 涓嬫媺妗嗗彧鏄剧ず宸ュ崟鐘舵��
-                this.engineeringNoMapList = ['寰呭紑宸�', '鏈紑宸�', '瀹屽伐', '鏆傚仠'];
-                // 榛樿鏄剧ず鍏ㄩ儴宸ュ崟
-                this.getWomdaa();
-			},
+                this.engineeringNoMapList = ['寰呭紑宸�', '鏈紑宸�', '寮�宸�', '鏆傚仠', '瀹屽伐'];
+                // 榛樿鏄剧ず鈥滃緟寮�宸モ�濆伐鍗�
+                this.getWomdaaByStatus();
+            },
             // 涓嬫媺妗嗛�変腑鍚庯紝鎸夌姸鎬佺瓫閫夊伐鍗�
             onEngineeringNoChange(status) {
                 this.engineeringNo = status;
@@ -696,6 +700,8 @@
 			toDetail(item) {
 				this.orderId = item.id;
 				this.selectedOrder = item.daa001;
+                this.productCode = item.daa002; // 浜у搧缂栫爜
+                this.productSpec = item.daa004; // 浜у搧瑙勬牸
 				this.currentTab = 0;
 			}
 		},
@@ -1001,4 +1007,4 @@
 			font-size: 20px;
 		}
 	}
-</style>
\ No newline at end of file
+</style>

--
Gitblit v1.9.3