优化标签的总数量展示

This commit is contained in:
WangHao 2021-11-07 02:15:33 +08:00
parent 3a6b44d309
commit 375215a031
2 changed files with 21 additions and 5 deletions

View File

@ -293,7 +293,7 @@
}
},
callback: {
// beforeClick: this.BeforeClick,
beforeClick: this.BeforeClick,
onClick: this.OnClickzTree,
// onCheck: this.zTreeOnCheck,
//
@ -316,6 +316,8 @@
}
},
zNodes: [],
//ztree treeNode
treeNodeClick:undefined,
bookmark: [],
inputVisible: false, //
inputValue: '', //
@ -759,6 +761,11 @@
},
addHoverDom: function (treeId, treeNode) {
// console.log("addHoverDom...........")
if (this.treeNodeClick !=null && this.treeNodeClick !=undefined){
// removeHoverDom
this.removeHoverDom(null,this.treeNodeClick);
}
var confCount = $("." + treeNode.tId + "_sz").length;
if (confCount > 0) return;
$("." + treeNode.tId + "_sz").unbind().remove();
@ -771,6 +778,8 @@
},
removeHoverDom: function (treeId, treeNode) {
// console.log("removeHoverDom...........")
$("." + treeNode.tId + "_count").unbind().remove();
$("." + treeNode.tId + "_sz").unbind().remove();
var switchObjspan = $("#" + treeNode.tId + "_span");
@ -781,6 +790,8 @@
//
BeforeClick: function (treeId, treeNode) {
console.log("展开---")
this.treeNodeClick = treeNode;
// removeHoverDom (treeId, treeNode);
//if (treeNode.level != 19990 ) {
// var zTree = $.fn.zTree.getZTreeObj("treeDemo");
// zTree.expandNode(treeNode);

View File

@ -3,11 +3,12 @@
<div class="aside-titleB" @click="tagListShowCk" @mouseenter="eidtTAGText=!eidtTAGText" @mouseleave="eidtTAGText=!eidtTAGText">
<i :class="tagListShow ? 'el-icon-caret-bottom aside-titleB_childi_one':'el-icon-caret-right aside-titleB_childi_one'" ></i>
<i class="el-icon-price-tag aside-titleB_childi_two"></i>
<span >标签管理</span>
<div style="margin-left: 40%" v-show="eidtTAGText">
<span style="width: 100%">标签管理</span>
<span style="min-width: 70px" v-show="eidtTAGText">
<i class="el-icon-search title-name" @click.stop="searchBkTagCk"></i>
<i class="el-icon-folder-add title-name" @click.stop="addBkTagCk"></i>
</div>
</span>
<span class="menuCount" v-show="!eidtTAGText">{{total}}</span>
</div>
@ -59,7 +60,7 @@
<!-- <el-tag type="info" size="mini">{{item.name}}</el-tag>-->
</div>
</div>
<div v-if=" tagList != undefined && tagList != null && total > 8 " class="aside-title name transition-box" @click="getListTag()">加载更多({{total}})</div>
<div v-if=" tagList != undefined && tagList != null && total > 8 " class="aside-title name transition-box" @click="getListTag()">加载更多</div>
<!-- 无标签 -->
<div v-if=" tagList == undefined ||tagList == null || tagList.length <= 0" class="aside-title name transition-box" >
@ -403,6 +404,10 @@
width: 100%;
margin-top: 10px;
}
.menuCount{
margin-right: 18px;
color: #9e9e9e;
}