Skip to content

Commit

Permalink
Add auth_required attrib on PluginMenuItem
Browse files Browse the repository at this point in the history
  • Loading branch information
bctiemann committed Jan 29, 2025
1 parent 5cd7c6d commit 1a0654a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion netbox/netbox/plugins/navigation.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,10 @@ class PluginMenuItem:
permissions = []
buttons = []

def __init__(self, link, link_text, staff_only=False, permissions=None, buttons=None):
def __init__(self, link, link_text, auth_required=False, staff_only=False, permissions=None, buttons=None):
self.link = link
self.link_text = link_text
self.auth_required = auth_required
self.staff_only = staff_only
if permissions is not None:
if type(permissions) not in (list, tuple):
Expand Down

0 comments on commit 1a0654a

Please sign in to comment.