From 73341eba8e313c2aead0476026bc362b8c4be4b1 Mon Sep 17 00:00:00 2001
From: xuxueyang <xuxy@fengyuntec.com>
Date: 星期四, 12 九月 2024 16:05:06 +0800
Subject: [PATCH] update 优化

---
 components/banner3d/banner3d.vue |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/components/banner3d/banner3d.vue b/components/banner3d/banner3d.vue
index 9b9b0d8..926f03f 100644
--- a/components/banner3d/banner3d.vue
+++ b/components/banner3d/banner3d.vue
@@ -29,17 +29,17 @@
 						<view class="line-component" v-if="bannerList[i].point">
 							<view class="line-bg">
 								<view class="tip"
-									:style="{'left':(bannerList[i].point.end&&(bannerList[i].point.current/bannerList[i].point.end)||0).toFixed(2)*100+'%'}">
+									:style="{'left':(bannerList[i].point.current<=bannerList[i].point.endPoint)?((bannerList[i].point.endPoint&&(bannerList[i].point.current/bannerList[i].point.endPoint)||0).toFixed(2)*100+'%'):'100%'}">
 									{{bannerList[i].point.current || 0}}
 								</view>
 								<view class="tip-loc"
-									:style="{'left':(bannerList[i].point.end&&(bannerList[i].point.current/bannerList[i].point.end)||0).toFixed(2)*100+'%'}">
+									:style="{'left':(bannerList[i].point.current<=bannerList[i].point.endPoint)?((bannerList[i].point.endPoint&&(bannerList[i].point.current/bannerList[i].point.endPoint)||0).toFixed(2)*100+'%'):'100%'}">
 								</view>
 							</view>
 
 							<view class="desc">
 								<span
-									v-if="bannerList[i].point.end">{{bannerList[i].point.current || 0}}/{{bannerList[i].point.end}},升级还需{{bannerList[i].point.end-bannerList[i].point.current}}成长值</span>
+									v-if="bannerList[i].point.endPoint&&(bannerList[i].point.current<=bannerList[i].point.endPoint)">{{bannerList[i].point.current || 0}}/{{bannerList[i].point.endPoint}},升级还需{{bannerList[i].point.endPoint - bannerList[i].point.current}}成长值</span>
 								<span v-else>当前成长值:{{bannerList[i].point.current || 0}}</span>
 							</view>
 						</view>
@@ -115,6 +115,7 @@
 					that.descIndex = e.mp.detail.current
 					clearTimeout(timer)
 				}, 150)
+				this.$emit('changeIndex',this.curIndex)
 			},
 			animationfinish(e) {
 				this.isDescAnimating = false

--
Gitblit v1.9.3