fix: 清理_hires残留 + HiChart替换确认
This commit is contained in:
@@ -322,16 +322,10 @@
|
||||
grid.appendChild(card);
|
||||
_cardCache[id] = card;
|
||||
if (isRow && !_chartInstances[id]) {
|
||||
try {
|
||||
_chartInstances[id] = { cpu: null, mem: null, net: null };
|
||||
if (typeof MiniChart !== 'undefined') {
|
||||
_chartInstances[id].cpu = new MiniChart(id+'-cpu', '#7aa2f7'); _chartInstances[id].mem = new MiniChart(id+'-mem', '#9ece6a'); _hires(_chartInstances[id].mem);
|
||||
}
|
||||
if (typeof DualLineChart !== 'undefined') {
|
||||
_chartInstances[id].net = new DualLineChart(id+'-net', '#bb9af7', '#c0a8f0');
|
||||
|
||||
}
|
||||
} catch(e) {}
|
||||
_chartInstances[id] = { cpu: null, mem: null, net: null };
|
||||
_chartInstances[id].cpu = new HiChart(id+'-cpu', '#7aa2f7');
|
||||
_chartInstances[id].mem = new HiChart(id+'-mem', '#9ece6a');
|
||||
_chartInstances[id].net = new HiChart(id+'-net', '#bb9af7', '#c0a8f0');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user