tangning il y a 1 jour
Parent
commit
6224909fdd
2 fichiers modifiés avec 3 ajouts et 2 suppressions
  1. 1 1
      src/app/map/App.vue
  2. 2 1
      src/hook/treeSelect.ts

+ 1 - 1
src/app/map/App.vue

@@ -17,7 +17,7 @@
     </div> -->
     <div class="left">
       <el-form-item label="" class="filter">
-        <com-company v-model="state.deptId" :id="state.caseId" hideAll />
+        <com-company v-model="state.deptId" hideAll />
       </el-form-item>
       <el-form-item label="" class="filter">
         <el-input v-model:modelValue="keywordSearch" placeholder="输入关键字"></el-input>

+ 2 - 1
src/hook/treeSelect.ts

@@ -42,6 +42,7 @@ const treeSelectOptionCover = <T>(
   );
 
 const getTreePath = (options: TreeOption[], value: string): null | string[] => {
+  
   for (const option of options) {
     if (option.value === value) {
       return [option.value];
@@ -123,7 +124,7 @@ export const useTreeSelect = <T>(
   const path = computed({
     get: () => getTreePath(options.value, props.modelValue)!,
     set: (path) => {
-      console.log("path", path);
+      console.log("path", path, props);
       update(path ? path[path.length - 1] : "");
     },
   });