From bbc93d7a5c22bf006502f2515e2200cdfe8f6a62 Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期一, 12 一月 2026 19:03:03 +0800
Subject: [PATCH] 双奇点app: 1.扫码改成可连续扫码,加一个导出excel功能

---
 src/pages/index.vue |  183 +++------------------------------------------
 1 files changed, 15 insertions(+), 168 deletions(-)

diff --git a/src/pages/index.vue b/src/pages/index.vue
index ebff4e6..514c546 100644
--- a/src/pages/index.vue
+++ b/src/pages/index.vue
@@ -11,26 +11,11 @@
 		<view class="hero-section">
 			<view class="bg-img">
 				<view class="hero-content">
-					<text class="hero-title">鍙屽鐐�</text>
+					<text class="hero-title">澶╂触鍙屽鐐�</text>
 				</view>
 				<view class="hero-wave"></view>
 			</view>
 		</view>
-		
-		<!--		<view class="notice-section">-->
-		<!--			<view class="notice">-->
-		<!--				<view class="notice-content">-->
-		<!--					<view class="notice-left">-->
-		<!--						<text class="notice-status">閫氱煡</text>-->
-		<!--					</view>-->
-		<!--					<view class="notice-separator"></view>-->
-		<!--					<view class="notice-right">-->
-		<!--						<text class="notice-label">{{currentStatus}}</text>-->
-		<!--						<text class="notice-text">褰撴棩閿�鍞澶囨暟:<text class="notice-number">{{number}}<text class="notice-unit">涓�</text></text></text>-->
-		<!--					</view>-->
-		<!--				</view>-->
-		<!--			</view>-->
-		<!--		</view>-->
 		<!-- 浠撳偍鐗╂祦妯″潡 -->
 		<view class="common-module marketing-module">
 			<view class="module-header">
@@ -60,156 +45,8 @@
 				</up-grid>
 			</view>
 		</view>
