add windows drive status (#5663)

Signed-off-by: si458 <simonsmith5521@gmail.com>
This commit is contained in:
Simon Smith
2024-01-04 02:18:14 +00:00
committed by GitHub
parent e4001e67ef
commit c48447d3e6
2 changed files with 8 additions and 0 deletions

View File

@@ -6137,6 +6137,10 @@
if (typeof m.Size == 'number') { x += addDetailItem("Capacity", format("{0} Mb", Math.floor(m.Size / 1024 / 1024)), s); }
if (typeof m.Size == 'string') { x += addDetailItem("Capacity", EscapeHtml(m.Size), s); }
}
if(hardware.windows && hardware.windows.drives && m.Model){
const foundObject = hardware.windows.drives.find(obj => obj['Model'] === m.Model);
if(foundObject) x += addDetailItem("Status", EscapeHtml(foundObject.Status), s);
}
x += '</div>';
}
}

View File

@@ -11950,6 +11950,10 @@
if (typeof m.Size == 'number') { x += addDetailItem("Capacity", format("{0} Mb", Math.floor(m.Size / 1024 / 1024)), s); }
if (typeof m.Size == 'string') { x += addDetailItem("Capacity", EscapeHtml(m.Size), s); }
}
if(hardware.windows && hardware.windows.drives && m.Model){
const foundObject = hardware.windows.drives.find(obj => obj['Model'] === m.Model);
if(foundObject) x += addDetailItem("Status", EscapeHtml(foundObject.Status), s);
}
x += '</div>';
}
}