Parcourir la source

是否显示复选框条件判断

duy il y a 3 mois
Parent
commit
42ec73313f
1 fichiers modifiés avec 8 ajouts et 3 suppressions
  1. 8 3
      src/views/data-fill/division.vue

+ 8 - 3
src/views/data-fill/division.vue

@@ -37,7 +37,7 @@
                     <HcLazyTree
                         v-model:loading="isLoading"
                         :is-auto-check="true"
-                        show-checkbox
+                        :show-checkbox="isShowCheckbox"
                         :auto-expand-keys="treeAutoExpandKeys"
                         is-counts
                         is-type
@@ -1126,7 +1126,7 @@ import HcTreeData1 from './components/division/HcTreeData1.vue'
 import DivisionTree from './components/division/DivisionTree.vue'
 import HcTreeNode from './components/HcTreeNode.vue'
 import divisionDialog from './components/divisionDialog.vue'
-
+import { HcIsButton } from '~src/plugins/IsButtons'
 import {
     arrIndex,
     arrToId,
@@ -1170,7 +1170,7 @@ watch(
         isCollapse.value = Collapse
     },
 )
-
+const isShowCheckbox = ref(false)
 //自动展开缓存
 const treeAutoExpandKeys = ref(getStoreValue('wbsTreeExpandKeys') || [])
 //自动展开缓存
@@ -1182,6 +1182,11 @@ watch(isLoading, (newVal) => {
 })
 //渲染完成
 onMounted(() => {
+    if (HcIsButton('data-division-batch-btn')) {
+        isShowCheckbox.value = true
+    } else {
+        isShowCheckbox.value = false
+    }
     //setElTreeMenu()
     getWbsNodeTypeApi()
     getMajorDataTypeApi()