You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kylin.apache.org by xx...@apache.org on 2023/02/09 08:13:02 UTC
[kylin] 03/04: KYLIN-5423 refine hive datasource table loading more issue
This is an automated email from the ASF dual-hosted git repository.
xxyu pushed a commit to branch kylin5
in repository https://gitbox.apache.org/repos/asf/kylin.git
commit d7af308ea77d63bef92d957ac31cebe49ad420b1
Author: Qian Xia <la...@gmail.com>
AuthorDate: Thu Feb 9 15:26:28 2023 +0800
KYLIN-5423 refine hive datasource table loading more issue
---
kystudio/src/components/common/TreeList/index.vue | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/kystudio/src/components/common/TreeList/index.vue b/kystudio/src/components/common/TreeList/index.vue
index 37f450f46b..ba4ee86d3a 100644
--- a/kystudio/src/components/common/TreeList/index.vue
+++ b/kystudio/src/components/common/TreeList/index.vue
@@ -237,7 +237,7 @@ export default class TreeList extends Vue {
}
if (type === 'isMore') {
- node.visible = data.parent.children.length !== 1 || data.parent.children.length === 0
+ node.visible = (data.parent.children.length !== 1 || data.parent.children.length === 0) && !data.parent.isLoading
}
if (data.isHidden !== undefined) {
node.visible = !data.isHidden
@@ -271,7 +271,8 @@ export default class TreeList extends Vue {
data.parent.child_options.page_offset += 1
'childContent' in data.parent && (data.parent.children = data.parent.childContent.slice(0, data.parent.child_options.page_offset * data.parent.child_options.page_size - 1))
data.parent.isMore = data.parent.child_options.page_offset * data.parent.child_options.page_size < data.parent.childContent.length
- } else {
+ } else if (!data.parent.isLoading) {
+ data.parent.isLoading = true
this.$emit('load-more', data, node)
}
break
@@ -384,9 +385,13 @@ export default class TreeList extends Vue {
// margin:0 auto;
width: auto;
background: white;
- flex: none;
cursor: default;
- margin-left: calc(50% - 16px)!important;
+ .el-loading-mask {
+ left: -42px;
+ .el-loading-spinner {
+ left: 50%;
+ }
+ }
.el-loading-spinner {
width: 16px;
}