戴艳蓉 3 years ago
parent
commit
aac4d5d864
1 changed files with 7 additions and 10 deletions
  1. 7 10
      src/views/interest/organize/index.vue

+ 7 - 10
src/views/interest/organize/index.vue

@@ -12,7 +12,7 @@
                 class="my-breadcrumb-item"
                 v-for="(item, index) in titleList"
                 :key="item + index"
-                :class="{ chover: index + 1 !== titleList.length }"
+                :class="{ chover: true }"
                 @click="changeBreadcrumb(index)"
               >
                 <span class="label">{{ item.titleName }}</span
@@ -63,7 +63,7 @@
                   @click="
                     addEditFn(
                       0,
-                      parmValue && parmValue.pid!=='' ? parmValue.pid : '0',
+                      parmValue && parmValue.pid !== '' ? parmValue.pid : '0',
                       1,
                       false,
                       true,
@@ -159,12 +159,7 @@ export default {
   },
   data() {
     return {
-      titleList: [
-        {
-          id: 0,
-          titleName: "北京华软中维科技服务有限公司",
-        },
-      ],
+      titleList: [],
       sitem: null,
 
       statusList: statusList,
@@ -204,12 +199,14 @@ export default {
     },
 
     async changeBreadcrumb(index) {
-      console.log(index);
       if (index + 1 !== this.titleList.length) {
         this.parmValue.pid = this.titleList[index].id;
         this.titleList = this.titleList.slice(0, index + 1);
-        await this.searchList();
+      } else {
+        this.parmValue.pid = 0;
+        this.titleList = [];
       }
+      await this.searchList();
     },
     async openChildren(item) {
       this.parmValue.pid = item.id;