From f5f8aaedd1d488fb20a293182dd7a40e2e82096e Mon Sep 17 00:00:00 2001
From: wangting <675591594@qq.com>
Date: 星期二, 30 四月 2024 12:20:44 +0800
Subject: [PATCH] 添加action

---
 Source/ProjectWeb/src/components/dynamic-components/dynamic-tree.vue |   16 ++++++++++++++--
 1 files changed, 14 insertions(+), 2 deletions(-)

diff --git a/Source/ProjectWeb/src/components/dynamic-components/dynamic-tree.vue b/Source/ProjectWeb/src/components/dynamic-components/dynamic-tree.vue
index ad9135f..191c5e3 100644
--- a/Source/ProjectWeb/src/components/dynamic-components/dynamic-tree.vue
+++ b/Source/ProjectWeb/src/components/dynamic-components/dynamic-tree.vue
@@ -1,6 +1,7 @@
 <template>
   <div class="UI-dynamic" :id="'UI-dynamic-'+areasName+componentVO.oid">
     <dynamic-button v-if="componentVO.buttons && componentVO.buttons.length>0" :componentVO="componentVO"
+                    :key="areasName+'buttons-'+componentVO.oid"
                     :butttonList="componentVO.buttons" :dataStore="checkDatas"
                     :sourceData="sourceData" type="tree" style="margin-bottom: 5px;"></dynamic-button>
     <el-input
@@ -48,6 +49,11 @@
     inDialog: {
       type: Boolean,
       default: false
+    },
+    canEdit:{
+      //鍐呭鏄惁鍙紪杈�
+      type:Boolean,
+      default:false
     },
     areasName:{
       type:String,
@@ -189,7 +195,7 @@
         textField: this.componentVO.treeDefineVO.treeNodeExpression,
         queryTemplate: this.sourceData.querytemplate,
         linkTypeFlag: validatenull(this.sourceData.queryType) ? (validatenull(this.sourceData.linkType) ? false : true) : (this.sourceData.queryType == 0 ? false : true),
-        rootExpress: this.componentVO.treeDefineVO.rootExpress
+        rootExpress: this.componentVO.treeDefineVO.rootExpress || ''
       }
       const sourceDataMapList = this.sourceDataMapParams;
 
@@ -213,7 +219,13 @@
         parentOid = parentOid.split('@vcitreesep@')[1];
       }
       const parentBtmName = (node.level === 0) ? '' : node.data.attributes.btmname;
-      getTree(parentOid, parentBtmName, this.params).then(res => {
+      const params=this.params;
+      if(node.level === 0){
+        params.queryRoot= true;
+      }else {
+        delete params.queryRoot;
+      }
+      getTree(parentOid, parentBtmName, params).then(res => {
         resolve(res.data.treeData)
       }).catch(error => {
         this.$message.error(error);

--
Gitblit v1.9.3