From 0c70227fc2ace5da24f27515574981310643c4be Mon Sep 17 00:00:00 2001
From: ludc
Date: 星期四, 26 十月 2023 18:24:08 +0800
Subject: [PATCH] bug修改提交
---
Source/UBCS-WEB/src/components/Master/MasterTree.vue | 39 +++++++++++++++++++++++++++++++--------
1 files changed, 31 insertions(+), 8 deletions(-)
diff --git a/Source/UBCS-WEB/src/components/Master/MasterTree.vue b/Source/UBCS-WEB/src/components/Master/MasterTree.vue
index 7e248d2..f24b41c 100644
--- a/Source/UBCS-WEB/src/components/Master/MasterTree.vue
+++ b/Source/UBCS-WEB/src/components/Master/MasterTree.vue
@@ -1,9 +1,11 @@
<template>
- <avue-tree ref="tree" v-model="CloneTreeAvueform" v-loading="loading" :data="Treedata" :defaultExpandAll="false"
- :option="Treeoption"
- style="height: calc(100vh - 150px);"
- @node-click=" nodeClick"
- ></avue-tree>
+ <div class="app">
+ <avue-tree ref="tree" v-model="CloneTreeAvueform" v-loading="loading" :data="Treedata" :defaultExpandAll="false" :option="Treeoption" @node-click="nodeClick" style="width: fit-content;">
+ <template slot-scope="{ node }">
+ <span style="display: inline-block;">{{ node.label }}</span>
+ </template>
+ </avue-tree>
+ </div>
</template>
<script>
@@ -28,6 +30,7 @@
},
data() {
return {
+ TreeValue:'',
idData: '',
masterVrBtnList: [],
tableHeadFindData: [],
@@ -94,7 +97,7 @@
}
}
}).catch(res => {
- console.log(res)
+ // console.log(res)
this.$message.error(res)
});
},
@@ -146,7 +149,7 @@
List.forEach(item => {
let columnItem = {
label: item.title,
- prop: item.field,
+ prop: item.queryField,
// type: this.columnType[item.type],
sortable: item.sort,
width: item.minWidth
@@ -165,6 +168,10 @@
//鏍戠偣鍑讳簨浠�
async nodeClick(data) {
try {
+ // console.log(data)
+ this.TreeValue=data.label.split(" ")[0].trim();
+ // console.log('TreeValue',this.TreeValue)
+ this.$emit('TreeValue',this.TreeValue)
this.nodeClickList = data;
this.tableHeadDataFateher = []
this.tableHeadFindData = []
@@ -181,6 +188,22 @@
}
</script>
-<style scoped>
+<style lang="scss" scoped>
+.app{
+ overflow: auto;
+ height: calc(100vh - 150px);
+}
+ .app::-webkit-scrollbar {
+ height: 15px ; // 绾靛悜婊氬姩鏉� 蹇呭啓
+ background: white;
+ border: white;
+ width: 10px;
+}
+// 婊氬姩鏉$殑婊戝潡
+ .app::-webkit-scrollbar-thumb {
+ background-color: #ececec;
+ border-radius: 20px;
+ border: #ececec;
+}
</style>
--
Gitblit v1.9.3