linuxrouter/docker/routlin-dash/app/pages/accountmanage/content.json
2026-06-12 11:16:31 -04:00

110 lines
2.7 KiB
JSON

{
"client_requirement": "client_is_manager+",
"items": [
{
"type": "header_page_title",
"items": [
{
"type": "h1",
"text": "Manage Accounts"
}
]
},
{
"type": "card",
"label": "Active Sessions",
"items": [
{
"type": "raw_html",
"html": "%ACTIVE_SESSIONS_TABLE%"
}
]
},
{
"type": "card",
"label": "User Accounts",
"items": [
{
"type": "raw_html",
"html": "%ACCOUNTS_TABLE%"
}
]
},
{
"type": "card",
"label": "Authorize New Account",
"items": [
{
"type": "form",
"action": "/action/accountmanage/accounts_add",
"method": "post",
"items": [
{
"type": "field",
"label": "Email Address",
"name": "email_address",
"input_type": "text",
"placeholder": "user@example.com",
"hint": "The user will verify ownership of this address during account setup."
},
{
"type": "field",
"label": "Access Level",
"name": "access_level",
"input_type": "select",
"options": "%ACCOUNT_LEVEL_OPTIONS%"
},
{
"type": "button_row",
"items": [
{
"type": "button_primary",
"action": "/action/accountmanage/accounts_add",
"method": "post",
"text": "Authorize"
}
]
}
]
}
]
},
{
"type": "card",
"id": "edit-form",
"label": "Edit Account",
"hidden": true,
"items": [
{
"type": "form",
"action": "/action/accountmanage/accounts_edit",
"method": "post",
"items": [
{"type": "hidden", "name": "row_index", "value": ""},
{
"type": "field",
"label": "Email Address",
"name": "email_address_display",
"input_type": "text",
"value": ""
},
{
"type": "field",
"label": "Access Level",
"name": "access_level",
"input_type": "select",
"options": "%ACCOUNT_LEVEL_OPTIONS%"
},
{
"type": "button_row",
"items": [
{"type": "button_primary", "text": "Save Changes"},
{"type": "button_cancel", "text": "Cancel"}
]
}
]
}
]
}
]
}