Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-21429

All UI elements can be disabled via API role.update request

XMLWordPrintable

    • Documentation backlog, S24-W22/23, S24-W24/25
    • 0.25

      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}"

            jfreibergs Janis Freibergs
            kseve Kirils Seve
            Team C
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: