diff --git a/nezha-fronted/src/components/common/project/L5/CanvasProps.vue b/nezha-fronted/src/components/common/project/L5/CanvasProps.vue index c01e61f65..0030f3f50 100644 --- a/nezha-fronted/src/components/common/project/L5/CanvasProps.vue +++ b/nezha-fronted/src/components/common/project/L5/CanvasProps.vue @@ -187,6 +187,7 @@ @active-change="(val)=>colorChangeTable(item,val)" popper-class="no-style-class" v-model="item.showColor" + :predefine="predefineColors" > @@ -1168,6 +1169,7 @@ name:this.$t("project.topology.fade") } ], + predefineColors:['#FF0000','#FF5300','#FFC900','#00B536','#00CAFF','#0092FF','#B600D9','#FF666C','#FF9348','#FFDD33','#00D063','#00deff','#62B9FF','#D55BE9'] } }, mixins:[rz], diff --git a/nezha-fronted/src/components/common/project/topologyL5.vue b/nezha-fronted/src/components/common/project/topologyL5.vue index 5c7962cb5..bf1921fb8 100644 --- a/nezha-fronted/src/components/common/project/topologyL5.vue +++ b/nezha-fronted/src/components/common/project/topologyL5.vue @@ -1166,7 +1166,7 @@ }, onMessage(event,data,e){ - console.log('onMessage',event); + // console.log('onMessage',event); // console.log(getTopology(this.topologyIndex)) if(!Array.isArray(data)&&data){//判断不是数组 提前个data配置好节点属性 // if(data.type===0){ @@ -1269,7 +1269,6 @@ this.tooltipPosition.top=ePosition.layerY; this.$nextTick(()=>{ if(this.$refs['topoTooltip']){ - // console.log(boxWidth,ePosition.layerX,this.$refs['topoTooltip'].offsetWidth,boxHeight,ePosition.layerY,); if((boxWidth/2)>ePosition.layerX){ this.tooltipPosition.left=ePosition.layerX+20; }else { @@ -1321,9 +1320,6 @@ // }; // } // },50); - - console.log(getTopology(this.topologyIndex).caches); - switch(event){ case 'node': case 'addNode': @@ -1734,7 +1730,6 @@ index:0, list:[JSON.parse(JSON.stringify(getTopology(this.topologyIndex).data))] } - console.log(getTopology(this.topologyIndex)); }) }, @@ -1863,12 +1858,13 @@ /*tools 方法*/ winResize(){ - let domRect=document.getElementById('topology-canvas'+this.topologyIndexF).getBoundingClientRect(); - this.toolShow.attrCord=[domRect.width-350,0]; - this.toolShow.height=domRect.height; + let domRect=document.getElementById('topology-canvas'+this.topologyIndex).getBoundingClientRect(); + // this.toolShow.attrCord=[domRect.width-350,0]; + // this.toolShow.height=domRect.height; getTopology(this.topologyIndex).canvasPos=domRect; getTopology(this.topologyIndex).centerView(); this.getNodesArr(); + console.log(213213123123); }, canvasMove(e){// 画布上的移动 确定tooltip的位置 if(this.tooltipPosition.show){ @@ -1923,7 +1919,6 @@ return false; }, redoIndexChange(index){ - console.log(index); this.redoIndex=index } },