完成抽奖页面,结果页面事件逻辑,待给到设计稿更新页面
This commit is contained in:
@@ -2,8 +2,10 @@
|
||||
<div class="home">
|
||||
<Index v-if="showIndex" @IndexPage="indexFn"></Index>
|
||||
<Question v-if="showQuestion" @QuestionPage="questionFn"></Question>
|
||||
<Loading v-if="showLoad" @LoadPage="loadFn"></Loading>
|
||||
<Result v-if="showResult" @ResultPage="resultFn"></Result>
|
||||
<MyPrize v-if="showMyPrize" @MyPrizePage="myPrizeFn"></MyPrize>
|
||||
<Draw v-if="showDraw" @DrawPage="drawFn"></Draw>
|
||||
<Loading v-if="showLoad" @LoadPage="loadFn"></Loading>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -13,6 +15,8 @@ import Loading from "@/components/Loading";
|
||||
import Index from "@/components/Index";
|
||||
import Question from "@/components/Question";
|
||||
import MyPrize from "@/components/MyPrize";
|
||||
import Draw from "@/components/Draw";
|
||||
import Result from "@/components/Result";
|
||||
import { createBGM } from "@/plugins";
|
||||
|
||||
const showLoad = ref(true);
|
||||
@@ -50,6 +54,20 @@ const myPrizeFn = (item) => {
|
||||
}
|
||||
};
|
||||
|
||||
const showDraw = ref(false);
|
||||
const drawFn = (item) => {
|
||||
if (item.action == "hide") {
|
||||
showDraw.value = false;
|
||||
}
|
||||
};
|
||||
|
||||
const showResult = ref(true);
|
||||
const resultFn = (item) => {
|
||||
if (item.action == "hide") {
|
||||
showResult.value = false;
|
||||
}
|
||||
};
|
||||
|
||||
onMounted(() => {
|
||||
// createBGM();
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user