From dcdb0231034810232f2542f3865666ebf72daf11 Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期三, 30 四月 2025 16:45:34 +0800
Subject: [PATCH] sf

---
 h5/pages/index/index.vue |   78 +++++++++++++++++++-------------------
 1 files changed, 39 insertions(+), 39 deletions(-)

diff --git a/h5/pages/index/index.vue b/h5/pages/index/index.vue
index 3a3651d..4ac7cd0 100644
--- a/h5/pages/index/index.vue
+++ b/h5/pages/index/index.vue
@@ -2,8 +2,8 @@
 	<view class="box">
 		<view class="box_bg" :style="{backgroundImage: 'url(' + Config.resourcePath + Config.bgImg + ')'}"></view>
 		<view class="box_user">
-			<text>娆㈣繋{{User.username}}鐧诲綍</text>
-			<view class="box_user_btn" @click="loginOut">閫�鍑虹櫥褰�</view>
+			<text>{{User.username}}</text>
+			<image src="@/static/ic_logout@2x.png" mode="widthFix" @click="loginOut"></image>
 		</view>
 		<view class="box_content" :style="{maxWidth: Config.rangeSize + 'px', minWidth: Config.rangeSize + 'px'}">
 			<!-- 骞垮憡鍥� -->
@@ -234,7 +234,7 @@
 										<view class="label">{{child.name}}锛�</view>
 										<view class="value">{{child.val}}</view>
 									</view>
-									<view v-if="item.param2" class="paramline"></view>
+									<view v-if="item.param2.length>0" class="paramline"></view>
 									<view class="item" v-if="item.param2" v-for="(child, j) in item.param2" :key="child.index">
 										<view class="label">{{child.name}}锛�</view>
 										<view class="value">{{child.val}}</view>
@@ -245,16 +245,6 @@
 					</view>
 				</view>
 			</template>
-			
-			<!-- 鏌ョ湅澶у浘 -->
-			<bigImg
-				ref="bigImg"
-				:imgList="imgList"/>
-			<!-- 鏌ョ湅澶у浘 -->
-			<bigImg1
-				ref="bigImg1"
-				:imgList="imgList"/>
-			<!-- 鎼滅储 -->
 			
 			<!-- 鎼滅储缁勪欢 -->
 			<search
@@ -270,12 +260,10 @@
 </template>
 
 <script>
-	import bigImg from '@/components/bigImg.vue'
-	import bigImg1 from '@/components/bigImg1.vue'
 	import search from '@/components/search.vue'
 	import noData from '@/components/noData.vue'
 	import { mapState } from 'vuex'
-	import { categoryList, goodsList, brandList, h5Image, goodsPage, listForH5 } from '@/apis/index.js'
+	import { categoryList, goodsList, brandList, h5Image, goodsPage, listForH5, logout } from '@/apis/index.js'
 	export default {
 		data() {
 			return {
@@ -352,7 +340,7 @@
 				page: 1
 			}
 		},
-		components: { bigImg, search, noData, bigImg1 },
+		components: { search, noData },
 		onLoad() {
 			var that = this
 			// 鐩戝惉閿洏缁勫悎閿�
@@ -435,6 +423,14 @@
 					}
 				}
 			}
+		},
+		onUnload() {
+			//娓呴櫎
+			document.onmouseup = function(ev){
+			    document.onmousemove = null;
+			}
+			//娓呴櫎
+			document.onkeydown = null
 		},
 		computed: {
 			// 鎸囧浠锋�昏
@@ -551,8 +547,11 @@
 			},
 			// 閫�鍑�
 			loginOut() {
-				this.$store.commit('clean')
-				uni.redirectTo({ url: '/pages/login/login' });
+				logout({})
+					.then(res => {
+						this.$store.commit('clean')
+						uni.redirectTo({ url: '/pages/login/login' });
+					})
 			},
 			// 鏌ヨ鍟嗗搧鏁版嵁
 			getShopList(type) {
@@ -708,12 +707,10 @@
 						})
 					}
 				})
-				// console.log(this.imgList)
+				if (this.imgList.length === 0) return
 				this.$viewerApi({
 				  images: this.imgList,
 				})
-				// this.$refs.bigImg.open(0)
-				// this.$refs.bigImg1.open(0)
 			},
 			empty() {
 				this.shopList = []
@@ -843,6 +840,7 @@
 				this.shopList[index].zdPrice = ''
 				this.shopList[index].price = ''
 				this.shopList[index].xhData = []
+				this.shopList[index].multifileList = []
 				this.shopList[index].ppShow = false
 				this.$forceUpdate()
 			},
@@ -936,12 +934,15 @@
 			},
 			copyItem(item) {
 				let obj = JSON.parse(JSON.stringify(item))
+				obj.multifileList = []
+				obj.xhData = []
 				obj.brandId = ''
 				obj.brand = ''
 				obj.brandName = ''
 				obj.name = ''
 				obj.zdPrice = ''
 				obj.price = ''
+				console.log(obj)
 				this.shopList.push(obj)
 			},
 			deleItem(i) {
@@ -1110,7 +1111,7 @@
 			background-size: 100% 100%;
 		}
 		.box_user {
-			z-index: 99;
+			z-index: 9;
 			position: fixed;
 			top: 30px;
 			right: 40px;
@@ -1122,19 +1123,11 @@
 				font-weight: 500;
 				color: #FFFFFF;
 			}
-			.box_user_btn {
-				width: 80px;
-				height: 34px;
-				line-height: 34px;
-				text-align: center;
-				border-radius: 8px;
-				border: 2px solid #FFFFFF;
-				font-size: 16px;
-				font-family: PingFangSC-Regular, PingFang SC;
-				font-weight: 400;
-				color: #FFFFFF;
-				margin-left: 22px;
+			image {
+				width: 18px;
+				height: 18px;
 				cursor: pointer;
+				margin-left: 10px;
 			}
 		}
 		.box_content {
@@ -1142,7 +1135,7 @@
 			// min-width: 750px;
 			.box_content_left {
 				position: fixed;
-				left: 50px;
+				left: 80px;
 				top: 50%;
 				cursor: pointer;
 				transform: translate(-50%, 0);
@@ -1156,7 +1149,7 @@
 			}
 			.box_content_right {
 				position: fixed;
-				right: 50px;
+				right: 0px;
 				top: 50%;
 				cursor: pointer;
 				transform: translate(-50%, 0);
@@ -1340,8 +1333,11 @@
 									font-weight: 500;
 								}
 								.commodityFrom_body_content_item_num_img {
-									width: 24px;
-									height: 24px;
+									width: 28px;
+									height: 28px;
+									display: flex;
+									align-items: center;
+									justify-content: center;
 									margin-right: 4px;
 									image {
 										width: 100%;
@@ -1393,6 +1389,8 @@
 										display: flex;
 										align-items: center;
 										justify-content: center;
+										padding: 0 10px;
+										box-sizing: border-box;
 										&:hover {
 											text {
 												color: #FFF200;
@@ -1580,6 +1578,8 @@
 								line-height: 40px;
 								text-align: center;
 								cursor: pointer;
+								padding: 0 10px;
+								box-sizing: border-box;
 								&:hover {
 									text {
 										color: #FFF200;

--
Gitblit v1.9.3