This commit is contained in:
Eudemon 2025-03-12 18:59:06 +08:00
parent bdf990d569
commit 5519dee3cf
10 changed files with 410 additions and 344 deletions

View File

@ -1,4 +1,4 @@
NODE_ENV = development ENV = development
VITE_APP_BASE_URL = https://game.777spinz.com VITE_APP_BASE_URL = https://game.777spinz.com
# VITE_APP_BASE_URL=https://game-api.777spinz.com # VITE_APP_BASE_URL=https://game-api.777spinz.com
# VITE_APP_BASE_URL=http://192.168.1.24:8093 # VITE_APP_BASE_URL=http://192.168.1.24:8093

View File

@ -1,2 +1,2 @@
NODE_ENV=production ENV=production
VITE_APP_BASE_URL=https://game-api.777spinz.com VITE_APP_BASE_URL=https://game-api.777spinz.com

View File

@ -180,21 +180,21 @@
}, },
"dependencies": { "dependencies": {
"@adjustcom/adjust-web-sdk": "^5.7.1", "@adjustcom/adjust-web-sdk": "^5.7.1",
"@dcloudio/uni-app": "3.0.0-4040520250104002", "@dcloudio/uni-app": "3.0.0-4050520250307001",
"@dcloudio/uni-app-harmony": "3.0.0-4040520250104002", "@dcloudio/uni-app-harmony": "3.0.0-4050520250307001",
"@dcloudio/uni-app-plus": "3.0.0-4040520250104002", "@dcloudio/uni-app-plus": "3.0.0-4050520250307001",
"@dcloudio/uni-components": "3.0.0-4040520250104002", "@dcloudio/uni-components": "3.0.0-4050520250307001",
"@dcloudio/uni-h5": "3.0.0-4040520250104002", "@dcloudio/uni-h5": "3.0.0-4050520250307001",
"@dcloudio/uni-mp-alipay": "3.0.0-4040520250104002", "@dcloudio/uni-mp-alipay": "3.0.0-4050520250307001",
"@dcloudio/uni-mp-baidu": "3.0.0-4040520250104002", "@dcloudio/uni-mp-baidu": "3.0.0-4050520250307001",
"@dcloudio/uni-mp-jd": "3.0.0-4040520250104002", "@dcloudio/uni-mp-jd": "3.0.0-4050520250307001",
"@dcloudio/uni-mp-kuaishou": "3.0.0-4040520250104002", "@dcloudio/uni-mp-kuaishou": "3.0.0-4050520250307001",
"@dcloudio/uni-mp-lark": "3.0.0-4040520250104002", "@dcloudio/uni-mp-lark": "3.0.0-4050520250307001",
"@dcloudio/uni-mp-qq": "3.0.0-4040520250104002", "@dcloudio/uni-mp-qq": "3.0.0-4050520250307001",
"@dcloudio/uni-mp-toutiao": "3.0.0-4040520250104002", "@dcloudio/uni-mp-toutiao": "3.0.0-4050520250307001",
"@dcloudio/uni-mp-weixin": "3.0.0-4040520250104002", "@dcloudio/uni-mp-weixin": "3.0.0-4050520250307001",
"@dcloudio/uni-mp-xhs": "3.0.0-4040520250104002", "@dcloudio/uni-mp-xhs": "3.0.0-4050520250307001",
"@dcloudio/uni-quickapp-webview": "3.0.0-4040520250104002", "@dcloudio/uni-quickapp-webview": "3.0.0-4050520250307001",
"crypto-js": "^4.2.0", "crypto-js": "^4.2.0",
"lodash": "^4.17.21", "lodash": "^4.17.21",
"md5": "^2.3.0", "md5": "^2.3.0",
@ -206,11 +206,11 @@
}, },
"devDependencies": { "devDependencies": {
"@dcloudio/types": "3.4.14", "@dcloudio/types": "3.4.14",
"@dcloudio/uni-automator": "3.0.0-4040520250104002", "@dcloudio/uni-automator": "3.0.0-4050520250307001",
"@dcloudio/uni-cli-shared": "3.0.0-4040520250104002", "@dcloudio/uni-cli-shared": "3.0.0-4050520250307001",
"@dcloudio/uni-stacktracey": "3.0.0-4040520250104002", "@dcloudio/uni-stacktracey": "3.0.0-4050520250307001",
"@dcloudio/uni-uts-v1": "3.0.0-4040520250104002", "@dcloudio/uni-uts-v1": "3.0.0-4040520250104002",
"@dcloudio/vite-plugin-uni": "3.0.0-4040520250104002", "@dcloudio/vite-plugin-uni": "3.0.0-4050520250307001",
"@types/crypto-js": "^4.2.2", "@types/crypto-js": "^4.2.2",
"@uni-helper/uni-app-types": "1.0.0-alpha.6", "@uni-helper/uni-app-types": "1.0.0-alpha.6",
"@vue/runtime-core": "3.4.21", "@vue/runtime-core": "3.4.21",

View File

@ -11,9 +11,16 @@ const api = {
openGameSearch: ipConfig.api_app + '/labelGame/openGameSearch', openGameSearch: ipConfig.api_app + '/labelGame/openGameSearch',
getGameByCategoryAndPage: ipConfig.api_app + '/labelGame/getGameByCategoryAndPage', getGameByCategoryAndPage: ipConfig.api_app + '/labelGame/getGameByCategoryAndPage',
getSearchResults: ipConfig.api_app + '/labelGame/getSearchResults', getSearchResults: ipConfig.api_app + '/labelGame/getSearchResults',
jiliLogout: ipConfig.api_app + '/jili/transfer/logout' jiliLogout: ipConfig.api_app + '/jili/transfer/logout',
gameOut: ipConfig.api_app + '/labelGame/logoutGame',
} }
export const gameOutApi = () => {
return httpRequest.post({
url: api.gameOut,
data: {}
})
}
/** /**
* 获取标签 * 获取标签
*/ */

View File

@ -2,7 +2,7 @@
import { ref, computed } from 'vue' import { ref, computed } from 'vue'
import { useThemeStore } from '@/store/useThemeStore.js' import { useThemeStore } from '@/store/useThemeStore.js'
import { createBankruptRechargeApi } from '@/api/home' import { createBankruptRechargeApi } from '@/api/home'
import { formatNum } from '@/module/utils/util' import { openWeb } from '@/module/utils/openUrl'
const props = defineProps({ const props = defineProps({
detail: { detail: {
@ -23,25 +23,22 @@ const close = () => {
emit('close') emit('close')
} }
/** const createOrder = async (recharge) => {
* uni.showLoading({ title: 'Loading...' })
* @param {number} num try {
*/ const { data } = await createBankruptRechargeApi(recharge);
function transNumtoStrArr(num) { console.log('createOrder', data);
if (!num || isNaN(num)) return [] if (data?.isSuccess) {
return num.toString().split('') openWeb(data?.url);
} }
const createOrder = async () => { } catch (error) {
console.log('createOrder') console.log('createOrder error', error);
const { data } = await createBankruptRechargeApi(); } finally {
console.log('createOrder', data); uni.hideLoading()
}
const calAmount = (obj) => {
if(obj.recharge, obj.rate) {
return formatNum(obj.recharge * obj.rate + obj.recharge, 1)
} }
return 0
} }
defineExpose({ defineExpose({
open, open,
close close
@ -52,38 +49,39 @@ defineExpose({
<view class="pop-content relative" :style="{ background: theme.popBg }"> <view class="pop-content relative" :style="{ background: theme.popBg }">
<theme-image src="@/static/greatRebet/image_X.png" class="close pos-absolute" @click="close"></theme-image> <theme-image src="@/static/greatRebet/image_X.png" class="close pos-absolute" @click="close"></theme-image>
<view class="tip pos-absolute" :style="{ color: theme.tip }">{{ $t('home.greatRebet.tip') }}</view> <view class="tip pos-absolute" :style="{ color: theme.tip }">{{ $t('home.greatRebet.tip') }}</view>
<view class="bonus left pos-absolute"> <view class="bonus left pos-absolute" v-if="detail.length > 0">
<view class="amount flex-center"> <view class="amount flex-center">
<!-- <theme-image src="@/static/greatRebet/lubi.png" class="icon-num"></theme-image> <!-- <theme-image src="@/static/greatRebet/lubi.png" class="icon-num"></theme-image>
<theme-image v-for="(item, index) in transNumtoStrArr(130)" :key="index" class="icon-num" <theme-image v-for="(item, index) in transNumtoStrArr(130)" :key="index" class="icon-num"
:src="`@/static/greatRebet/${item}.png`"></theme-image> --> :src="`@/static/greatRebet/${item}.png`"></theme-image> -->
{{ currency }}{{ detail[0]['give'] }} {{ currency }}{{ detail[0]['give'] + detail[0]['recharge'] }}
</view> </view>
<view class="percent pos-absolute percent-left flex-center" <view class="percent pos-absolute percent-left flex-center"
:style="{ background: theme.percentBg, color: theme.percent }"> :style="{ background: theme.percentBg, color: theme.percent }">
<text>{{ formatNum(detail[0]['rate'] * 100, 1) }}</text> <text>{{ detail[0]['rate'] }}</text>
<text style="font-size: 20rpx;">%</text> <text style="font-size: 20rpx;">%</text>
</view> </view>
</view> </view>
<view class="bonus center pos-absolute"> <view class="bonus center pos-absolute">
<view class="amount flex-center">{{ currency }}{{ detail[1]['give'] }}</view> <view class="amount flex-center">{{ currency }}{{ detail[1]['give'] + detail[1]['recharge'] }}</view>
<view class="percent percent-center pos-absolute flex-center" <view class="percent percent-center pos-absolute flex-center"
:style="{ background: theme.percentBg, color: theme.percent }"> :style="{ background: theme.percentBg, color: theme.percent }">
<text>{{ formatNum(detail[1]['rate'] * 100, 1) }}</text> <text>{{ detail[1]['rate'] }}</text>
<text style="font-size: 20rpx;">%</text> <text style="font-size: 20rpx;">%</text>
</view> </view>
</view> </view>
<view class="bonus right pos-absolute"> <view class="bonus right pos-absolute">
<view class="amount flex-center">{{ currency }}{{ detail[2]['give'] }}</view> <view class="amount flex-center">{{ currency }}{{ detail[2]['give'] + detail[2]['recharge'] }}</view>
<view class="percent percent-right pos-absolute flex-center" <view class="percent percent-right pos-absolute flex-center"
:style="{ background: theme.percentBg, color: theme.percent }"> :style="{ background: theme.percentBg, color: theme.percent }">
<text>{{ formatNum(detail[2]['rate'] * 100, 1) }}</text> <text>{{ detail[2]['rate'] }}</text>
<text style="font-size: 20rpx;">%</text> <text style="font-size: 20rpx;">%</text>
</view> </view>
</view> </view>
<view class="btn-box pos-absolute flex justify-between w-full"> <view class="btn-box pos-absolute flex justify-between w-full">
<view v-for="(item, index) in detail" :key="index" class="recharge-btn flex-center" :style="{ background: theme.btnBg, color: theme.light }" <view v-for="(item, index) in detail" :key="index" class="recharge-btn flex-center"
@click.stop="createOrder(item.recharge)">{{ currency }}{{ item.recharge }}</view> :style="{ background: theme.btnBg, color: theme.light }" @click.stop="createOrder(item.recharge)">{{
currency }}{{ item.recharge }}</view>
<!-- <view class="recharge-btn flex-center" :style="{ background: theme.btnBg, color: theme.light }" <!-- <view class="recharge-btn flex-center" :style="{ background: theme.btnBg, color: theme.light }"
@click.stop="createOrder">{{ currency }}22</view> @click.stop="createOrder">{{ currency }}22</view>
<view class="recharge-btn flex-center" :style="{ background: theme.btnBg, color: theme.light }" <view class="recharge-btn flex-center" :style="{ background: theme.btnBg, color: theme.light }"
@ -144,7 +142,7 @@ defineExpose({
.amount { .amount {
font-family: Roboto; font-family: Roboto;
font-weight: bold; font-weight: bold;
font-size: 44rpx; font-size: 40rpx;
color: #FFFFFF; color: #FFFFFF;
// text-shadow: 1rpx 1rpx 4rpx #8A0A00; // text-shadow: 1rpx 1rpx 4rpx #8A0A00;
background: linear-gradient(45deg, #F5FF60, #FFDE00, #FFFFFF 10%, #FFDE00, #F5FF60); background: linear-gradient(45deg, #F5FF60, #FFDE00, #FFFFFF 10%, #FFDE00, #F5FF60);
@ -162,17 +160,17 @@ defineExpose({
} }
.percent-left { .percent-left {
top: -60rpx; top: -64rpx;
right: -20rpx; right: -20rpx;
} }
.percent-center { .percent-center {
top: -20rpx; top: -60rpx;
right: -20rpx; right: -30rpx;
} }
.percent-right { .percent-right {
top: -30rpx; top: -60rpx;
right: -30rpx; right: -30rpx;
} }

View File

@ -5,8 +5,8 @@
"appid" : "__UNI__FECBD22", "appid" : "__UNI__FECBD22",
"description" : "Winzz777", "description" : "Winzz777",
// "description" : "Spinz777", // "description" : "Spinz777",
"versionName" : "1.2.1", "versionName" : "1.2.2",
"versionCode" : 121, "versionCode" : 122,
"channel_list" : [ "channel_list" : [
{ {
"id" : "suisui2" "id" : "suisui2"

View File

@ -2,18 +2,20 @@
<common-layout bgColor="#4D0606"> <common-layout bgColor="#4D0606">
<!-- <theme-image src="@/static/home_bg.png" mode="aspectFill" class="home-bg" <!-- <theme-image src="@/static/home_bg.png" mode="aspectFill" class="home-bg"
:style="{ height: appStore.windowInfo.height + 'px', width: appStore.windowInfo.width + 'px' }" /> --> :style="{ height: appStore.windowInfo.height + 'px', width: appStore.windowInfo.width + 'px' }" /> -->
<view class="home-container" <view class="home-container" :style="{
:style="{ background: `top / cover no-repeat ${themeStore.theme.home.bgColor}`, height: appStore.windowInfo.screenHeight + 'px' }"> background: `top / cover no-repeat ${themeStore.theme.home.bgColor}`,
height: appStore.windowInfo.screenHeight + 'px',
}">
<HomeHeader /> <HomeHeader />
<!-- <view>Hello World</view> --> <!-- <view>Hello World</view> -->
<view class="plr30"> <view class="plr30">
<uni-swiper-dot :info="pageData.bannerList" :current="pageData.currentIndex" field="content" <uni-swiper-dot :info="pageData.bannerList" :current="pageData.currentIndex" field="content"
mode="round" :dotsStyles="{ mode="round" :dotsStyles="{
backgroundColor: '#fff', backgroundColor: '#fff',
selectedBackgroundColor: themeStore.theme.swiper.dot, selectedBackgroundColor: themeStore.theme.swiper.dot,
selectedBorder: 'none', selectedBorder: 'none',
bottom: 6, bottom: 6,
}"> }">
<swiper class="swiper-view" :circular="true" :duration="500" :autoplay="true" <swiper class="swiper-view" :circular="true" :duration="500" :autoplay="true"
:indicator-dots="false" :interval="3000" @change="handleSwipeChange"> :indicator-dots="false" :interval="3000" @change="handleSwipeChange">
<swiper-item v-for="(item, index) in pageData.bannerList" :key="index" <swiper-item v-for="(item, index) in pageData.bannerList" :key="index"
@ -33,15 +35,15 @@
<view class="plr30"> <view class="plr30">
<view class="home-tabs-view" :style="{ 'border-color': themeStore.theme.seplineColor }"> <view class="home-tabs-view" :style="{ 'border-color': themeStore.theme.seplineColor }">
<SegmentControl :listData="[ <SegmentControl :listData="[
{ title: $t('home.allgames') }, { title: $t('home.allgames') },
{ title: $t('home.recent') }, { title: $t('home.recent') },
{ title: $t('home.favorite') }, { title: $t('home.favorite') },
]" @change="({ index }) => { ]" @change="({ index }) => {
gameStore.getRecentGames(); gameStore.getRecentGames();
gameStore.getFavoriteGames(); gameStore.getFavoriteGames();
pageData.active = index; pageData.active = index;
} }
" /> " />
</view> </view>
</view> </view>
<view v-show="pageData.active === 0"> <view v-show="pageData.active === 0">
@ -62,7 +64,7 @@
<NoDataSearch style="width: 100%" v-if="gameStore.favoriteGameList.length === 0" /> <NoDataSearch style="width: 100%" v-if="gameStore.favoriteGameList.length === 0" />
</view> </view>
</view> </view>
<view class="w-full space" style="height: 100rpx;"></view> <view class="w-full space" style="height: 100rpx"></view>
</view> </view>
<!-- float-promo --> <!-- float-promo -->
<!-- <view class="float-promo" v-if="depositBonusRights" @click.stop="openDepositBonus"> <!-- <view class="float-promo" v-if="depositBonusRights" @click.stop="openDepositBonus">
@ -106,19 +108,26 @@
@close="handleClose" /> @close="handleClose" />
<ConDepositPop ref="conDepositPop" @close="handleClose" /> <ConDepositPop ref="conDepositPop" @close="handleClose" />
<DepositBonus ref="depositBonusPop" @close="handleClose" /> <DepositBonus ref="depositBonusPop" @close="handleClose" />
<GreatRebet v-if="bankruptArr.length > 0" ref="greatPopRef" :detail="bankruptArr" @close="handleClose" /> <GreatRebet ref="greatPopRef" :detail="bankruptArr" @close="handleClose" />
<view v-if="showSlider" class="slider-bar" <view v-if="showSlider" class="slider-bar" :style="{
:style="{ right: -(col * singleItemWidth + 38) + 'rpx', transform: `translateX(${slideTranslateX}rpx)` }"> right: -(col * singleItemWidth + 38) + 'rpx',
transform: `translateX(${slideTranslateX}rpx)`,
}">
<view class="out-menu" @click="menuClick"> <view class="out-menu" @click="menuClick">
<theme-image :src="`@/static/home/${slideOpen ? 'shouqi.png':'zhankai.png'}`" class="icon-slide-menu" /> <theme-image :src="`@/static/home/${slideOpen ? 'shouqi.png' : 'zhankai.png'}`"
class="icon-slide-menu" />
<view class="red-dot" v-if="isDoted"></view> <view class="red-dot" v-if="isDoted"></view>
</view> </view>
<view class="slider-box" :style="{ width: slideWidth + 'rpx' }"> <view class="slider-box" :style="{ width: slideWidth + 'rpx' }">
<view class="slide-item relative" v-for="(item, index) in slideItems" :key="index" @click.stop="openPromo(item)"> <view class="slide-item relative" v-for="(item, index) in slideItems" :key="index"
<theme-image :src="item.icon" @click.stop="openPromo(item)">
:style="{ width: singleItemWidth + 'rpx', height: singleItemWidth + 'rpx' }" class="icon-slide-menu" <theme-image :src="item.icon" :style="{
mode="aspectFit" /> width: singleItemWidth + 'rpx',
<view class="red-dot" v-if="item.doted"></view> height: singleItemWidth + 'rpx',
}" class="icon-slide-menu" mode="aspectFit" />
<view class="red-dot flex-center" v-if="item.doted">
<text :style="{ color: themeStore.theme.depositWheel.quaternary }">{{ item.count }}</text>
</view>
</view> </view>
</view> </view>
</view> </view>
@ -136,7 +145,11 @@ import { useThemeStore } from "@/store/useThemeStore";
import { useMailStore } from "@/store/useMailStore.js"; import { useMailStore } from "@/store/useMailStore.js";
import { useDepositStore } from "@/store/useDepositStore"; import { useDepositStore } from "@/store/useDepositStore";
import { usePromoStore } from "@/store/usePromoStore"; import { usePromoStore } from "@/store/usePromoStore";
import { checkBankruptApi, requestBannerList, requestRechargeButtonStatus } from "@/api/home"; import {
checkBankruptApi,
requestBannerList,
requestRechargeButtonStatus,
} from "@/api/home";
import { requestGetGameUrlByGame } from "@/api/game.js"; import { requestGetGameUrlByGame } from "@/api/game.js";
import HomeUserInfo from "./components/HomeUserInfo.vue"; import HomeUserInfo from "./components/HomeUserInfo.vue";
import HomeHeader from "./components/HomeHeader.vue"; import HomeHeader from "./components/HomeHeader.vue";
@ -150,12 +163,12 @@ import Rank from "./components/PromoPopup/Rank.vue";
import UpRebate from "./components/PromoPopup/UpRebate.vue"; import UpRebate from "./components/PromoPopup/UpRebate.vue";
import Signin from "./components/PromoPopup/Signin.vue"; import Signin from "./components/PromoPopup/Signin.vue";
import Community from "./components/PromoPopup/Community.vue"; import Community from "./components/PromoPopup/Community.vue";
import Jili from "./components/PromoPopup/Jili.vue" import Jili from "./components/PromoPopup/Jili.vue";
import UserInfoPopUp from "./components/UserInfo.vue"; import UserInfoPopUp from "./components/UserInfo.vue";
import { useI18n } from "vue-i18n"; import { useI18n } from "vue-i18n";
import { openUrl } from "@/module/utils/openUrl"; import { openUrl } from "@/module/utils/openUrl";
// import StartLoading from "@/components/loading/StartLoading.vue" // import StartLoading from "@/components/loading/StartLoading.vue"
import { okSpin } from '@/module/third/okspin.js' import { okSpin } from "@/module/third/okspin.js";
import BindPhonePop from "@/components/popup/BindPhonePop.vue"; import BindPhonePop from "@/components/popup/BindPhonePop.vue";
import Congratulation from "@/components/popup/Congratulation.vue"; import Congratulation from "@/components/popup/Congratulation.vue";
import BindPromoPop from "@/components/popup/BindPromoPop.vue"; import BindPromoPop from "@/components/popup/BindPromoPop.vue";
@ -175,11 +188,11 @@ const userStore = useUserStore();
const appStore = useAppStore(); const appStore = useAppStore();
const themeStore = useThemeStore(); const themeStore = useThemeStore();
const mailStore = useMailStore(); const mailStore = useMailStore();
const depositStore = useDepositStore() const depositStore = useDepositStore();
const promoStore = usePromoStore() const promoStore = usePromoStore();
const depositBonusRights = ref(false) const depositBonusRights = ref(false);
const awardPopup = ref(null) const awardPopup = ref(null);
const greatPopRef = ref(null) const greatPopRef = ref(null);
const pageData = reactive({ const pageData = reactive({
// startLoadingVisible: true, // startLoadingVisible: true,
currentIndex: 0, currentIndex: 0,
@ -189,69 +202,69 @@ const pageData = reactive({
}); });
// slider area // slider area
const slideOpen = ref(false) const slideOpen = ref(false);
const showSlider = ref(false) const showSlider = ref(false);
const slideWidth = ref(150) const slideWidth = ref(150);
const singleItemWidth = 112 const singleItemWidth = 112;
// const slideTranslateX = ref(-150) // const slideTranslateX = ref(-150)
const colLength = 5 const colLength = 5;
const col = computed(() => { const col = computed(() => {
return Math.ceil(slideItems.value.length / colLength) return Math.ceil(slideItems.value.length / colLength);
}) });
const slideItems = ref([]) const slideItems = ref([]);
const isDoted = computed(() => { const isDoted = computed(() => {
return slideItems.value.filter(v => v.doted).length > 0 return slideItems.value.filter((v) => v.doted).length > 0;
}) });
const slideTranslateX = computed(() => { const slideTranslateX = computed(() => {
return slideOpen.value ? -152 : 2 return slideOpen.value ? -152 : 2;
}) });
const menuClick = () => { const menuClick = () => {
slideOpen.value = !slideOpen.value slideOpen.value = !slideOpen.value;
} };
const openPromo = (item) => { const openPromo = (item) => {
const idx = slideItems.value.findIndex(v => v.dotName == item.dotName) const idx = slideItems.value.findIndex((v) => v.dotName == item.dotName);
console.log('openPromo', idx, item); console.log("openPromo", idx, item);
if(idx > -1) { if (idx > -1) {
slideItems.value[idx].doted = false slideItems.value[idx].doted = false;
} }
setDot(item.dotName, false) setDot(item.dotName, false);
if (item.el) { if (item.el) {
item.el?.open() item.el?.open();
} else { } else {
uni.navigateTo({ uni.navigateTo({
url: item.path, url: item.path,
}); });
} }
} };
// end // end
const posY = ref(200) const posY = ref(200);
const rewardDayonce = ref(false) const rewardDayonce = ref(false);
const bindPromoPop = ref(null) const bindPromoPop = ref(null);
const bindPhone = ref(null) const bindPhone = ref(null);
const firstRechargePop = ref(null) const firstRechargePop = ref(null);
const popupArr = ref([]) const popupArr = ref([]);
const today = ref('') const today = ref("");
const rankPop = ref(null) const rankPop = ref(null);
const rankRewardPop = ref(null) const rankRewardPop = ref(null);
const rankData = ref(0) const rankData = ref(0);
const conDepositPop = ref(null) const conDepositPop = ref(null);
const depositBonusPop = ref(null) const depositBonusPop = ref(null);
const wheelPop = ref(null) const wheelPop = ref(null);
const greatRebet = ref(null) const greatRebet = ref(null);
// const app = getCurrentInstance(); // const app = getCurrentInstance();
const actState = ref(0) const actState = ref(0);
const activityData = ref({}) const activityData = ref({});
const isShowToday = computed(() => { const isShowToday = computed(() => {
if (today.value) { if (today.value) {
return today.value == conversionTime() return today.value == conversionTime();
} }
return false return false;
}) });
const onUnbindPhone = () => { const onUnbindPhone = () => {
bindPhone.value.open() bindPhone.value.open();
} };
/** /**
* 弹窗显示隐藏相关参数 * 弹窗显示隐藏相关参数
*/ */
@ -260,70 +273,68 @@ let upRebateVisible = ref(false);
let signinVisible = ref(false); let signinVisible = ref(false);
let rankVisible = ref(false); let rankVisible = ref(false);
let communityVisible = ref(false); let communityVisible = ref(false);
let jiliVisible = ref(false) let jiliVisible = ref(false);
let isRegister = ref(userStore.isOneClickRegister); let isRegister = ref(userStore.isOneClickRegister);
let registerSuccesVisible = ref(false); let registerSuccesVisible = ref(false);
let popupData = reactive({}); let popupData = reactive({});
let popupIndex = ref(0); let popupIndex = ref(0);
const openDepositBonus = () => { const openDepositBonus = () => {
if (actState.value == 2) { if (actState.value == 2) {
checkUserAct() checkUserAct();
depositBonusPop.value.open() depositBonusPop.value.open();
} else { } else {
conDepositPop.value.open() conDepositPop.value.open();
} }
} };
const delay = (s) => { const delay = (s) => {
return new Promise(resolve => setTimeout(resolve, s)) return new Promise((resolve) => setTimeout(resolve, s));
} };
const handleClose = async () => { const handleClose = async () => {
await delay(300) await delay(300);
showPopQueue() showPopQueue();
} };
const preLoadImg = (url) => { const preLoadImg = (url) => {
// const image = new Image(); // const image = new Image();
// image.src = url; // image.src = url;
uni.getImageInfo({ uni.getImageInfo({
src: url, src: url,
}); });
} };
const handleOnBind = () => { const handleOnBind = () => {
bindPhone.value.open() bindPhone.value.open();
} };
const handleChecked2 = () => { const handleChecked2 = () => {
if (rewardDayonce.value) { if (rewardDayonce.value) {
uni.removeStorageSync('rewardDayonce') uni.removeStorageSync("rewardDayonce");
rewardDayonce.value = false rewardDayonce.value = false;
} else { } else {
uni.setStorageSync('rewardDayonce', conversionTime()) uni.setStorageSync("rewardDayonce", conversionTime());
rewardDayonce.value = true rewardDayonce.value = true;
} }
} };
const handleChecked = () => { const handleChecked = () => {
if (isShowToday.value) { if (isShowToday.value) {
uni.removeStorageSync('today') uni.removeStorageSync("today");
today.value = '' today.value = "";
} else { } else {
uni.setStorageSync('today', conversionTime()) uni.setStorageSync("today", conversionTime());
today.value = conversionTime() today.value = conversionTime();
} }
} };
const showPopQueue = () => { const showPopQueue = () => {
if (popupArr.value.length > 0) { if (popupArr.value.length > 0) {
const popup = popupArr.value.shift() const popup = popupArr.value.shift();
popup && popup.open() popup && popup.open();
} }
} };
const getPageData = () => { const getPageData = () => {
gameStore.getRecentGames(); gameStore.getRecentGames();
gameStore.getFavoriteGames(); gameStore.getFavoriteGames();
if (userStore.isLogin) { if (userStore.isLogin) {
mailStore.getMailList(); mailStore.getMailList();
depositStore.getChargeInfo() depositStore.getChargeInfo();
} }
}; };
@ -333,7 +344,7 @@ const getBanner = async () => {
return; return;
} }
pageData.bannerList = data.bannerList || []; pageData.bannerList = data.bannerList || [];
pageData.bannerList.forEach(banner => preLoadImg(banner.imageUrl)); pageData.bannerList.forEach((banner) => preLoadImg(banner.imageUrl));
}; };
const handleSwipeChange = (e) => { const handleSwipeChange = (e) => {
@ -382,32 +393,32 @@ const handleBannerClick = async (item) => {
case 11: case 11:
break; break;
case 12: case 12:
navTo('/pages/promo/SignupBonus') navTo("/pages/promo/SignupBonus");
break; break;
case 13: case 13:
navTo('/pages/promo/Jili') navTo("/pages/promo/Jili");
break; break;
case 14: case 14:
navTo('/pages/promo/InvitationalRanks') navTo("/pages/promo/InvitationalRanks");
break; break;
case 15: case 15:
navTo('/pages/activity/Activity') navTo("/pages/activity/Activity");
break; break;
case 16: case 16:
if (!userStore.userInfo?.mobile) { if (!userStore.userInfo?.mobile) {
bindPhone.value.open() bindPhone.value.open();
} else { } else {
toast.show(t('account.bindPhone.binded')) toast.show(t("account.bindPhone.binded"));
} }
break; break;
case 17: case 17:
navTo('/pages/activity/Poster') navTo("/pages/activity/Poster");
break; break;
case 18: case 18:
navTo('/pages/promo/TgExchange') navTo("/pages/promo/TgExchange");
break; break;
case 19: case 19:
navTo('/pages/redeposit/ReDeposit') navTo("/pages/redeposit/ReDeposit");
break; break;
default: default:
break; break;
@ -482,7 +493,7 @@ const handleBannerClick = async (item) => {
if (code !== 200 && !data) { if (code !== 200 && !data) {
return; return;
} }
uni.setStorageSync('GAME_URL_KEY', data) uni.setStorageSync("GAME_URL_KEY", data);
uni.navigateTo({ uni.navigateTo({
url: `/pages/webview/GameWeb?url=${encodeURIComponent(data)}`, url: `/pages/webview/GameWeb?url=${encodeURIComponent(data)}`,
}); });
@ -496,20 +507,20 @@ const handleBannerClick = async (item) => {
*/ */
const getPromoLists = async () => { const getPromoLists = async () => {
// await promoStore.getPromoList() // await promoStore.getPromoList()
const arr = promoStore.promoPopupList const arr = promoStore.promoPopupList;
console.log('popList:', arr); console.log("popList:", arr);
pageData.popupList = arr; pageData.popupList = arr;
if (isRegister.value && userStore.password) { if (isRegister.value && userStore.password) {
registerSuccesVisible.value = true; registerSuccesVisible.value = true;
} else { } else {
if (appStore.hasShowActivity) { if (appStore.hasShowActivity) {
return return;
} }
if (pageData.popupList.length > 0) { if (pageData.popupList.length > 0) {
appStore.hasShowActivity = true appStore.hasShowActivity = true;
} }
console.log('pageData.popupList', pageData.popupList); console.log("pageData.popupList", pageData.popupList);
popupLogicJudgment(pageData.popupList[0]); popupLogicJudgment(pageData.popupList[0]);
} }
@ -544,8 +555,8 @@ const closePopup = (type, checkValue = false) => {
isRegister.value = false; isRegister.value = false;
userStore.isOneClickRegister = false; userStore.isOneClickRegister = false;
} }
if (type === 'giftCode') { if (type === "giftCode") {
jiliVisible.value = false jiliVisible.value = false;
} }
if (pageData.popupList.length - 1 >= popupIndex.value) { if (pageData.popupList.length - 1 >= popupIndex.value) {
const obj = pageData.popupList[popupIndex.value]; const obj = pageData.popupList[popupIndex.value];
@ -559,7 +570,9 @@ const closePopup = (type, checkValue = false) => {
* 弹窗逻辑判断 * 弹窗逻辑判断
*/ */
const popupLogicJudgment = (item) => { const popupLogicJudgment = (item) => {
if (!item) { return } if (!item) {
return;
}
if (item.popup == "firstdeposit") { if (item.popup == "firstdeposit") {
let value = uni.getStorageSync("checkEndTime"); let value = uni.getStorageSync("checkEndTime");
@ -590,52 +603,53 @@ const popupLogicJudgment = (item) => {
if (item.popup == "signin") { if (item.popup == "signin") {
signinVisible.value = true; signinVisible.value = true;
} }
if (item.popup === 'giftCode') { if (item.popup === "giftCode") {
jiliVisible.value = true jiliVisible.value = true;
} }
}; };
const date2Date = (dateStr) => { const date2Date = (dateStr) => {
const date = new Date(dateStr) const date = new Date(dateStr);
const year = date.getFullYear() const year = date.getFullYear();
const month = date.getMonth() const month = date.getMonth();
const day = date.getDate() const day = date.getDate();
return new Date(year, month, day) return new Date(year, month, day);
} };
function setDot(key, val) { function setDot(key, val) {
uni.setStorage({ uni.setStorage({
key, key,
data: val, data: val,
}) });
} }
function getDot(key) { function getDot(key) {
return uni.getStorageSync(key) return uni.getStorageSync(key);
} }
const checkUserAct = async () => { const checkUserAct = async () => {
const { data } = await checkRechargeActApi() const { data } = await checkRechargeActApi();
console.log("User activity", data); console.log("User activity", data);
actState.value = data.state actState.value = data.state;
if (data.state === 0 || (data.activity == null && data.detailList == null)) { if (data.state === 0 || (data.activity == null && data.detailList == null)) {
depositBonusRights.value = false depositBonusRights.value = false;
return return;
} }
depositBonusRights.value = true depositBonusRights.value = true;
if (data.state === 1) { if (data.state === 1) {
if (data.activity?.content) { if (data.activity?.content) {
const content = JSON.parse(data.activity?.content ?? '{}') const content = JSON.parse(data.activity?.content ?? "{}");
promoStore.rechargeContent = content promoStore.rechargeContent = content;
let doted = false let doted = false;
const dot = getDot('recharge_bonus') const dot = getDot("recharge_bonus");
if(dot === '') { if (dot === "") {
doted = true doted = true;
} }
slideItems.value.push({ slideItems.value.push({
el: conDepositPop.value, el: conDepositPop.value,
path: '', path: "",
icon: '@/static/pop_icons/deposit.gif', icon: "@/static/pop_icons/deposit.gif",
doted: doted, doted: doted,
dotName: 'recharge_bonus', dotName: "recharge_bonus",
}) count: 1
popupArr.value.push(conDepositPop.value) });
popupArr.value.push(conDepositPop.value);
} }
} }
if (data.state === 2) { if (data.state === 2) {
@ -643,15 +657,18 @@ const checkUserAct = async () => {
// Need to complete the game Galgame // Need to complete the game Galgame
if (data.detailList) { if (data.detailList) {
promoStore.detailList = data.detailList.map((item, index) => { promoStore.detailList = data.detailList.map((item, index) => {
const condition = JSON.parse(item.condition) const condition = JSON.parse(item.condition);
const games = condition.typeVal.filter(item => item.name !== '').map(item => { const games = condition.typeVal
return item?.name .filter((item) => item.name !== "")
}).join('、') .map((item) => {
return item?.name;
})
.join("、");
item.conditions = games item.conditions = games;
item.show = false item.show = false;
return item return item;
}) });
promoStore.detailList.unshift({ promoStore.detailList.unshift({
id: 1, id: 1,
@ -660,32 +677,34 @@ const checkUserAct = async () => {
status: 2, status: 2,
curBets: 1, curBets: 1,
maxBets: 1, maxBets: 1,
conditions: '', conditions: "",
show: false show: false,
}) });
const today = date2Date(Date.now()) const today = date2Date(Date.now());
const idx = promoStore.detailList.findIndex((i) => { const idx = promoStore.detailList.findIndex((i) => {
const endDate = date2Date(i.giveDate) const endDate = date2Date(i.giveDate);
return today.getTime() == endDate.getTime() return today.getTime() == endDate.getTime();
}) });
if (idx !== -1) { if (idx !== -1) {
promoStore.detailList[idx].show = true promoStore.detailList[idx].show = true;
} }
popupArr.value.push(depositBonusPop.value) popupArr.value.push(depositBonusPop.value);
const hasDot = promoStore.detailList.filter(item => item.status === 1).length > 0 const hasDot =
setDot('deposit_doted', hasDot) promoStore.detailList.filter((item) => item.status === 1).length > 0;
setDot("deposit_doted", hasDot);
slideItems.value.push({ slideItems.value.push({
el: depositBonusPop.value, el: depositBonusPop.value,
path: '', path: "",
icon: '@/static/pop_icons/deposit.gif', icon: "@/static/pop_icons/deposit.gif",
doted: hasDot, doted: hasDot,
dotName:'deposit_doted', dotName: "deposit_doted",
}) count: 1
});
} }
} }
} };
// onPullDownRefresh(async () => { // onPullDownRefresh(async () => {
// setTimeout(() => { // setTimeout(() => {
// uni.stopPullDownRefresh(); // uni.stopPullDownRefresh();
@ -697,148 +716,183 @@ const checkUserAct = async () => {
// showPopQueue() // showPopQueue()
// }) // })
const onBindPhoneComplete = () => { const onBindPhoneComplete = () => {
const idx = slideItems.value.findIndex(item => item.el === bindPhone.value) const idx = slideItems.value.findIndex((item) => item.el === bindPhone.value);
if (idx > -1) { if (idx > -1) {
slideItems.value.splice(idx, 1) slideItems.value.splice(idx, 1);
} }
} };
const bankruptArr = ref([]) const bankruptArr = ref([]);
const getUserBankrupt = async () => { const getUserBankrupt = async () => {
try { try {
const {data} = await checkBankruptApi() const { data } = await checkBankruptApi();
console.log('getUserBankrupt:', data); console.log("getUserBankrupt:", data);
const {state, details} = data const { state, details } = data;
if(state === 0) return if (state === 0) return;
if(state === 1) { if (state === 1) {
const arr = details.sort((a, b) => a.recharge - b.recharge) const arr = details.sort((a, b) => a.recharge - b.recharge);
bankruptArr.value = [arr[0], arr[2], arr[1]] bankruptArr.value = [arr[0], arr[2], arr[1]];
popupArr.value.push(greatPopRef.value) popupArr.value.push(greatPopRef.value);
let dot = getDot('bankrupt_doted')
if(dot === '') { let dot = getDot("bankrupt_doted");
setDot('bankrupt_doted', true) if (dot === "") {
dot = true dot = true;
} }
slideItems.value.push({ slideItems.value.push({
el: greatPopRef.value, el: greatPopRef.value,
path: '', path: "",
icon: '@/static/pop_icons/animation_bx.gif', icon: "@/static/pop_icons/animation_bx.gif",
doted: dot, doted: dot,
dotName: 'bankrupt_doted' dotName: "bankrupt_doted",
count: 1
}) });
return return;
} }
if(state === 2) { if (state === 2) {
let dot = getDot('bankrupt_doted') const idx = slideItems.value.findIndex((item) => item.dotName === 'bankrupt_doted');
if(dot === '') { const arr = details.sort((a, b) => a.recharge - b.recharge);
setDot('bankrupt_doted', true) bankruptArr.value = [arr[0], arr[2], arr[1]];
dot = true let dot = getDot("bankrupt_doted");
if (dot === "") {
dot = true;
} }
slideItems.value.push({ if (idx > -1) {
el: greatPopRef.value, slideItems.value[idx].doted = true;
path: '', } else {
icon: '@/static/pop_icons/animation_bx.gif', slideItems.value.push({
doted: dot, el: greatPopRef.value,
dotName: 'bankrupt_doted' path: "",
}) icon: "@/static/pop_icons/animation_bx.gif",
doted: dot,
dotName: "bankrupt_doted",
count: 1
});
}
console.log("bankruptArr:", slideItems.value);
} }
} catch (error) { } catch (error) {
console.log('getUserBankrupt error:', error); console.log("getUserBankrupt error:", error);
} }
} };
onLoad(async () => { onLoad(async () => {
console.log("onLoad");
uni.hideTabBar(); uni.hideTabBar();
okSpin.login() okSpin.login();
getBanner(); getBanner();
await getUserBankrupt()
await checkUserAct(); await checkUserAct();
checkRedepositApi().then(({ data }) => {
console.log("checkRedepositApi:", data); const wheelIdx = promoStore.promoList.findIndex(
if (data?.activity) { (item) => item.jumpUrl === "module:lottery"
const doted = getDot('wheel_doted') );
slideItems.value.push({
el: null,
path: '/pages/redeposit/ReDeposit',
icon: '@/static/pop_icons/animation_zp.gif',
doted: doted ? true : false,
dotName: 'wheel_doted'
})
}
if(data?.lottery?.lottery) {
const lottery = JSON.parse(data.lottery.lottery)
const count = lottery?.reduce((acc, cur) => {
return acc + cur.curCount
}, 0) ?? 0;
if(count > 0) {
const idx = slideItems.value.findIndex(item => item.dotName === 'wheel_doted')
setDot('wheel_doted', true)
slideItems.value[idx].doted = true
}
}
})
const wheelIdx = promoStore.promoList.findIndex(item => item.jumpUrl === 'module:lottery')
//console.log('wheelIdx', wheelIdx);
if (wheelIdx > -1) { if (wheelIdx > -1) {
popupArr.value.push(wheelPop.value) popupArr.value.push(wheelPop.value);
// slideItems.value.push({
// el: wheelPop.value,
// icon: '@/static/pop_icons/animation_zp.gif'
// })
} }
const todayStr = uni.getStorageSync('today') const todayStr = uni.getStorageSync("today");
const rewardDate = uni.getStorageSync('rewardDayonce') const rewardDate = uni.getStorageSync("rewardDayonce");
rewardDayonce.value = rewardDate === conversionTime() rewardDayonce.value = rewardDate === conversionTime();
today.value = todayStr today.value = todayStr;
if (userStore.userInfo?.firstRecharge === 0 && todayStr !== conversionTime()) { if (
popupArr.value.push(firstRechargePop.value) userStore.userInfo?.firstRecharge === 0 &&
todayStr !== conversionTime()
) {
popupArr.value.push(firstRechargePop.value);
} }
if (!userStore.userInfo?.mobile) { if (!userStore.userInfo?.mobile) {
// #ifdef APP-PLUS // #ifdef APP-PLUS
popupArr.value.push(bindPromoPop.value) popupArr.value.push(bindPromoPop.value);
// #endif // #endif
slideItems.value.push({ slideItems.value.push({
el: bindPhone.value, el: bindPhone.value,
path: '', path: "",
icon: '@/static/pop_icons/animation_verify.gif', icon: "@/static/pop_icons/animation_verify.gif",
doted: true, doted: true,
dotName: 'bind_doted' dotName: "bind_doted",
}) count: 1
});
} else {
const idx = slideItems.value.findIndex(
(item) => item.dotName === "bind_doted"
);
if (idx > -1) {
slideItems.value.splice(idx, 1);
}
} }
const promoIdx = promoStore.promoList.findIndex(item => item.content?.popup === 'betrank') const promoIdx = promoStore.promoList.findIndex(
(item) => item.content?.popup === "betrank"
);
if (promoIdx !== -1) { if (promoIdx !== -1) {
// popupArr.value.push(rankRewardPop.value) // popupArr.value.push(rankRewardPop.value)
let doted = false let doted = false;
const dot = getDot('rank_doted') const dot = getDot("rank_doted");
if(dot === '') { if (dot === "") {
doted = true doted = true;
} }
slideItems.value.push({ slideItems.value.push({
el: null, el: null,
path: '/pages/promo/Ranking/Ranking', path: "/pages/promo/Ranking/Ranking",
icon: '@/static/pop_icons/animation_phb.gif', icon: "@/static/pop_icons/animation_phb.gif",
doted: doted, doted: doted,
dotName: 'rank_doted' dotName: "rank_doted",
}) count: 1
});
} }
setTimeout(() => { setTimeout(() => {
// conDepositPop.value.open() showPopQueue();
// depositBonusPop.value.open() showSlider.value = true;
slideOpen.value = true;
showPopQueue()
showSlider.value = true
slideOpen.value = true
// greatPopRef.value.open()
}, 1000); }, 1000);
}); });
onShow(() => { onShow(() => {
getUserBankrupt();
getPageData(); getPageData();
}) checkRedepositApi().then(({ data }) => {
const idx = slideItems.value.findIndex(
(item) => item.dotName === "wheel_doted"
);
if (idx < 0) {
if (data?.activity) {
const doted = getDot("wheel_doted");
slideItems.value.push({
el: null,
path: "/pages/redeposit/ReDeposit",
icon: "@/static/pop_icons/animation_zp.gif",
doted: doted ? true : false,
count: 1,
dotName: "wheel_doted",
});
}
if (data?.lottery?.lottery) {
const idx2 = slideItems.value.findIndex(
(item) => item.dotName === "wheel_doted"
);
const lottery = JSON.parse(data.lottery.lottery);
const count =
lottery?.reduce((acc, cur) => {
return acc + cur.curCount;
}, 0) ?? 0;
setDot("wheel_doted", true);
slideItems.value[idx2].doted = true;
slideItems.value[idx2].count = count;
}
} else {
if (data?.lottery?.lottery) {
const lottery = JSON.parse(data.lottery.lottery);
const count =
lottery?.reduce((acc, cur) => {
return acc + cur.curCount;
}, 0) ?? 0;
setDot("wheel_doted", true);
slideItems.value[idx].doted = true;
slideItems.value[idx].count = count;
}
}
});
});
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
@ -981,10 +1035,10 @@ onShow(() => {
.slider-box { .slider-box {
background-color: rgba(0, 0, 0, 0.7); background-color: rgba(0, 0, 0, 0.7);
max-height: 640rpx; max-height: 740rpx;
// min-height: 360rpx; // min-height: 360rpx;
border-radius: 20rpx; border-radius: 20rpx;
border: 2px solid #FCCA0F; border: 2px solid #fcca0f;
padding: 14rpx; padding: 14rpx;
.slide-item { .slide-item {
@ -993,15 +1047,19 @@ onShow(() => {
&:last-child { &:last-child {
margin-bottom: 0; margin-bottom: 0;
} }
.red-dot{
width: 20rpx; .red-dot {
height: 20rpx; width: 24rpx;
height: 24rpx;
border-radius: 50%; border-radius: 50%;
background-color: red; background-color: red;
position: absolute; position: absolute;
top: 0; top: 0;
right: 0; right: 0;
font-size: 18rpx;
color: "#FFCE18";
} }
.icon-slide-menu { .icon-slide-menu {
width: 98rpx; width: 98rpx;
height: 98rpx; height: 98rpx;

View File

@ -64,7 +64,7 @@
nextTick(() => { nextTick(() => {
setTimeout(() => { setTimeout(() => {
startMove() startMove()
}, 200); }, 500);
}) })
} }

View File

@ -36,7 +36,7 @@ import HomeNotice from '@/pages/home/components/HomeNotice.vue'
import { useAppStore } from '@/store/useAppStore.js' import { useAppStore } from '@/store/useAppStore.js'
import { useUserStore } from '@/store/useUserStore' import { useUserStore } from '@/store/useUserStore'
import { enterFullscreen, exitFullscreen } from '@/module/fullscreen/fullscreen-handler' import { enterFullscreen, exitFullscreen } from '@/module/fullscreen/fullscreen-handler'
import { requestGetGameUrlByGame, requestJiliLogout } from '@/api/game.js' import { gameOutApi, requestGetGameUrlByGame, requestJiliLogout } from '@/api/game.js'
const appStore = useAppStore() const appStore = useAppStore()
const userStore = useUserStore() const userStore = useUserStore()
@ -144,6 +144,9 @@ const injectPreventFullscreen = () => {
} }
// #endif // #endif
} }
const reportGameOut = () => {
gameOutApi()
}
onMounted(() => { onMounted(() => {
enterFullscreen() enterFullscreen()
injectPreventFullscreen() injectPreventFullscreen()
@ -165,6 +168,7 @@ onUnmounted(() => {
uni.offWindowResize(computeWebviewHeight) uni.offWindowResize(computeWebviewHeight)
stopReport() stopReport()
requestJiliLogout() requestJiliLogout()
reportGameOut()
}) })
const startReport = () => { const startReport = () => {

View File

@ -1,6 +1,6 @@
import { defineConfig } from 'vite' import { defineConfig } from 'vite'
import uni from '@dcloudio/vite-plugin-uni' import uni from '@dcloudio/vite-plugin-uni'
import compression from 'vite-plugin-compression' // import compression from 'vite-plugin-compression'
// https://vitejs.dev/config/ // https://vitejs.dev/config/
export default defineConfig({ export default defineConfig({
@ -15,12 +15,11 @@ export default defineConfig({
// deleteOriginFile: false, // 是否删除原文件 // deleteOriginFile: false, // 是否删除原文件
// }), // }),
], ],
// resolve: { resolve: {
// alias: { alias: {
// '@': '/src', '@': '/src'
// 'vue-i18n': 'vue-i18n/dist/vue-i18n.cjs.js' }
// } },
// },
css: { css: {
preprocessorOptions: { preprocessorOptions: {
scss: { scss: {