네트워크 품질 표 행열 구조 수정
This commit is contained in:
+12
-6
@@ -2615,8 +2615,8 @@
|
||||
const dropKey = direction === 'rx' ? 'rx_dropped_total' : 'tx_dropped_total';
|
||||
const speedKey = direction === 'rx' ? 'rx_mbytes' : 'tx_mbytes';
|
||||
const packetKey = direction === 'rx' ? 'rx_pps' : 'tx_pps';
|
||||
const qualityTitle = direction === 'rx' ? t('rxErrorsDrops') : t('txErrorsDrops');
|
||||
const currentTitle = direction === 'rx' ? t('downloadRxPackets') : t('uploadTxPackets');
|
||||
const speedTitle = direction === 'rx' ? t('downloadLine') : t('uploadLine');
|
||||
const packetTitle = direction === 'rx' ? t('rxPacketsLine') : t('txPacketsLine');
|
||||
const totalRow = totals || {};
|
||||
const currentRow = rows.length ? rows[rows.length - 1] : {};
|
||||
const recent = recentNetworkQuality(rows, direction);
|
||||
@@ -2627,14 +2627,20 @@
|
||||
<table class="quality-table">
|
||||
<tbody>
|
||||
<tr>
|
||||
<th scope="row">${escapeHtml(currentTitle)}</th>
|
||||
<th scope="col">${escapeHtml(speedTitle)}</th>
|
||||
<th scope="col">${escapeHtml(packetTitle)}</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="quality-value"><strong>${escapeHtml(formatChartNumber(currentRow[speedKey], ' MB/s'))}</strong></td>
|
||||
<td class="quality-value"><strong>${escapeHtml(formatChartNumber(currentRow[packetKey], ' pps'))}</strong></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">${escapeHtml(qualityTitle)}</th>
|
||||
<td class="quality-value"><strong>${escapeHtml(formatCount(totalRow[errorKey]))}</strong> ${escapeHtml(t('errorsLine'))}</td>
|
||||
<td class="quality-value"><strong>${escapeHtml(formatCount(totalRow[dropKey]))}</strong> ${escapeHtml(t('dropsLine'))} <span class="quality-badge ${escapeHtml(recent.state)}">${escapeHtml(recent.label)}</span></td>
|
||||
<th scope="col">${escapeHtml(t('errorsLine'))}</th>
|
||||
<th scope="col">${escapeHtml(t('dropsLine'))}</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="quality-value"><strong>${escapeHtml(formatCount(totalRow[errorKey]))}</strong></td>
|
||||
<td class="quality-value"><strong>${escapeHtml(formatCount(totalRow[dropKey]))}</strong> <span class="quality-badge ${escapeHtml(recent.state)}">${escapeHtml(recent.label)}</span></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
Reference in New Issue
Block a user