mirror of
https://github.com/BobbyWibowo/lolisafe.git
synced 2025-01-07 12:21:33 +00:00
Updated dashboard.js
Oversight.
This commit is contained in:
parent
13081ef38a
commit
9b1cb06825
@ -1989,17 +1989,17 @@ page.getServerStats = function (element) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
let content = ''
|
let content = ''
|
||||||
|
|
||||||
for (const key of Object.keys(response.data.stats)) {
|
for (const key of Object.keys(response.data.stats)) {
|
||||||
let rows = ''
|
let rows = ''
|
||||||
for (const valKey of Object.keys(response.data.stats[key])) {
|
for (const valKey of Object.keys(response.data.stats[key])) {
|
||||||
let value = response.data.stats[key][valKey]
|
const _value = response.data.stats[key][valKey]
|
||||||
if (['albums', 'users'].includes(key))
|
let value = _value
|
||||||
value = value.toLocaleString()
|
if (['albums', 'users', 'uploads'].includes(key))
|
||||||
|
value = _value.toLocaleString()
|
||||||
if (['memoryUsage', 'size'].includes(valKey))
|
if (['memoryUsage', 'size'].includes(valKey))
|
||||||
value = page.getPrettyBytes(value)
|
value = page.getPrettyBytes(_value)
|
||||||
if (valKey === 'systemMemory')
|
if (valKey === 'systemMemory')
|
||||||
value = `${page.getPrettyBytes(value.used)} / ${page.getPrettyBytes(value.total)} (${Math.round(value.used / value.total * 100)}%)`
|
value = `${page.getPrettyBytes(_value.used)} / ${page.getPrettyBytes(_value.total)} (${Math.round(_value.used / _value.total * 100)}%)`
|
||||||
rows += `
|
rows += `
|
||||||
<tr>
|
<tr>
|
||||||
<th>${valKey.replace(/([A-Z])/g, ' $1').toUpperCase()}</th>
|
<th>${valKey.replace(/([A-Z])/g, ' $1').toUpperCase()}</th>
|
||||||
|
@ -16,7 +16,7 @@
|
|||||||
v3: CSS and JS files (libs such as bulma, lazyload, etc).
|
v3: CSS and JS files (libs such as bulma, lazyload, etc).
|
||||||
v4: Renders in /public/render/* directories (to be used by render.js).
|
v4: Renders in /public/render/* directories (to be used by render.js).
|
||||||
#}
|
#}
|
||||||
{% set v1 = "MYXYdOtS8u" %}
|
{% set v1 = "ix1PYPhEvh" %}
|
||||||
{% set v2 = "hiboQUzAzp" %}
|
{% set v2 = "hiboQUzAzp" %}
|
||||||
{% set v3 = "hiboQUzAzp" %}
|
{% set v3 = "hiboQUzAzp" %}
|
||||||
{% set v4 = "dplQUZqTnf" %}
|
{% set v4 = "dplQUZqTnf" %}
|
||||||
|
Loading…
Reference in New Issue
Block a user