fix: 开源版可以看到行列权限菜单,但切换后显示空白页面

This commit is contained in:
dataeaseShu 2023-12-12 16:44:41 +08:00
parent 653b3e55b1
commit b4198a82e3

View File

@ -420,6 +420,23 @@ const defaultProps = {
label: 'name' label: 'name'
} }
const defaultTab = [
{
title: t('chart.data_preview'),
name: 'dataPreview'
},
{
title: '结构预览',
name: 'structPreview'
}
]
const tablePanes = ref([])
const tablePaneList = computed(() => {
return nodeInfo.weight >= 7 ? [...defaultTab, ...tablePanes.value] : [...defaultTab]
})
const panelLoad = paneInfo => {
tablePanes.value = paneInfo
}
const datasetListTree = ref() const datasetListTree = ref()
watch(nickName, (val: string) => { watch(nickName, (val: string) => {
@ -587,19 +604,17 @@ const getMenuList = (val: boolean) => {
</div> </div>
<div class="tab-border"> <div class="tab-border">
<el-tabs v-model="activeName" @tab-change="handleClick"> <el-tabs v-model="activeName" @tab-change="handleClick">
<el-tab-pane :label="t('chart.data_preview')" name="dataPreview"></el-tab-pane>
<el-tab-pane label="结构预览" name="structPreview"></el-tab-pane>
<el-tab-pane <el-tab-pane
v-if="nodeInfo.weight >= 7" v-for="ele in tablePaneList"
:label="t('dataset.row_permissions')" :key="ele.name"
name="row" :label="ele.title"
></el-tab-pane> :name="ele.name"
<el-tab-pane
v-if="nodeInfo.weight >= 7"
:label="t('dataset.column_permissions')"
name="column"
></el-tab-pane> ></el-tab-pane>
</el-tabs> </el-tabs>
<XpackComponent
jsname="L2NvbXBvbmVudC9yb3ctY29sLXBlcm1pc3Npb24vcGFuZS9pbmRleA=="
@loaded="panelLoad"
/>
</div> </div>
</div> </div>
<div class="dataset-table-info"> <div class="dataset-table-info">