[PR #20386] [MERGED] Closes #17010: Show admin navigation menu items only for staff & superusers #15912

Closed
opened 2025-12-30 00:24:45 +01:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/netbox-community/netbox/pull/20386
Author: @jeremystretch
Created: 9/18/2025
Status: Merged
Merged: 9/19/2025
Merged by: @arthanson

Base: mainHead: 17010-admin-menu-items


📝 Commits (1)

  • 63dfcd5 Closes #17010: Show admin navigation menu items only for staff & superusers

📊 Changes

2 files changed (+10 additions, -10 deletions)

View changed files

📝 netbox/netbox/navigation/menu.py (+9 -9)
📝 netbox/utilities/templatetags/navigation.py (+1 -1)

📄 Description

Closes: #17010

  • Set staff_only=True on all MenuItems under the Admin section
  • Tweak the the logic of the nav() template tag so that users with is_staff or is_superuser satisfied the staff_only condition

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/netbox-community/netbox/pull/20386 **Author:** [@jeremystretch](https://github.com/jeremystretch) **Created:** 9/18/2025 **Status:** ✅ Merged **Merged:** 9/19/2025 **Merged by:** [@arthanson](https://github.com/arthanson) **Base:** `main` ← **Head:** `17010-admin-menu-items` --- ### 📝 Commits (1) - [`63dfcd5`](https://github.com/netbox-community/netbox/commit/63dfcd5c468f43b0fb3aa6987ee142f9523ad6b3) Closes #17010: Show admin navigation menu items only for staff & superusers ### 📊 Changes **2 files changed** (+10 additions, -10 deletions) <details> <summary>View changed files</summary> 📝 `netbox/netbox/navigation/menu.py` (+9 -9) 📝 `netbox/utilities/templatetags/navigation.py` (+1 -1) </details> ### 📄 Description ### Closes: #17010 - Set `staff_only=True` on all MenuItems under the Admin section - Tweak the the logic of the `nav()` template tag so that users with `is_staff` or `is_superuser` satisfied the `staff_only` condition --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
adam added the pull-request label 2025-12-30 00:24:45 +01:00
adam closed this issue 2025-12-30 00:24:45 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#15912