Skip to content

Commit

Permalink
Add setup url config
Browse files Browse the repository at this point in the history
  • Loading branch information
gnarula committed Feb 16, 2015
1 parent 13b930b commit d8547fc
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
9 changes: 9 additions & 0 deletions modules/s3cfg.py
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,7 @@ def __init__(self):
self.supply = Storage()
self.search = Storage()
self.security = Storage()
self.setup = Storage()
self.sync = Storage()
self.ui = Storage()
self.vulnerability = Storage()
Expand Down Expand Up @@ -1970,6 +1971,14 @@ def get_search_filter_manager_load(self):
""" Text for saved filter load-button """
return self.search.get("filter_manager_load", None)

# =========================================================================
# Setup
#
def get_url(self):
""" URL for Setup Coapp """

return self.setup.get("url", None)

# =========================================================================
# Sync
#
Expand Down
2 changes: 2 additions & 0 deletions modules/s3menus.py
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,8 @@ def menu_admin(cls, **attr):
check=translate),
MM("Test Results", f="result"),
)
if settings.setup.url:
menu_admin.append(MM("Setup Coapp", url=settings.setup.url))
elif s3_has_role("ORG_ADMIN"):
menu_admin = MM(name_nice, c="admin", f="user", **attr)()
else:
Expand Down

0 comments on commit d8547fc

Please sign in to comment.