Added access check for write and manage actions
This commit is contained in:
@@ -41,14 +41,15 @@ block content
|
||||
a(href='/admin/stats')
|
||||
i.icon-bar-graph-2
|
||||
span Stats
|
||||
li
|
||||
a(href='/admin/users')
|
||||
i.icon-users
|
||||
span Users
|
||||
li
|
||||
a(href='/admin/settings')
|
||||
i.icon-cog
|
||||
span Site Settings
|
||||
if rights.manage
|
||||
li
|
||||
a(href='/admin/users')
|
||||
i.icon-users
|
||||
span Users
|
||||
li
|
||||
a(href='/admin/settings')
|
||||
i.icon-cog
|
||||
span Site Settings
|
||||
li
|
||||
a(href='/logout')
|
||||
i.icon-delete2
|
||||
|
||||
@@ -6,18 +6,20 @@ block rootNavCenter
|
||||
block rootNavRight
|
||||
i.nav-item#notifload
|
||||
span.nav-item
|
||||
a.button.is-outlined.btn-move-prompt.is-hidden
|
||||
i.icon-shuffle
|
||||
span Move
|
||||
if rights.write
|
||||
a.button.is-outlined.btn-move-prompt.is-hidden
|
||||
i.icon-shuffle
|
||||
span Move
|
||||
a.button.is-outlined(href='/' + pageData.meta.path)
|
||||
i.icon-loader
|
||||
span Normal View
|
||||
a.button.is-orange(href='/edit/' + pageData.meta.path)
|
||||
i.fa.fa-edit
|
||||
span Edit
|
||||
a.button.is-blue.btn-create-prompt
|
||||
i.fa.fa-plus
|
||||
span Create
|
||||
if rights.write
|
||||
a.button.is-orange(href='/edit/' + pageData.meta.path)
|
||||
i.fa.fa-edit
|
||||
span Edit
|
||||
a.button.is-blue.btn-create-prompt
|
||||
i.fa.fa-plus
|
||||
span Create
|
||||
|
||||
block content
|
||||
|
||||
|
||||
@@ -11,18 +11,20 @@ mixin tocMenu(ti)
|
||||
block rootNavRight
|
||||
i.nav-item#notifload
|
||||
.nav-item
|
||||
a.button.is-outlined.btn-move-prompt.is-hidden
|
||||
i.icon-shuffle
|
||||
span Move
|
||||
if rights.write
|
||||
a.button.is-outlined.btn-move-prompt.is-hidden
|
||||
i.icon-shuffle
|
||||
span Move
|
||||
a.button.is-outlined(href='/source/' + pageData.meta.path)
|
||||
i.icon-loader
|
||||
span Source
|
||||
a.button(href='/edit/' + pageData.meta.path)
|
||||
i.icon-document-text
|
||||
span Edit
|
||||
a.button.btn-create-prompt
|
||||
i.icon-plus
|
||||
span Create
|
||||
if rights.write
|
||||
a.button(href='/edit/' + pageData.meta.path)
|
||||
i.icon-document-text
|
||||
span Edit
|
||||
a.button.btn-create-prompt
|
||||
i.icon-plus
|
||||
span Create
|
||||
|
||||
block content
|
||||
|
||||
@@ -46,10 +48,11 @@ block content
|
||||
a(href='/' + pageData.parent.path)
|
||||
i.icon-reply
|
||||
span= pageData.parent.title
|
||||
li
|
||||
a(href='/admin')
|
||||
i.icon-head
|
||||
span Account
|
||||
if !isGuest
|
||||
li
|
||||
a(href='/admin')
|
||||
i.icon-head
|
||||
span Account
|
||||
aside.stickyscroll(data-margin-top=40)
|
||||
.sidebar-label
|
||||
i.icon-th-list
|
||||
|
||||
Reference in New Issue
Block a user