mirror of https://github.com/1Panel-dev/1Panel
fix: datas should be dataList (#7402)
parent
a4dcbc90e6
commit
6012a6cf9f
|
@ -149,11 +149,11 @@ function initChart() {
|
||||||
z: 1,
|
z: 1,
|
||||||
tooltip: props.option.tooltip || {
|
tooltip: props.option.tooltip || {
|
||||||
trigger: 'axis',
|
trigger: 'axis',
|
||||||
formatter: function (datas: any) {
|
formatter: function (dataList: any) {
|
||||||
let res = datas[0].name + '<br/>';
|
let res = dataList[0].name + '<br/>';
|
||||||
switch (props.option.formatStr) {
|
switch (props.option.formatStr) {
|
||||||
case 'KB/s':
|
case 'KB/s':
|
||||||
for (const item of datas) {
|
for (const item of dataList) {
|
||||||
res +=
|
res +=
|
||||||
item.marker +
|
item.marker +
|
||||||
' ' +
|
' ' +
|
||||||
|
@ -164,7 +164,7 @@ function initChart() {
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 'KB':
|
case 'KB':
|
||||||
for (const item of datas) {
|
for (const item of dataList) {
|
||||||
res +=
|
res +=
|
||||||
item.marker +
|
item.marker +
|
||||||
' ' +
|
' ' +
|
||||||
|
@ -175,7 +175,7 @@ function initChart() {
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 'MB':
|
case 'MB':
|
||||||
for (const item of datas) {
|
for (const item of dataList) {
|
||||||
res +=
|
res +=
|
||||||
item.marker +
|
item.marker +
|
||||||
' ' +
|
' ' +
|
||||||
|
@ -186,7 +186,7 @@ function initChart() {
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
for (const item of datas) {
|
for (const item of dataList) {
|
||||||
res +=
|
res +=
|
||||||
item.marker +
|
item.marker +
|
||||||
' ' +
|
' ' +
|
||||||
|
|
Loading…
Reference in New Issue