Commit 5358d690 authored by wangqinghua's avatar wangqinghua

告警闪烁

parent 5f3570b5
......@@ -29,7 +29,6 @@ TopologyPanel.prototype.saveTopology = function (url) {
}
// 获取json
var topologyJSON = editor.stage.toJson();
console.log(topologyJSON);
return topologyJSON;
// 保存拓扑图数据
}
......@@ -100,10 +99,8 @@ TopologyPanel.prototype.loadTopologyByJson = function (topologyJson, backImg) {
}
console.log(editor.utils.getAllNodes());
}
} catch (e) {
console.error(e)
var initTopologyJson = {
'version': '0.4.8',
'wheelZoom': 0.95,
......@@ -605,14 +602,14 @@ TopologyEditor.prototype.init = function (topologyGuid, backImg, topologyJson) {
// 只读模式下单击节点
if (event.target instanceof JTopo.Node && editor.stageMode === 'normal') {
console.log(self.currentNode)
} else if (event.target instanceof JTopo.Node && editor.stageMode === 'edit') {
console.log(self.currentNode)
} else if (event.target instanceof JTopo.Link && editor.stageMode === 'normal') {
console.log(self.currentNode)
} else if (event.target instanceof JTopo.Link && editor.stageMode === 'edit') {
console.log(self.currentNode)
} else {
// 单击别的地方
$('.node-tooltip').css('display', 'none')
......@@ -621,7 +618,6 @@ TopologyEditor.prototype.init = function (topologyGuid, backImg, topologyJson) {
// 双击编辑事件
this.scene.dbclick(function (event) {
console.log("双击");
if (!event.target) {
// 单击舞台空白处
$('.node-tooltip').css('display', 'none')
......@@ -857,9 +853,7 @@ TopologyEditor.prototype.init = function (topologyGuid, backImg, topologyJson) {
// 按下ctrl进入多选模式,此时选择节点不能画线
$(document).keydown(function (e) {
console.log('键盘事件')
if (e.shiftKey) { // 组合键模式
console.log('in')
switch (e.which) {
// 放大 shift+=
case 187:
......@@ -982,7 +976,7 @@ TopologyEditor.prototype.drag = function (modeDiv, drawArea, text) {
// IE只允许KEY为text和URL
event.dataTransfer.setData('text', backImg + ';' + text + ';' + nodeType)
} catch (ex) {
console.log(ex)
}
}
//
......@@ -1070,7 +1064,6 @@ editor.utils = {
node.hostId = hostId;
editor.scene.add(node)
editor.currentNode = node;
console.log(node);
},
// 重新渲染节点
reloadNode: function (node) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment