Steps to reproduce:
- Create user role via API so only one element will be enabled e.g.
{ "jsonrpc": "2.0", "method": "role.create", "params": { "name": "{name}", "type": "1", "rules": { "ui": [ { "name": "monitoring.dashboard", "status": "0" }, { "name": "monitoring.problems", "status": "1" }, { "name": "monitoring.hosts", "status": "0" }, { "name": "monitoring.latest_data", "status": "0" }, { "name": "monitoring.maps", "status": "0" }, { "name": "services.services", "status": "0" }, { "name": "services.sla_report", "status": "0" }, { "name": "inventory.overview", "status": "0" }, { "name": "inventory.hosts", "status": "0" }, { "name": "reports.availability_report", "status": "0" }, { "name": "reports.top_triggers", "status": "0" } ] } }, "auth": "{{token}}", "id": 1 }
- Update user role via API so all UI elements will be disabled e.g.
"jsonrpc": "2.0", "method": "role.update", "params": { "roleid": "{role_id}", "rules": { "ui": [ { "name": "monitoring.problems", "status": "0" } ] } }, "auth": "{{token}}", "id": 1 }
- Check user role via FE
Result: All UI elements for the role are disabled.
Expected: Validation error should appear "At least one UI element must be enabled for user role {role_name}"