fix:【数据源】数据源列表缺少状态显示

This commit is contained in:
taojinlong 2024-10-28 15:53:39 +08:00
parent a965640597
commit b565414c0d
2 changed files with 18 additions and 3 deletions

View File

@ -1155,8 +1155,11 @@ public class DatasourceServer implements DatasourceApi {
if (!Arrays.asList("API", "Excel", "folder").contains(coreDatasource.getType())) {
calciteProvider.updateDsPoolAfterCheckStatus(datasourceDTO);
}
} catch (DEException e) {
datasourceDTO.setStatus("Error");
DEException.throwException(e.getMessage());
} catch (Exception e) {
coreDatasource.setStatus("Error");
datasourceDTO.setStatus("Error");
DEException.throwException(e.getMessage());
} finally {
coreDatasource.setStatus(datasourceDTO.getStatus());

View File

@ -380,7 +380,6 @@ const initSearch = () => {
state.filterTable = tableData.value.filter(ele =>
ele.tableName.toLowerCase().includes(nickName.value.toLowerCase())
)
console.log(tableData.value)
state.paginationConfig.total = state.filterTable.length
}
@ -867,7 +866,6 @@ const operation = (cmd: string, data: Tree, nodeType: string) => {
}
const handleClick = (tabName: TabPaneName) => {
console.log(tabName)
switch (tabName) {
case 'config':
listDatasourceTables({ datasourceId: nodeInfo.id }).then(res => {
@ -1091,8 +1089,22 @@ const getMenuList = (val: boolean) => {
:title="node.label"
class="label-tooltip ellipsis"
:class="data.type === 'Excel' && 'excel'"
v-if="data.extraFlag > -1"
>{{ node.label }}</span
>
<el-tooltip
effect="dark"
v-else
:content="`${t('data_set.invalid_data_source')}: ${node.label}`"
placement="top"
>
<span
:title="node.label"
class="label-tooltip ellipsis"
:class="data.type === 'Excel' && 'excel'"
>{{ node.label }}</span
>
</el-tooltip>
<div class="icon-more" v-if="data.weight >= 7">
<handle-more
icon-size="24px"