zhang há 1 ano atrás
pai
commit
3502442d11
2 ficheiros alterados com 79 adições e 18 exclusões
  1. 78 18
      pages/index/entertainment.vue
  2. 1 0
      pages/user/shareQrCode.vue

+ 78 - 18
pages/index/entertainment.vue

@@ -145,60 +145,84 @@
 		<uni-popup type="center" ref="popupDetail">
 			<view class="alert-detail">
 				<view class="padding-c-30 padding-t-30 padding-b-30" v-if="alertDetail.result_info">
+				<!-- <view class="padding-c-30 padding-t-30 padding-b-30"> -->
 					<view class="flex">
 						<view class="type">
-							NO
+							{{$t('set.a7')}}{{alertDetail.no}}{{$t('set.a8')}}
 						</view>
 						<view class="num" >
-							{{alertDetail.no}}
+							<view class="lis" v-if="List.result === 1">
+								<view class="liss green">{{$t('enter.a5')}}</view>
+							</view>
+							<view class="lis" v-if="List.result === 0">
+								<view class="liss red">{{$t('enter.a6')}}</view>
+							</view>
+							<view class="lis" v-if="List.status === 0">
+								<view class="liss primary">{{$t('enter.a4')}}</view>
+							</view>
 						</view>
 					</view>
-					<view class="flex">
+					<!-- <view class="flex">
 						<view class="type">
 							{{$t('gameList.a5')}}
 						</view>
 						<view class="num" v-if="alertDetail.result_info.ts">
 							{{getTime(alertDetail.result_info.ts)}}
 						</view>
+					</view> -->
+					<view class="flex">
+						<view class="type">
+							{{$t('gameList.a2')}}
+						</view>
+						<view class="num">
+							{{alertDetail.game.timebar}}
+						</view>
 					</view>
 					<view class="flex">
 						<view class="type">
-							open
+							{{$t('gameList.a4')}}
 						</view>
 						<view class="num">
-							{{alertDetail.result_info.o}}
+							<!-- {{alertDetail.result_info.c}} -->
+							{{List.num}}U
 						</view>
 					</view>
 					<view class="flex">
 						<view class="type">
-							close
+							{{$t('gameList.a7')}}
 						</view>
 						<view class="num">
-							{{alertDetail.result_info.c}}
+							<!-- {{alertDetail.result_info.l}} -->
+							<view class="lisT green" v-if="List.bet==1">{{ $t("enter.u6") }}</view>
+							<view class="lisT red" v-if="List.bet==2">{{ $t("enter.u4") }}</view>
+							<view class="lisT green" v-if="List.bet==3">{{ $t("enter.u5") }}</view>
+							<view class="lisT red" v-if="List.bet==4">{{ $t("enter.u7") }}</view>
 						</view>
 					</view>
 					<view class="flex">
 						<view class="type">
-							lowest
+							{{$t('gameList.a8')}}
 						</view>
 						<view class="num">
-							{{alertDetail.result_info.l}}
+							<!-- {{alertDetail.result_info.h}} -->
+							{{List.get}}
 						</view>
 					</view>
 					<view class="flex">
 						<view class="type">
-							highest
+							{{$t('gameList.a9')}}
 						</view>
 						<view class="num">
-							{{alertDetail.result_info.h}}
+							{{alertDetail.result_info.o}}
 						</view>
 					</view>
 					<view class="flex">
 						<view class="type">
-							highest
+							{{$t('gameList.a5')}}
 						</view>
 						<view class="num">
-							{{alertDetail.result_info.h}}
+							<!-- {{alertDetail.result_info.h}} -->
+							{{alertDetail.open_time}}
 						</view>
 					</view>
 				</view>
@@ -278,6 +302,7 @@
 				KlineList: {
 					c: ''
 				},
+				
 				upOnBtnData: {
 					// 是否显示底部导航栏
 					show: false,
@@ -286,10 +311,10 @@
 					passwordArr: '',
 					value: '',
 				},
+				// ???
+				List: [],
 				// 弹窗数据像晴
-				alertDetail: {
-
-				},
+				alertDetail:{},
 				// 保存获取下次游戏对象
 				getNextTimeObj: '',
 				// 判断是否当前页面中
@@ -316,6 +341,7 @@
 			}
 			this.getUserWallet();
 			this.gameInit();
+			this.gameBetList()
 		},
 		// 关闭循环
 		onHide() {
@@ -328,9 +354,10 @@
 			getTime,
 			// 弹窗详情
 			alertDetailOpen(item) {
-				console.log(item);
 				this.alertDetail = item.room;
 				this.$refs.popupDetail.open();
+				this.List = item;
+				console.log(item);
 			},
 			// 倒计时清理
 			initData() {
@@ -503,6 +530,9 @@
 			gameBetList() {
 				const that = this;
 				const lineNum = that.history.base.decimal;
+				const list = that.betList.list;
+				// return list;
+				console.log('11111', list);
 				gameBetList({
 					page: 1,
 					limit: 10,
@@ -511,7 +541,7 @@
 					that.betList.list = data.bet_log.map((res)=>{
 						res.num=Number(res.num);
 						res.get=Number(res.get);
-						res.sexy = +(res.get-res.num).toFixed(2);
+						res.sexy = res.get-res.num;
 						console.log(res);
 						if(res.room.result_info){
 							const obj = res.room.result_info
@@ -523,6 +553,7 @@
 						return res
 					});
 				})
+				return list;
 			},
 			// 获取游戏K线信息
 			getGameKline(reload = true) {
@@ -1128,4 +1159,33 @@
 			padding: 10rpx 0;
 		}
 	}
+	
+	.lisT {
+		font-size: $font-lg;
+		font-weight: bold;
+		&.red{
+			color: #df5660;
+		}
+		&.green{
+			color: $color-green;
+		}
+	}
+	
+	.lis {
+		.liss {
+			border-radius: 5rpx;
+			padding: 10rpx 20rpx;
+			font-size: 22rpx;
+			font-weight: 500;
+			&.red{
+				background: $color-yellow;
+			}
+			&.green{
+				background: $color-green;
+			}
+			&.primary {
+				background: #01ebf6;
+			}
+		}
+	}
 </style>

+ 1 - 0
pages/user/shareQrCode.vue

@@ -94,6 +94,7 @@
 						return res
 					})
 					that.list = that.list.concat(list)
+					console.log('1111111',list);
 					that.page++
 					if (list.length == that.limit) {
 						that.loadingType = 'more'