3
0

Fix page-layout all-sepecific permission translations

This commit is contained in:
Jože Fortun 2023-04-07 12:38:29 +02:00
parent 7c6c5950d5
commit d95fb02bf0
3 changed files with 21 additions and 6 deletions

View File

@ -78,11 +78,13 @@
<b-dropdown-item>
<c-permissions-button
v-if="page.canGrant"
:title="page.title || page.handle || page.pageID"
:target="page.title || page.handle || page.pageID"
:resource="`corteza::compose:page-layout/${namespace.namespaceID}/${page.pageID}/*`"
:button-label="$t('general:label.pageLayout')"
:show-button-icon="false"
all-specific
button-variant="white text-left w-100"
/>
</b-dropdown-item>
@ -368,7 +370,7 @@
<b-modal
v-if="layoutEditor.layout"
:visible="!!layoutEditor.layout"
:title="$t('page-layout.configure', { title: ((layoutEditor.layout || {}).meta || {}).title})"
:title="$t('page-layout.configure', { title: ((layoutEditor.layout || {}).meta || {}).title, interpolation: { escapeValue: false } })"
:ok-title="$t('general:label.saveAndClose')"
ok-variant="primary"
cancel-variant="link"

View File

@ -149,7 +149,7 @@ export default {
const { namespaceID } = this.namespace
this.page.weight = this.tree.length
this.createPage({ ...this.page, namespaceID }).then(({ pageID, title }) => {
const pageLayout = new compose.PageLayout({ namespaceID, pageID, meta: { title } })
const pageLayout = new compose.PageLayout({ namespaceID, pageID, handle: 'primary', meta: { title } })
return this.createPageLayout(pageLayout).then(() => {
this.$router.push({ name: 'admin.pages.edit', params: { pageID } })
})

View File

@ -164,24 +164,37 @@ resources:
description: 'Default: deny'
specific: Update page "{{target}}"
title: Update any page
page-layout:
create:
description: 'Default: deny'
specific: Create page layouts for page "{{target}}"
title: Create page layout
search:
description: 'Default: deny'
specific: List page layouts for page "{{target}}"
title: List page layout
page-layout:
all: all page layouts
specific: page layout "{{target}}"
tooltip: Page layout permissions
all-specific: all page layouts of page "{{ target }}"
operations:
delete:
description: 'Default: deny'
specific: Delete page layout "{{target}}"
title: Delete any page layout
read:
description: 'Default: deny'
specific: Read page layout "{{target}}"
title: Read any page layout
all-specific: Read page layouts of page "{{ target }}"
update:
description: 'Default: deny'
specific: Update page layout "{{target}}"
title: Update any page layout
all-specific: Update page layouts of page "{{ target }}"
delete:
description: 'Default: deny'
specific: Delete page layout "{{target}}"
title: Delete any page layout
all-specific: Delete page layouts of page "{{ target }}"
record:
all: all records