12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152 |
- <template>
- <view class="page-content">
- <mx-nav-bar title="志愿表"/>
- <mx-tabs-swiper v-model="current" :tabs="tabs" border>
- <template #AI志愿>
- <ai-list/>
- </template>
- <template #模拟志愿>
- <multiple-list/>
- </template>
- </mx-tabs-swiper>
- </view>
- </template>
- <script>
- import MxConst from "@/common/MxConst";
- import AiListItem from "@/pages/ie/entry-ai-list/components/ai-list-item.vue";
- import AiList from "@/pages/ie/entry-ai-list/components/ai-list.vue";
- import MultipleList from "@/pages/ie/entry-ai-list/components/multiple-list.vue";
- import {useTransfer} from "@/hooks/useTransfer";
- import {useProvideMajorTreeService} from "@/pages/ie/hooks/useMajorTreeInjection";
- export default {
- components: {MultipleList, AiList, AiListItem},
- data() {
- return {
- current: 0,
- tabs: [
- {name: 'AI志愿', type: MxConst.enum.ai.voluntaryType.ai},
- {name: '模拟志愿', type: MxConst.enum.ai.voluntaryType.multiple}
- ]
- };
- },
- setup() {
- const {prevData} = useTransfer()
- useProvideMajorTreeService()
- return {
- prevData
- }
- },
- mounted() {
- if (!isNaN(this.prevData.tab)) {
- // switch default tab.
- this.current = this.prevData.tab * 1
- }
- }
- }
- </script>
- <style lang="scss" scoped>
- </style>
|