add sections for enabled and disabled interfaces

This commit is contained in:
liamcottle 2024-08-07 22:35:37 +12:00
parent 46f28920f5
commit de3fa070fd
3 changed files with 225 additions and 157 deletions

View file

@ -131,6 +131,12 @@ class Utils {
}).join(''));
}
static isInterfaceEnabled(iface) {
const rawValue = iface.enabled ?? iface.interface_enabled;
const value = rawValue?.toLowerCase();
return value === "on" || value === "yes" || value === "true";
}
}
export default Utils;