0byt3m1n1
Path:
/
home
/
mgatv524
/
cms.mgaplay.com.br
/
views
/
[
Home
]
File: authed-topbar.twig
{# /** * Copyright (C) 2022 Xibo Signage Ltd * * Xibo - Digital Signage - http://www.xibo.org.uk * * This file is part of Xibo. * * Xibo is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License as published by * the Free Software Foundation, either version 3 of the License, or * any later version. * * Xibo is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Affero General Public License for more details. * * You should have received a copy of the GNU Affero General Public License * along with Xibo. If not, see <http://www.gnu.org/licenses/>. */ #} <ul class="nav navbar-nav"> <li class="nav-item"><a class="nav-link" href="{{ url_for("home") }}">{% trans "Dashboard" %}</a></li> {% set countViewable = currentUser.featureEnabledCount(["schedule.view", "daypart.view"]) %} {% set groupElementClass = (countViewable > 1) ? 'dropdown-item' : 'nav-link' %} {% if countViewable > 0 %} {% if countViewable > 1 %} <li class="nav-item dropdown"> <a href="#" class="nav-link dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">{% trans "Schedule" %} <span class="caret"></span></a> <div class="dropdown-menu"> {% else %} <li class="nav-item"> {% endif %} {% if currentUser.featureEnabled("schedule.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("schedule.view") }}">{% if countViewable > 1 %}{% trans "Schedule" %}{% else %}{% trans "Schedule" %}{% endif %}</a> {% endif %} {% if currentUser.featureEnabled("daypart.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("daypart.view") }}">{% trans "Dayparting" %}</a> {% endif %} {% if countViewable > 1 %} </div> {% endif %} </li> {% endif %} {% set countViewable = currentUser.featureEnabledCount(["campaign.view", "layout.view", "template.view", "resolution.view"]) %} {% set groupElementClass = (countViewable > 1) ? 'dropdown-item' : 'nav-link' %} {% if countViewable > 0 %} {% if countViewable > 1 %} <li class="nav-item dropdown"> <a href="#" class="nav-link dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">{% trans "Design" %} <span class="caret"></span></a> <div class="dropdown-menu"> {% else %} <li class="nav-item"> {% endif %} {% if currentUser.featureEnabled("campaign.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("campaign.view") }}">{% trans "Campaigns" %}</a> {% endif %} {% if currentUser.featureEnabled("layout.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("layout.view") }}">{% trans "Layouts" %}</a> {% endif %} {% if currentUser.featureEnabled("template.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("template.view") }}">{% trans "Templates" %}</a> {% endif %} {% if currentUser.featureEnabled("resolution.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("resolution.view") }}">{% trans "Resolutions" %}</a> {% endif %} {% if countViewable > 1 %} </div> {% endif %} </li> {% endif %} {% set countViewable = currentUser.featureEnabledCount(["library.view", "playlist.view", "dataset.view", "menuboard.view"]) %} {% set groupElementClass = (countViewable > 1) ? 'dropdown-item' : 'nav-link' %} {% if countViewable > 0 %} {% if countViewable > 1 %} <li class="nav-item dropdown"> <a href="#" class="nav-link dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">{% trans "Library" %} <span class="caret"></span></a> <div class="dropdown-menu"> {% else %} <li class="nav-item"> {% endif %} {% if currentUser.featureEnabled("playlist.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("playlist.view") }}">{% trans "Playlists" %}</a> {% endif %} {% if currentUser.featureEnabled("library.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("library.view") }}">{% trans "Media" %}</a> {% endif %} {% if currentUser.featureEnabled("dataset.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("dataset.view") }}">{% trans "DataSets" %}</a> {% endif %} {% if currentUser.featureEnabled("menuboard.view") and not hideMenuBoard %} <a class="{{ groupElementClass }}" href="{{ url_for("menuBoard.view") }}">{% trans "Menu Boards" %}</a> {% endif %} {% if countViewable > 1 %} </div> {% endif %} </li> {% endif %} {% set countViewable = currentUser.featureEnabledCount(["displays.view", "displaygroup.view", "displayprofile.view", "playersoftware.view", "command.view"]) %} {% set groupElementClass = (countViewable > 1) ? 'dropdown-item' : 'nav-link' %} {% if countViewable > 0 %} {% if countViewable > 1 %} <li class="nav-item dropdown"> <a href="#" class="nav-link dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">{% trans "Displays" %} <span class="caret"></span></a> <div class="dropdown-menu"> {% else %} <li class="nav-item"> {% endif %} {% if currentUser.featureEnabled("displays.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("display.view") }}">{% trans "Displays" %}</a> {% endif %} {% if currentUser.featureEnabled("displaygroup.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("displaygroup.view") }}">{% trans "Display Groups" %}</a> {% endif %} {% if currentUser.featureEnabled("displayprofile.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("displayprofile.view") }}">{% trans "Display Settings" %}</a> {% endif %} {% if currentUser.featureEnabled("playersoftware.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("playersoftware.view") }}">{% trans "Player Versions" %}</a> {% endif %} {% if currentUser.featureEnabled("command.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("command.view") }}">{% trans "Commands" %}</a> {% endif %} {% if countViewable > 1 %} </div> {% endif %} </li> {% endif %} {% if currentUser.featureEnabled("users.view") and (currentUser.isGroupAdmin() or currentUser.isSuperAdmin()) %} {% set userMenuViewable = true %} {% else %} {% set userMenuViewable = false %} {% endif %} {% set countViewable = currentUser.featureEnabledCount(["usergroup.view", "module.view", "transition.view", "task.view"]) %} {% set groupElementClass = (countViewable > 1 or (countViewable == 1 and userMenuViewable)) ? 'dropdown-item' : 'nav-link' %} {% if countViewable > 0 or userMenuViewable %} {% if countViewable > 1 or (countViewable == 1 and userMenuViewable) %} <li class="nav-item dropdown"> <a href="#" class="nav-link dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">{% trans "Administration" %} <span class="caret"></span></a> <div class="dropdown-menu"> {% else %} <li class="nav-item"> {% endif %} {% if userMenuViewable %} <a class="{{ groupElementClass }}" href="{{ url_for("user.view") }}">{% trans "Users" %}</a> {% endif %} {% if currentUser.featureEnabled("usergroup.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("group.view") }}">{% trans "User Groups" %}</a> {% endif %} {% if currentUser.isSuperAdmin() %} <a class="{{ groupElementClass }}" href="{{ url_for("admin.view") }}">{% trans "Settings" %}</a> {% endif %} {% if currentUser.isSuperAdmin() %} <a class="{{ groupElementClass }}" href="{{ url_for("application.view") }}">{% trans "Applications" %}</a> {% endif %} {% if currentUser.featureEnabled("module.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("module.view") }}">{% trans "Modules" %}</a> {% endif %} {% if currentUser.featureEnabled("transition.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("transition.view") }}">{% trans "Transitions" %}</a> {% endif %} {% if currentUser.featureEnabled("task.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("task.view") }}">{% trans "Tasks" %}</a> {% endif %} {% if currentUser.featureEnabled("tag.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("tag.view") }}">{% trans "Tags" %}</a> {% endif %} {% if currentUser.isSuperAdmin() %} <a class="{{ groupElementClass }}" href="{{ url_for("folders.view") }}">{% trans "Folders" %}</a> {% endif %} {% if countViewable > 1 or (countViewable == 1 and userMenuViewable) %} </div> {% endif %} </li> {% endif %} {% set countViewable = currentUser.featureEnabledCount(["report.view", "report.scheduling", "report.saving"]) %} {% set groupElementClass = (countViewable > 1) ? 'dropdown-item' : 'nav-link' %} {% if countViewable > 0 %} {% if countViewable > 1 %} <li class="nav-item dropdown"> <a href="#" class="nav-link dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">{% trans "Reporting" %} <span class="caret"></span></a> <div class="dropdown-menu"> {% else %} <li class="nav-item"> {% endif %} {% if currentUser.featureEnabled("report.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("report.view") }}">{% trans "All Reports" %}</a> {% endif %} {% if currentUser.featureEnabled("report.scheduling") %} <a class="{{ groupElementClass }}" href="{{ url_for("reportschedule.view") }}">{% trans "Report Schedules" %}</a> {% endif %} {% if currentUser.featureEnabled("report.saving") %} <a class="{{ groupElementClass }}" href="{{ url_for("savedreport.view") }}">{% trans "Saved Reports" %}</a> {% endif %} {% if countViewable > 1 %} </div> {% endif %} </li> {% endif %} {% set countViewable = currentUser.featureEnabledCount(["log.view", "sessions.view", "auditlog.view", "fault.view", "help.view"]) %} {% set groupElementClass = (countViewable > 1) ? 'dropdown-item' : 'nav-link' %} {% if countViewable > 0 %} {% if countViewable > 1 %} <li class="nav-item dropdown"> <a href="#" class="nav-link dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">{% trans "Advanced" %} <span class="caret"></span></a> <div class="dropdown-menu"> {% else %} <li class="nav-item"> {% endif %} {% if currentUser.featureEnabled("log.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("log.view") }}">{% trans "Log" %}</a> {% endif %} {% if currentUser.featureEnabled("sessions.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("sessions.view") }}">{% trans "Sessions" %}</a> {% endif %} {% if currentUser.featureEnabled("auditlog.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("auditlog.view") }}">{% trans "Audit Trail" %}</a> {% endif %} {% if currentUser.featureEnabled("fault.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("fault.view") }}">{% trans "Report Fault" %}</a> {% endif %} {% if currentUser.featureEnabled("help.view") %} <a class="{{ groupElementClass }}" href="{{ url_for("help.view") }}">{% trans "Help Links" %}</a> {% endif %} {% if countViewable > 1 %} </div> {% endif %} </li> {% endif %} </ul>