lilei 4 anni fa
parent
commit
fe4f057ac9
3 ha cambiato i file con 11 aggiunte e 3 eliminazioni
  1. 11 3
      pages/index/index.vue
  2. BIN
      static/luckwheel-fixed.gif
  3. BIN
      static/luckwheel-fixed1.gif

+ 11 - 3
pages/index/index.vue

@@ -59,7 +59,10 @@
 				</view>
 			 </view>
 		</view>
-		
+		<!-- 转盘浮动图片 -->
+		<view class="luckwheel-fixed" @click="toLuckDraw()">
+			<u-image width="100rpx" height="100rpx" src="/static/luckwheel-fixed1.gif"></u-image>
+		</view>
 		<!-- 抽奖活动弹框 -->
 		<u-mask :show="showLottery" @click="showLottery = false">
 			<view class="lottery-content">
@@ -104,6 +107,8 @@
 		onLoad() {
 			// 检查更新
 			this.checkUpdate()
+			// 判断是否有抽奖活动
+			this.getLuckDraw()
 			// 查询购物车列表
 			this.getCartList()
 			// 刷新购物车列表
@@ -138,8 +143,6 @@
 			console.log(res)
 		},
 		onShow() {
-			// 判断是否有抽奖活动
-			this.getLuckDraw()
 			// 获取订单状态数据字典
 			// this.getCodeList('RUBBISH_TYPE','vuex_rubbishType')
 			// 获取顶部轮播图
@@ -425,6 +428,11 @@
 				padding-top: 10upx;
 			}
 		}
+		.luckwheel-fixed{
+			position: fixed;
+			right: 50rpx;
+			bottom: 20%;
+		}
 		.lottery-content{
 			display: flex;
 			align-items: center;

BIN
static/luckwheel-fixed.gif


BIN
static/luckwheel-fixed1.gif