CN-714 feat: 字段调整

This commit is contained in:
chenjinsong
2022-09-23 15:47:18 +08:00
parent e84a77a34b
commit 326149484f
2 changed files with 3 additions and 3 deletions

View File

@@ -21,7 +21,7 @@ if (openMock) {
const egressLinkIds = ['257', '513', '769', '1025', '1281', '1537', '1793', '2049', '2305', '2817'] const egressLinkIds = ['257', '513', '769', '1025', '1281', '1537', '1793', '2049', '2305', '2817']
ingressLinkIds.forEach(ingress => { ingressLinkIds.forEach(ingress => {
egressLinkIds.forEach(egress => { egressLinkIds.forEach(egress => {
data.push({ egressLinkId: egress, ingressLinkId: ingress, egressUsage: 128000, ingressUsage: 12800, totalBitsRate: 985412, score: 6, tcpConnectionEstablishLatency: 50, httpResponseLatency: 50, sslResponseLatency: 50, packetsLoss: 0.2, packetRetrans: 0.1 }) data.push({ egressLinkId: egress, ingressLinkId: ingress, egressBytes: 128000, ingressBytes: 12800, totalBytes: 130800, establishLatencyMs: 50, httpResponseLatency: 50, sslConLatency: 50, tcpLostlenPercent: 0.2, pktRetransPercent: 0.1 })
}) })
}) })
return { return {

View File

@@ -78,10 +78,10 @@ export default {
if (data) { if (data) {
const existedEgressLink = data.egress.find(e => e.linkId === egressLink.linkId) const existedEgressLink = data.egress.find(e => e.linkId === egressLink.linkId)
if (!existedEgressLink) { if (!existedEgressLink) {
data.egress.push({ linkId: egressLink.linkId, totalBitsRate: d.totalBitsRate }) data.egress.push({ linkId: egressLink.linkId, totalBytes: d.totalBytes })
} }
} else { } else {
gridData.push({ linkId: ingressLink.linkId, egress: [{ linkId: egressLink.linkId, totalBitsRate: d.totalBitsRate }] }) gridData.push({ linkId: ingressLink.linkId, egress: [{ linkId: egressLink.linkId, totalBytes: d.totalBytes }] })
} }
} }
}) })