generated from Leo_Ding/web-template
Compare commits
3 Commits
b0af79cb08
...
65ea48af37
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
65ea48af37 | ||
|
|
f31e60914b | ||
|
|
36f5af21da |
@ -1,4 +1,5 @@
|
||||
<template>
|
||||
<a-spin :spinning="spinning" tip="Loading..." size="large">
|
||||
<a-layout class="layout">
|
||||
<template #default>
|
||||
<!-- 上下布局 -->
|
||||
@ -30,7 +31,8 @@
|
||||
<template #left>
|
||||
<brand :theme="config.headerTheme"></brand>
|
||||
</template>
|
||||
<basic-menu mode="horizontal" :theme="config.headerTheme" :data-list="topMenuList"></basic-menu>
|
||||
<basic-menu mode="horizontal" :theme="config.headerTheme"
|
||||
:data-list="topMenuList"></basic-menu>
|
||||
</basic-header>
|
||||
<a-layout>
|
||||
<template v-if="sideMenuList.length">
|
||||
@ -104,7 +106,7 @@
|
||||
</template>
|
||||
</template>
|
||||
</a-layout>
|
||||
|
||||
</a-spin>
|
||||
<config-dialog ref="configDialogRef"></config-dialog>
|
||||
</template>
|
||||
|
||||
@ -127,15 +129,22 @@ defineOptions({
|
||||
})
|
||||
|
||||
useMultiTab()
|
||||
|
||||
const spinning = ref(false)
|
||||
const appStore = useAppStore()
|
||||
const dicsStore = useDicsStore()
|
||||
initData()
|
||||
async function initData() {
|
||||
storage.local.setItem('companyId','C001')
|
||||
try {
|
||||
spinning.value = true
|
||||
storage.local.setItem('companyId', 'C001')
|
||||
await dicsStore.loadProvinces() // 加载省份数据
|
||||
await dicsStore.loadAllDictData() // 加载字典数据
|
||||
await dicsStore.loadOrgTree()
|
||||
spinning.value = false
|
||||
} catch (error) {
|
||||
spinning.value = false
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
const { sideMenuList, topMenuList } = useMenu()
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user