mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-11-12 13:13:45 +01:00
[web] Hide privilege matrix tab in CE/SP (#34339)
The privilege matrix is only available in saas. GitOrigin-RevId: 72156e82d5039bc622e0119e07d2b4c5b9fdc10d
This commit is contained in:
@@ -16,8 +16,8 @@ block content
|
||||
+bookmarkable-tabset-header('system-messages', 'System Messages', true)
|
||||
+bookmarkable-tabset-header('open-sockets', 'Open Sockets')
|
||||
+bookmarkable-tabset-header('open-close-editor', 'Open/Close Editor')
|
||||
+bookmarkable-tabset-header('privileges-matrix', 'Privileges Matrix')
|
||||
if hasFeature('saas')
|
||||
+bookmarkable-tabset-header('privileges-matrix', 'Privileges Matrix')
|
||||
+bookmarkable-tabset-header('tpds', 'TPDS/Dropbox Management')
|
||||
+bookmarkable-tabset-header('debug-projects', 'Debug Projects')
|
||||
|
||||
@@ -73,42 +73,42 @@ block content
|
||||
button.btn.btn-danger(type='submit') Reopen Editor
|
||||
p.small Will reopen the editor after closing.
|
||||
|
||||
.tab-pane(role='tabpanel' id='privileges-matrix')
|
||||
p This matrix shows the access levels for different admin roles across various user management privileges. The matrix is automatically generated from the code-defined roles and capabilities.
|
||||
if hasFeature('saas') && privilegesMatrix
|
||||
.privileges-matrix-container
|
||||
table.table.table-bordered.table-striped.privileges-matrix-table
|
||||
thead
|
||||
tr
|
||||
th Webpage and privilege
|
||||
th(colspan=privilegesMatrix.roles.length) Access Level Needed For Team
|
||||
tr
|
||||
th
|
||||
each role in privilegesMatrix.roles
|
||||
th= role.displayName
|
||||
tbody
|
||||
- let currentSection = null
|
||||
each row in privilegesMatrix.privileges
|
||||
- const privilege = row.privilege
|
||||
if currentSection !== privilege.section
|
||||
- currentSection = privilege.section
|
||||
tr.section-header
|
||||
td(colspan=privilegesMatrix.roles.length + 1)
|
||||
strong= privilege.section
|
||||
tr
|
||||
td.privilege-label= privilege.label
|
||||
each role in privilegesMatrix.roles
|
||||
- const accessLevel = row.access[role.id]
|
||||
td.access-cell(class=`access-${accessLevel}`)
|
||||
span.access-badge(class=`badge-${accessLevel}`)
|
||||
if accessLevel === 'yes'
|
||||
| Yes
|
||||
else
|
||||
| No
|
||||
else
|
||||
p The privileges matrix is not available in this environment.
|
||||
|
||||
if hasFeature('saas')
|
||||
.tab-pane(role='tabpanel' id='privileges-matrix')
|
||||
p This matrix shows the access levels for different admin roles across various user management privileges. The matrix is automatically generated from the code-defined roles and capabilities.
|
||||
if privilegesMatrix
|
||||
.privileges-matrix-container
|
||||
table.table.table-bordered.table-striped.privileges-matrix-table
|
||||
thead
|
||||
tr
|
||||
th Webpage and privilege
|
||||
th(colspan=privilegesMatrix.roles.length) Access Level Needed For Team
|
||||
tr
|
||||
th
|
||||
each role in privilegesMatrix.roles
|
||||
th= role.displayName
|
||||
tbody
|
||||
- let currentSection = null
|
||||
each row in privilegesMatrix.privileges
|
||||
- const privilege = row.privilege
|
||||
if currentSection !== privilege.section
|
||||
- currentSection = privilege.section
|
||||
tr.section-header
|
||||
td(colspan=privilegesMatrix.roles.length + 1)
|
||||
strong= privilege.section
|
||||
tr
|
||||
td.privilege-label= privilege.label
|
||||
each role in privilegesMatrix.roles
|
||||
- const accessLevel = row.access[role.id]
|
||||
td.access-cell(class=`access-${accessLevel}`)
|
||||
span.access-badge(class=`badge-${accessLevel}`)
|
||||
if accessLevel === 'yes'
|
||||
| Yes
|
||||
else
|
||||
| No
|
||||
else
|
||||
p The privileges matrix is not available in this environment.
|
||||
|
||||
.tab-pane(role='tabpanel' id='tpds')
|
||||
h3 Flush project to TPDS
|
||||
.row
|
||||
|
||||
Reference in New Issue
Block a user