修复没有数据,前台报异常

This commit is contained in:
ascrutae 2016-04-21 18:28:14 +08:00
parent 0fb9222c9c
commit 6229fd3516
2 changed files with 7 additions and 0 deletions

View File

@ -1,4 +1,5 @@
function changeData(data) {
var result = {
traceTree: {
traceId: "",
@ -9,6 +10,11 @@ function changeData(data) {
treeNodes: []
}
};
if (data.nodes == undefined || data.nodes.length == 0){
return result;
}
result.traceTree.traceId = data.traceId;
result.traceTree.totalTime = data.endTime - data.beginTime;
var totalTime = result.traceTree.totalTime;

View File

@ -63,6 +63,7 @@
if (loadType == "showTraceInfo"){
loadTraceTreeData("${_base}");
return;
}
if (loadType == "showAnlyResult"){