feature: display interfaces with VLAN id on Interfaces page
Currently we do not display interfaces with VLAN id assigned on Interfaces page.
So for example: !328 (merged) introduced way to set VLAN id for wan interface in reForis, but the wan interface with VLAN id is not displayed on Interfaces page.
Proposed idea
It could look like this.
In this case max-width: 100px
for .interface
class seems to give quite nice looking result - interface label on first line, VLAN id on second line - but feel free to adjust the CSS for the best result :)
Backend will provide additional info regarding the vlan_id
, if it is available.
{
"networks": {
[...]
"wan": [
{
"type": "eth",
"bus": "eth",
"state": "up",
"slot": "WAN",
"module_id": 0,
"macaddr": "11:22:33:44:55:66",
"link_speed": 1000,
"vlan_id": 100, <-- optional VLAN id here
"id": "eth2.100",
"configurable": true
}
]
}
This is just an example of wan interface, vlan_id
could be provided to other interfaces as well.
So I propose that interface label (displayed name) could be created:
- Just from
slot
if there is novlan_id
- Combination of
slot
andvlan_id
, e.g. "WAN (VLAN 100)"
We could also use bootstrap badges to put visual emphasis on the VLAN id number.
Depends on: turris/turrishw#5 (closed), turris/foris-controller/foris-controller#105 (closed)