完成部分接口联调
This commit is contained in:
@@ -4,9 +4,12 @@ import gsap from "gsap";
|
||||
import { debounceTap } from "@/plugins";
|
||||
import Preloader from "@/plugins/Preloader";
|
||||
import { loadImg, pageImg } from "@/data/imgList";
|
||||
import {getMyPrize} from '@/api'
|
||||
import {useMainStore} from '@/store'
|
||||
|
||||
// 页面配置初始化
|
||||
const emit = defineEmits(["LoadPage"]);
|
||||
const userStore = useMainStore()
|
||||
|
||||
const loadNum = ref(0);
|
||||
|
||||
@@ -43,6 +46,13 @@ onMounted(() => {
|
||||
duration: 0.2,
|
||||
autoAlpha: 1,
|
||||
onComplete: () => {
|
||||
getMyPrize({},userStore.token).then(
|
||||
res=>{
|
||||
if(res.code == 0){
|
||||
console.log('我的奖品',res);
|
||||
}
|
||||
}
|
||||
)
|
||||
Preloader({
|
||||
name: "内页资源",
|
||||
imgs: pageImg,
|
||||
@@ -53,6 +63,7 @@ onMounted(() => {
|
||||
},
|
||||
}).then((res) => {
|
||||
console.log("加载完成");
|
||||
|
||||
gsap.to(".LoadPage", {
|
||||
duration: 1,
|
||||
autoAlpha: 0,
|
||||
@@ -65,6 +76,9 @@ onMounted(() => {
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
||||
Reference in New Issue
Block a user