perf(手机端): 资料中心结构树添加loading
This commit is contained in:
@@ -4,7 +4,8 @@
|
||||
:style="{ height: '100%', width: '90%' }"
|
||||
round
|
||||
:close-on-click-overlay="false"
|
||||
@click-overlay="handleCancel">
|
||||
@click-overlay="handleCancel"
|
||||
get-container="body">
|
||||
<h3 class="popup-title">
|
||||
<span>体系结构</span>
|
||||
<van-icon name="cross" size="22px" @click="handleCancel" />
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
<span style="font-size:18px"> {{ node.label }} </span>
|
||||
</span>
|
||||
</el-tree>
|
||||
<loading :loading="loading">加载中...</loading>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -31,7 +32,8 @@ export default {
|
||||
label: 'name',
|
||||
children: 'children'
|
||||
},
|
||||
currentKey: ''
|
||||
currentKey: '',
|
||||
loading: false
|
||||
}
|
||||
},
|
||||
created () {
|
||||
@@ -39,10 +41,13 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
getTreeData () {
|
||||
this.loading = true
|
||||
this.$http._getData('fileMaterialCenter/zlTree').then(res => {
|
||||
if (res.ok && res.data) {
|
||||
this.treeList = res.data
|
||||
}
|
||||
}).finally(() => {
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
filterNode (value, data) {
|
||||
|
||||
Reference in New Issue
Block a user