Development
This commit is contained in:
parent
bb07e67d53
commit
69b5f00d5b
8 changed files with 165 additions and 26 deletions
|
|
@ -78,7 +78,17 @@ def collect_tokens(cfg):
|
|||
captive_vlans = [v for v in cfg.get('vlans', []) if v.get('restricted_vlan') == 'c']
|
||||
tokens['CAPTIVE_VLAN_OPTIONS'] = json.dumps(
|
||||
[{'value': '', 'label': '-- Select VLAN --'}] +
|
||||
[{'value': v['name'], 'label': f"{v['name']} (VLAN {v['vlan_id']})"} for v in captive_vlans]
|
||||
[
|
||||
{
|
||||
'value': v['name'],
|
||||
'label': f"{v['name']} (VLAN {v['vlan_id']})",
|
||||
'require_upw': v.get('captive_portal', {}).get('require_username_password',
|
||||
v.get('require_username_password', False)),
|
||||
'default_duration_seconds': v.get('captive_portal', {}).get('default_duration_seconds',
|
||||
v.get('default_duration_seconds', 0)),
|
||||
}
|
||||
for v in captive_vlans
|
||||
]
|
||||
)
|
||||
|
||||
raw_rows = _load_credentials()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue