update
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2024-08-05 18:16:10 +08:00
parent 5626c70da6
commit 49e2df722d

View File

@@ -5,27 +5,18 @@
<!-- <view id="J_prismPlayer"></view> --> <!-- <view id="J_prismPlayer"></view> -->
<!-- <view class="player" id="mse"></view> --> <!-- <view class="player" id="mse"></view> -->
<!-- 头部 --> <!-- 头部 -->
<view <view class="z-50 bg-[#EB1313] w-full h-[110px] p-[18px] text-[30px] flex text-white justify-between items-center">
class="z-50 bg-[#EB1313] w-full h-[110px] p-[18px] text-[30px] flex text-white justify-between items-center"
>
<view>积分: {{ user.integral }}</view> <view>积分: {{ user.integral }}</view>
<view class="flex items-center justify-center"> <view class="flex items-center justify-center">
<view class="pr-[10px] text-[25px]"> <view class="pr-[10px] text-[25px]">
<view></view> <view></view>
<view></view> <view></view>
</view> </view>
<nut-popover <nut-popover v-model:visible="showSelector" :list="selector" location="bottom" @choose="onChange">
v-model:visible="showSelector"
:list="selector"
location="bottom"
@choose="onChange"
>
<template #reference> <template #reference>
<!-- @click.stop="showSelector = !showSelector" --> <!-- @click.stop="showSelector = !showSelector" -->
<view <view @click.stop="showSelector = !showSelector"
@click.stop="showSelector = !showSelector" class="w-[200px] h-[70px] pl-2 pr-2 border-2 rounded-md border-white flex items-center justify-center">
class="w-[200px] h-[70px] pl-2 pr-2 border-2 rounded-md border-white flex items-center justify-center"
>
<view>{{ formData.selectorChecked }}</view> <view>{{ formData.selectorChecked }}</view>
<down theme="filled" size="25" fill="#fff" /> <down theme="filled" size="25" fill="#fff" />
</view> </view>
@@ -49,12 +40,8 @@
</view> </view>
</template> </template>
</nut-popover> --> </nut-popover> -->
<navigator <navigator :url="`/pages/bet_record/index?uid=${uid}`" open-type="navigate" hover-class="none"
:url="`/pages/bet_record/index?uid=${uid}`" class="flex items-center">
open-type="navigate"
hover-class="none"
class="flex items-center"
>
<view>投注记录</view> <view>投注记录</view>
<right theme="filled" size="25" fill="#ffffff" /> <right theme="filled" size="25" fill="#ffffff" />
</navigator> </navigator>
@@ -66,46 +53,26 @@
<view class="text-[red] text-[40px]">{{ tStr }}</view> <view class="text-[red] text-[40px]">{{ tStr }}</view>
</view> </view>
<view class="flex flex-col items-center popover"> <view class="flex flex-col items-center popover">
<nut-popover <nut-popover v-model:visible="showTable" location="bottom" @open="openTable">
v-model:visible="showTable"
location="bottom"
@open="openTable"
>
<template #reference> <template #reference>
<view <view class="flex items-center" @click.stop="showTable = !showTable">
class="flex items-center"
@click.stop="showTable = !showTable"
>
<text class="text-[#333333] text-[28px]">近期开奖</text> <text class="text-[#333333] text-[28px]">近期开奖</text>
<down class="mr-1" theme="filled" size="25" fill="#333333" /> <down class="mr-1" theme="filled" size="25" fill="#333333" />
</view> </view>
</template> </template>
<template #content> <template #content>
<nut-table <nut-table style="width: 900px" :columns="columns" :data="data" striped :bordered="true"></nut-table>
style="width: 900px"
:columns="columns"
:data="data"
striped
:bordered="true"
></nut-table>
</template> </template>
</nut-popover> </nut-popover>
<view class="flex"> <view class="flex">
<view <view class="m-[5px] rounded-full w-[44px] h-[44px] text-white text-[28px] text-center leading-[44px]"
class="m-[5px] rounded-full w-[44px] h-[44px] text-white text-[28px] text-center leading-[44px]" v-for="(item, index) in numList" :key="index">
v-for="(item, index) in numList"
:key="index"
>
<view v-if="!item.num" class="m-[5px]"> <view v-if="!item.num" class="m-[5px]">
<plus-cross theme="filled" size="20" fill="#333333" /> <plus-cross theme="filled" size="20" fill="#333333" />
</view> </view>
<view <view class="rounded-full" :style="{
class="rounded-full" backgroundColor: item.color,
:style="{ }">{{ item.num }}</view>
backgroundColor: item.color,
}"
>{{ item.num }}</view
>
</view> </view>
</view> </view>
</view> </view>
@@ -114,29 +81,20 @@
<!-- <scroll-view scroll-y class="h-[800px]"> --> <!-- <scroll-view scroll-y class="h-[800px]"> -->
<template v-if="formData.betType !== 2"> <template v-if="formData.betType !== 2">
<view class="grid gap-1 grid-cols-4 place-items-center p-[20px]"> <view class="grid gap-1 grid-cols-4 place-items-center p-[20px]">
<view <view v-for="(item, index) in betList" :key="index"
v-for="(item, index) in betList"
:key="index"
class="shadow-md border border-[#E6E6E6] rounded-[10px] w-[150px] mb-[20px] h-[150px] max-[150px] bg-[red] text-center flex justify-center items-center" class="shadow-md border border-[#E6E6E6] rounded-[10px] w-[150px] mb-[20px] h-[150px] max-[150px] bg-[red] text-center flex justify-center items-center"
:class=" :class="formData.betIndexs.includes(item.value)
formData.betIndexs.includes(item.value) ? 'bg-[#EB1313]'
? 'bg-[#EB1313]' : 'bg-white'
: 'bg-white' " @click="betSelect(item)">
" <view :class="formData.betIndexs.includes(item.value) ? 'text-white' : ''">
@click="betSelect(item)" <view>{{ item.label }}</view>
> <view :class="[
<view formData.betIndexs.includes(item.value)
:class="formData.betIndexs.includes(item.value) ? 'text-white' : ''" ? 'text-white'
><view>{{ item.label }}</view> : 'text-[#EB1313]',
<view 'text-[30px]',
:class="[ ]">{{ item.odds }}</view>
formData.betIndexs.includes(item.value)
? 'text-white'
: 'text-[#EB1313]',
'text-[30px]',
]"
>{{ item.odds }}</view
>
<!-- <viwe v-if="item.betVal > 0">{{ item.betVal }}</viwe> --> <!-- <viwe v-if="item.betVal > 0">{{ item.betVal }}</viwe> -->
</view> </view>
</view> </view>
@@ -144,24 +102,18 @@
</template> </template>
<template v-else> <template v-else>
<view class="grid gap-5 grid-cols-6 place-items-center p-[20px]"> <view class="grid gap-5 grid-cols-6 place-items-center p-[20px]">
<view <view v-for="(item, index) in betList" :key="index"
v-for="(item, index) in betList"
:key="index"
class="shadow-md border border-[#E6E6E6] rounded-full w-[80px] mb-[20px] h-[80px] max-[200px]: bg-[red] text-center leading-[80px]" class="shadow-md border border-[#E6E6E6] rounded-full w-[80px] mb-[20px] h-[80px] max-[200px]: bg-[red] text-center leading-[80px]"
:class=" :class="formData.betIndexs.includes(item.value)
formData.betIndexs.includes(item.value) ? 'bg-[#EB1313]'
? 'bg-[#EB1313]' : 'bg-white'
: 'bg-white' " @click="betSelect(item)">
" <view :style="{
@click="betSelect(item)" color: formData.betIndexs.includes(item.value)
> ? 'white'
<view : getTextColor(item.label),
:style="{ }">
color: formData.betIndexs.includes(item.value) <view>{{ item.label }}</view>
? 'white'
: getTextColor(item.label),
}"
><view>{{ item.label }}</view>
<view class="text-[28px] text-[#EB1313] leading-[50px]">{{ <view class="text-[28px] text-[#EB1313] leading-[50px]">{{
item.odds item.odds
}}</view> }}</view>
@@ -175,56 +127,38 @@
<!-- 操作栏 --> <!-- 操作栏 -->
<view class="fixed bottom-0 w-full"> <view class="fixed bottom-0 w-full">
<!-- 投注信息 --> <!-- 投注信息 -->
<view <view v-if="formData.betIndexs.length > 0"
v-if="formData.betIndexs.length > 0" class="bg-[#F5F5F5] w-full text-[28px] p-[26px] flex justify-between items-center">
class="bg-[#F5F5F5] w-full text-[28px] p-[26px] flex justify-between items-center" <view>
>
<view
>
<text class="text-[#EB1313]">{{ formData.betIndexs.length }}</text> <text class="text-[#EB1313]">{{ formData.betIndexs.length }}</text>
<text class="text-[#EB1313]">{{ <text class="text-[#EB1313]">{{
formData.betIndexs.length * formData.value formData.betIndexs.length * formData.value
}}</text> }}</text>
豆子</view 豆子
> </view>
<!-- <view> 单注最多可赢 <text class="text-[#EB1313]">100</text> 积分 </view> --> <!-- <view> 单注最多可赢 <text class="text-[#EB1313]">100</text> 积分 </view> -->
</view> </view>
<view <view class="bg-white p-[30px] w-full text-[28px] flex justify-between items-center">
class="bg-white p-[30px] w-full text-[28px] flex justify-between items-center" <view @click="clearbet"
> class="bg-[#FFE8E8] rounded-[10px] border border-[#FF0204] w-[100px] h-[60px] text-[#FF0204] text-center leading-[60px]">
<view 清空</view>
@click="clearbet"
class="bg-[#FFE8E8] rounded-[10px] border border-[#FF0204] w-[100px] h-[60px] text-[#FF0204] text-center leading-[60px]"
>清空</view
>
<view> <view>
<view <view>可用豆子:
>可用豆子: <text class="text-[#EB1313]">{{ user.pulse }}</text> 豆子
<text class="text-[#EB1313]">{{ user.pulse }}</text> 豆子</view </view>
>
<!-- @input="betIput" --> <!-- @input="betIput" -->
<view class="flex" <view class="flex">单注:
>单注: <input v-model="formData.value" type="number"
<input
v-model="formData.value"
type="number"
class="ml-1 mr-1 border border-[#D9D9D9] rounded-[10px] w-[140px] pl-[10px] pr-[10px] text-[#FF0204] text-center" class="ml-1 mr-1 border border-[#D9D9D9] rounded-[10px] w-[140px] pl-[10px] pr-[10px] text-[#FF0204] text-center"
placeholder="" placeholder="" />
/> 豆子
豆子</view </view>
>
</view> </view>
</view> </view>
<!-- 确认投注 --> <!-- 确认投注 -->
<view <view class="text-[36px] h-[100px] bg-[red] text-white text-center leading-[100px]" shape="square" block
class="text-[36px] h-[100px] bg-[red] text-white text-center leading-[100px]" type="primary" @click="submit">一键投注</view>
shape="square"
block
type="primary"
@click="submit"
>一键投注</view
>
<!-- <button @click="lottieFn(2, 1000)">text</button> --> <!-- <button @click="lottieFn(2, 1000)">text</button> -->
</view> </view>
<view id="lottie" v-show="isLottie"></view> <view id="lottie" v-show="isLottie"></view>
@@ -255,7 +189,7 @@ import "./index.scss";
import wzj from "../../static/wzj.json"; import wzj from "../../static/wzj.json";
import zj from "../../static/zj.json"; import zj from "../../static/zj.json";
onMounted(() => {}); onMounted(() => { });
const player = ref(null); const player = ref(null);
@@ -563,11 +497,11 @@ const initPlayer = () => {
const showSelector = ref(false); const showSelector = ref(false);
const selector = ref([ const selector = ref([
{ name: "特码", value: 2 },
{ {
name: "头尾数", name: "头尾数",
value: 1, value: 1,
}, },
{ name: "特码", value: 2 },
{ name: "单双", value: 3 }, { name: "单双", value: 3 },
]); ]);
@@ -706,13 +640,13 @@ const columns = ref([
const data = ref([]); const data = ref([]);
const openTable = () => {}; const openTable = () => { };
const numList = ref([]); const numList = ref([]);
const formData = ref({ const formData = ref({
selectorChecked: "头尾数", selectorChecked: "特码",
betType: 1, betType: 2,
betIndexs: [], betIndexs: [],
value: "", value: "",
total: 0, total: 0,