搜索结果列表页面开发

This commit is contained in:
付民康
2025-03-12 18:41:20 +08:00
commit 7cebe8fc00
739 changed files with 88149 additions and 0 deletions

View File

@@ -0,0 +1,40 @@
<template>
<!-- 用户主页 -->
<UserLayout v-if="globalStore.namespaceType === 0 && username">
<template #content>
<UserMobilePage v-if="isPhone()" />
<UserPage v-else/>
<!-- <RouterView /> -->
<!-- <micro-app name="user-center" :url="url" iframe baseroute="/"></micro-app> -->
</template>
</UserLayout>
<!-- 组织主页 -->
<OrgLayout v-if="globalStore.namespaceType === 1 && orgStore.orgInfo.id">
<template #content>
<OrgMobilePage v-if="isPhone()" />
<OrgPage v-else />
</template>
</OrgLayout>
</template>
<!-- 用户主页 or 组织首页 -->
<script setup lang="ts">
import isPhone from '@/utils/isPhone';
import UserLayout from '@/layouts/UserLayout/index.vue';
import UserPage from '../User/index.vue';
import UserMobilePage from '@/views/Mobile/User/index.vue';
import OrgLayout from '@/layouts/OrgLayout/index.vue';
import OrgPage from '@/views/Org/index.vue';
import OrgMobilePage from '@/views/Mobile/Org/index.vue';
import { useGlobalInfoStore } from '@/stores/Global';
import { orgInfoStore } from '@/stores/Org/index';
import { otherAccountStore } from '@/stores/user';
import { watch, computed } from 'vue';
const globalStore = useGlobalInfoStore();
const orgStore = orgInfoStore();
const otherStore = otherAccountStore();
const username = computed(() => { // 切换用户主页和组织主页时,刷新渲染
return otherStore.accountInfo.username || 'unknown';
})
</script>