-		<!-- 钀ラ攢绠$悊妯″潡 -->
-		<view class="common-module marketing-module">
-			<view class="module-header">
-				<view class="module-title-container">
-					<text class="module-title">钀ラ攢绠$悊</text>
-				</view>
-			</view>
-			<view class="module-content">
-				<up-grid
-					:border="false"
-					col="4"
-				>
-					<up-grid-item
-						v-for="(item, index) in marketingItems"
-						:key="index"
-						@click="handleCommonItemClick(item)"
-					>
-						<view class="icon-container" :style="{ background: item.bgColor }">
-							<up-icon
-								:name="item.icon"
-								:size="58"
-								color="#ffffff"
-							></up-icon>
-						</view>
-						<text class="item-label">{{item.label}}</text>
-					</up-grid-item>
-				</up-grid>
-			</view>
-		</view>
-		
-		<!-- 閲囪喘绠$悊妯″潡 -->
-		<view class="common-module purchase-module">
-			<view class="module-header">
-				<view class="module-title-container">
-					<text class="module-title">閲囪喘绠$悊</text>
-				</view>
-			</view>
-			<view class="module-content">
-				<up-grid
-					:border="false"
-					col="4"
-				>
-					<up-grid-item
-						v-for="(item, index) in purchaseItems"
-						:key="index"
-						@click="handleCommonItemClick(item)"
-					>
-						<view class="icon-container" :style="{ background: item.bgColor }">
-							<up-icon
-								:name="item.icon"
-								:size="58"
-								color="#ffffff"
-							></up-icon>
-						</view>
-						<text class="item-label">{{item.label}}</text>
-					</up-grid-item>
-				</up-grid>
-			</view>
-		</view>
-		
-		<!-- 鍗忓悓鍔炲叕妯″潡 -->
-		<view class="common-module collaboration-module">
-			<view class="module-header">
-				<view class="module-title-container">
-					<text class="module-title">鍗忓悓鍔炲叕</text>
-				</view>
-			</view>
-			<view class="module-content">
-				<up-grid
-					:border="false"
-					col="4"
-				>
-					<up-grid-item
-						v-for="(item, index) in collaborationItems"
-						:key="index"
-						@click="handleCommonItemClick(item)"
-					>
-						<view class="icon-container" :style="{ background: item.bgColor }">
-							<up-icon
-								:name="item.icon"
-								:size="58"
-								color="#ffffff"
-							></up-icon>
-						</view>
-						<text class="item-label">{{item.label}}</text>
-					</up-grid-item>
-				</up-grid>
-			</view>
-		</view>
-		
-		<!-- 鐢熶骇绠℃帶妯″潡 -->
-		<view class="common-module production-module">
-			<view class="module-header">
-				<view class="module-title-container">
-					<text class="module-title">鐢熶骇绠℃帶</text>
-				</view>
-			</view>
-			<view class="module-content">
-				<up-grid
-					:border="false"
-					col="4"
-				>
-					<up-grid-item
-						v-for="(item, index) in productionItems"
-						:key="index"
-						@click="handleCommonItemClick(item)"
-					>
-						<view class="icon-container" :style="{ background: item.bgColor }">
-							<up-icon
-								:name="item.icon"
-								:size="58"
-								color="#ffffff"
-							></up-icon>
-						</view>
-						<text class="item-label">{{item.label}}</text>
-					</up-grid-item>
-				</up-grid>
-			</view>
-		</view>
-		
-		<!-- 璁惧绠$悊妯″潡 -->
-		<view class="common-module equipment-module">
-			<view class="module-header">
-				<view class="module-title-container">
-					<text class="module-title">璁惧绠$悊</text>
-				</view>
-			</view>
-			<view class="module-content">
-				<up-grid
-					:border="false"
-					col="4"
-				>
-					<up-grid-item
-						v-for="(item, index) in equipmentItems"
-						:key="index"
-						@click="handleCommonItemClick(item)"
-					>
-						<view class="icon-container" :style="{ background: item.bgColor }">
-							<up-icon
-								:name="item.icon"
-								:size="58"
-								color="#ffffff"
-							></up-icon>
-						</view>
-						<text class="item-label">{{item.label}}</text>
-					</up-grid-item>
-				</up-grid>
-			</view>
-		</view>
 		<GoodsDetailPopup ref="refGoodsDetailPopup"></GoodsDetailPopup>
+		<ScanListPopup ref="refScanListPopup"></ScanListPopup>
 	</view>
 </template>
 
@@ -220,6 +57,7 @@
 import modal from "@/plugins/modal";
 import useUserStore from "@/store/modules/user";
 import GoodsDetailPopup from './components/GoodsDetailPopup.vue';
+import ScanListPopup from './components/ScanListPopup.vue';
 
 const userStore = useUserStore()
 const factoryId = ref('');
@@ -566,7 +404,7 @@
 			});
 			break
 		case '浜у搧鎵爜':
-			scanQRCode()
+			openScanListPopup()
 			break
 		default:
 			uni.showToast({
@@ -602,7 +440,7 @@
 	show.value = false;
 	const factoryId = factoryListTem.value[arr.indexs[0]].deptId
 	const loginForm = {
-		username: userStore.name,
+		userName: userStore.name,
 		password: uni.getStorageSync('remembered_password'),
 		factoryId: factoryId,
 	}
@@ -629,11 +467,12 @@
 		onlyFromCamera:true,
 		scanType:['barCode','qrCode'],
 		success(res) {
+			console.log(res)
 			searchDetail(res.result||'')
 		},
 		fail(res) {
 			uni.showToast({
-				title: res.errMsg||'鎵爜澶辫触',
+				title: '鍙栨秷鎵爜',
 				icon: 'none',
 				duration: 1500
 			})
@@ -643,6 +482,14 @@
 
 //璋堟鐩稿叧
 const refGoodsDetailPopup = ref(null)
+const refScanListPopup = ref(null)
+
+//鎵撳紑鎵爜鍒楄〃寮圭獥
+const openScanListPopup = () => {
+	if (refScanListPopup.value) {
+		refScanListPopup.value.open()
+	}
+}
 
 
 //鏌ョ湅璇︽儏

--
Gitblit v1.9.3