CzRger пре 5 дана
родитељ
комит
569a04f88f
1 измењених фајлова са 9 додато и 1 уклоњено
  1. 9 1
      src/views/web/list/index-worker.vue

+ 9 - 1
src/views/web/list/index-worker.vue

@@ -56,7 +56,10 @@
                 <template v-if="item.__expend">
                   <template v-for="son in item.children">
                     <div class="item-son __hover" :class="{active: son.__id === state.resultParams.activeKey}" @click="state.resultParams.activeIndex = son.treeId, state.resultParams.activeKey = son.__id" v-if="son.__count > 0">
-                      {{son.treeName}}<span class="total">({{son.__count}})</span>
+                      {{son.treeName}}<span class="total">(
+                      {{son.__count}}
+                        <template v-if="son.__term"> / <span style="color: red">{{ son.__term }}</span></template>
+                      )</span>
                     </div>
                   </template>
                 </template>
@@ -620,10 +623,15 @@ const initWorker = () => {
                               v.__count = index.data
                               type.__count = type.__count ? (type.__count + index.data) : index.data
                               tag.__count = tag.__count ? (tag.__count + index.data) : index.data
+                              // 全命中数量
+                              v.__term = index.term
+                              type.__term = type.__term ? (type.__term + index.term) : index.term
+                              tag.__term = tag.__term ? (tag.__term + index.term) : index.term
                             }
                           })
                         })
                         type.children.sort((a, b) => b.__count - a.__count)
+                        type.children.sort((a, b) => b.__term - a.__term)
                       }
                     })
                   }