add windows drive status (#5663)

Signed-off-by: si458 <simonsmith5521@gmail.com>

Simon Smith committed Jan 4, 2024 at 02:18 UTC c48447d3e6d256aed900654cf08e6fa167aed81c
2 files changed +8
views/default-mobile.handlebars
+4
@@ -6137,6 +6137,10 @@
6137 if (typeof m.Size == 'number') { x += addDetailItem("Capacity", format("{0} Mb", Math.floor(m.Size / 1024 / 1024)), s); }
6138 if (typeof m.Size == 'string') { x += addDetailItem("Capacity", EscapeHtml(m.Size), s); }
6139 }
6140 + if(hardware.windows && hardware.windows.drives && m.Model){
6141 + const foundObject = hardware.windows.drives.find(obj => obj['Model'] === m.Model);
6142 + if(foundObject) x += addDetailItem("Status", EscapeHtml(foundObject.Status), s);
6143 + }
6144 x += '</div>';
6145 }
6146 }
views/default.handlebars
+4
@@ -11950,6 +11950,10 @@
11950 if (typeof m.Size == 'number') { x += addDetailItem("Capacity", format("{0} Mb", Math.floor(m.Size / 1024 / 1024)), s); }
11951 if (typeof m.Size == 'string') { x += addDetailItem("Capacity", EscapeHtml(m.Size), s); }
11952 }
11953 + if(hardware.windows && hardware.windows.drives && m.Model){
11954 + const foundObject = hardware.windows.drives.find(obj => obj['Model'] === m.Model);
11955 + if(foundObject) x += addDetailItem("Status", EscapeHtml(foundObject.Status), s);
11956 + }
11957 x += '</div>';
11958 }
11959 }