Fixed inconsistiency of canEdit usage in authoring steps

pull/10/head
Jens Pelzetter 2021-12-09 21:02:57 +01:00
parent 5bafec04a3
commit eef4210785
11 changed files with 430 additions and 439 deletions

View File

@ -133,6 +133,7 @@ public abstract class AbstractMvcAuthoringStep implements MvcAuthoringStep {
) )
); );
documentModel.setContentItem(document); documentModel.setContentItem(document);
documentModel.setCanEdit(getCanEdit());
documentPath = itemManager.getItemPath(document); documentPath = itemManager.getItemPath(document);
final Map<String, String> values = new HashMap<>(); final Map<String, String> values = new HashMap<>();

View File

@ -45,7 +45,6 @@ import javax.enterprise.context.RequestScoped;
import javax.inject.Inject; import javax.inject.Inject;
import javax.inject.Named; import javax.inject.Named;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import javax.ws.rs.Path;
import javax.ws.rs.core.UriBuilder; import javax.ws.rs.core.UriBuilder;
/** /**
@ -140,6 +139,11 @@ public class SelectedDocumentModel {
*/ */
private boolean excludeDefaultAuthoringSteps; private boolean excludeDefaultAuthoringSteps;
/**
* Can the current user edit the document.
*/
private boolean canEdit;
/** /**
* The workflow assigned to the current content item. * The workflow assigned to the current content item.
*/ */
@ -186,6 +190,14 @@ public class SelectedDocumentModel {
return excludeDefaultAuthoringSteps; return excludeDefaultAuthoringSteps;
} }
public boolean getCanEdit() {
return canEdit;
}
public void setCanEdit(final boolean canEdit) {
this.canEdit = canEdit;
}
public String getWorkflowName() { public String getWorkflowName() {
return workflowName; return workflowName;
} }

View File

@ -127,8 +127,6 @@ public class MvcArticlePropertiesStep extends AbstractMvcAuthoringStep {
articlePropertiesStepModel.setName(getDocument().getDisplayName()); articlePropertiesStepModel.setName(getDocument().getDisplayName());
articlePropertiesStepModel.setCanEdit(getCanEdit());
final Set<Locale> titleLocales = getDocument() final Set<Locale> titleLocales = getDocument()
.getTitle() .getTitle()
.getAvailableLocales(); .getAvailableLocales();

View File

@ -37,8 +37,6 @@ public class MvcArticlePropertiesStepModel {
private String name; private String name;
private boolean canEdit;
private Map<String, String> titleValues; private Map<String, String> titleValues;
private List<String> unusedTitleLocales; private List<String> unusedTitleLocales;
@ -55,14 +53,6 @@ public class MvcArticlePropertiesStepModel {
this.name = name; this.name = name;
} }
public boolean getCanEdit() {
return canEdit;
}
public void setCanEdit(final boolean canEdit) {
this.canEdit = canEdit;
}
public Map<String, String> getTitleValues() { public Map<String, String> getTitleValues() {
return Collections.unmodifiableMap(titleValues); return Collections.unmodifiableMap(titleValues);
} }

View File

@ -222,7 +222,7 @@
</c:otherwise> </c:otherwise>
</c:choose> </c:choose>
<div class="cms-editor-messages"></div> <div class="cms-editor-messages"></div>
<c:if test="#{cc.attrs.hasUnusedLocales}"> <c:if test="#{cc.attrs.hasUnusedLocales and cc.attrs.canEdit}">
<div class="mb-2"> <div class="mb-2">
<div class="text-right"> <div class="text-right">
<button <button

View File

@ -17,6 +17,7 @@
<div class="d-flex mb-3"> <div class="d-flex mb-3">
<span class="mr-2">#{CmsDefaultStepsMessageBundle['categorization.system.assigned.to']}</span> <span class="mr-2">#{CmsDefaultStepsMessageBundle['categorization.system.assigned.to']}</span>
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<button class="btn btn-primary" <button class="btn btn-primary"
data-target="#edit-categorization-#{tree.domainKey}" data-target="#edit-categorization-#{tree.domainKey}"
data-toggle="modal" data-toggle="modal"
@ -26,7 +27,9 @@
#{CmsDefaultStepsMessageBundle['categorization.system.assigned.edit']} #{CmsDefaultStepsMessageBundle['categorization.system.assigned.edit']}
</span> </span>
</button> </button>
</c:if>
</div> </div>
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<div aria-labelledby="edit-categorization-#{tree.domainKey}-title" <div aria-labelledby="edit-categorization-#{tree.domainKey}-title"
aria-hidden="true" aria-hidden="true"
class="modal fade" class="modal fade"
@ -74,6 +77,7 @@
</form> </form>
</div> </div>
</div> </div>
</c:if>
<c:choose> <c:choose>
<c:when test="#{tree.root.assigned or tree.root.subCategoryAssigned}"> <c:when test="#{tree.root.assigned or tree.root.subCategoryAssigned}">
@ -91,7 +95,6 @@
</c:otherwise> </c:otherwise>
</c:choose> </c:choose>
</c:forEach> </c:forEach>
</ui:define> </ui:define>

View File

@ -22,6 +22,7 @@
#{CmsDefaultStepsMessageBundle['media.sortmedia.errors.save']} #{CmsDefaultStepsMessageBundle['media.sortmedia.errors.save']}
</div> </div>
</template> </template>
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<div class="text-right"> <div class="text-right">
<button class="btn btn-primary" <button class="btn btn-primary"
data-toggle="modal" data-toggle="modal"
@ -87,7 +88,9 @@
</form> </form>
</div> </div>
</div> </div>
</c:if>
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<div> <div>
<button class="btn btn-secondary media-save-order-button" <button class="btn btn-secondary media-save-order-button"
disabled="disabled" disabled="disabled"
@ -104,6 +107,7 @@
<span>#{CmsDefaultStepsMessageBundle['media.medialists.order.save']}</span> <span>#{CmsDefaultStepsMessageBundle['media.medialists.order.save']}</span>
</button> </button>
</div> </div>
</c:if>
<div id="messages"></div> <div id="messages"></div>
<ul class="cms-media-lists mt-3 list-group" <ul class="cms-media-lists mt-3 list-group"
data-baseUrl="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@media-service/save-order"> data-baseUrl="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@media-service/save-order">
@ -114,28 +118,30 @@
<div class="d-flex justify-content-between"> <div class="d-flex justify-content-between">
<div>#{list.name}</div> <div>#{list.name}</div>
<div class="cms-medialist-buttons d-flex"> <div class="cms-medialist-buttons d-flex">
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<button class="btn btn-secondary cms-sort-handle mr-2" <button class="btn btn-secondary cms-sort-handle mr-2"
type="button"> type="button">
<bootstrap:svgIcon icon="arrows-move" /> <bootstrap:svgIcon icon="arrows-move" />
<span class="sr-only">#{CmsDefaultStepsMessageBundle['media.medialists.move.button']}"</span> <span class="sr-only">#{CmsDefaultStepsMessageBundle['media.medialists.move.button']}"</span>
</button> </button>
</c:if>
<button class="btn btn-secondary mx-2" <button class="btn btn-secondary mx-2"
data-toggle="modal" data-toggle="modal"
data-target="#media-list-#{list.name}-info" data-target="#media-list-#{list.uuid}-info"
type="button"> type="button">
<bootstrap:svgIcon icon="info-circle" /> <bootstrap:svgIcon icon="info-circle" />
<span class="sr-only">#{CmsDefaultStepsMessageBundle['media.medialists.info.button']}"</span> <span class="sr-only">#{CmsDefaultStepsMessageBundle['media.medialists.info.button']}"</span>
</button> </button>
<div aria-hidden="true" <div aria-hidden="true"
aria-labelledby="medialist-#{list.name}-info-title" aria-labelledby="medialist-#{list.uuid}-info-title"
class="modal fade" class="modal fade"
id="media-list-#{list.name}-info" id="media-list-#{list.uuid}-info"
tabindex="-1"> tabindex="-1">
<div class="modal-dialog"> <div class="modal-dialog">
<div class="modal-content"> <div class="modal-content">
<div class="modal-header"> <div class="modal-header">
<h3 class="modal-title" <h3 class="modal-title"
id="medialist-#{list.name}-info-title"> id="medialist-#{list.uuid}-info-title">
#{CmsDefaultStepsMessageBundle.getMessage('media.medialists.info.dialog.title', [list.name])} #{CmsDefaultStepsMessageBundle.getMessage('media.medialists.info.dialog.title', [list.name])}
</h3> </h3>
<button <button
@ -164,6 +170,7 @@
</div> </div>
</div> </div>
</div> </div>
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<a class="btn btn-primary mx-2" <a class="btn btn-primary mx-2"
href="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@media/medialists/#{list.name}/@details"> href="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@media/medialists/#{list.name}/@details">
<bootstrap:svgIcon icon="pen" /> <bootstrap:svgIcon icon="pen" />
@ -193,6 +200,7 @@
contentSection="#{CmsMediaStep.sectionName}" contentSection="#{CmsMediaStep.sectionName}"
formParamName="mediaIdentifier" formParamName="mediaIdentifier"
/> />
</c:if>
</div> </div>
</div> </div>
<ul class="cms-medias mt-3 list-group" <ul class="cms-medias mt-3 list-group"
@ -234,11 +242,13 @@
<span class="cms-media-label">#{media.title}</span> <span class="cms-media-label">#{media.title}</span>
</div> </div>
<div class="cms-media-buttons d-flex"> <div class="cms-media-buttons d-flex">
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<button class="btn btn-secondary cms-sort-handle mr-2" <button class="btn btn-secondary cms-sort-handle mr-2"
type="button"> type="button">
<bootstrap:svgIcon icon="arrows-move" /> <bootstrap:svgIcon icon="arrows-move" />
<span class="sr-only">#{CmsDefaultStepsMessageBundle['media.medialists.media.move.button']}"</span> <span class="sr-only">#{CmsDefaultStepsMessageBundle['media.medialists.media.move.button']}"</span>
</button> </button>
</c:if>
<button class="btn btn-secondary mx-2" <button class="btn btn-secondary mx-2"
data-toggle="modal" data-toggle="modal"
data-target="#media-#{media.uuid}-info-dialog" data-target="#media-#{media.uuid}-info-dialog"
@ -286,6 +296,7 @@
</div> </div>
</div> </div>
</div> </div>
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<libreccm:deleteDialog <libreccm:deleteDialog
actionTarget="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@media/medialists/#{list.name}/media/#{media.uuid}/@remove" actionTarget="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@media/medialists/#{list.name}/media/#{media.uuid}/@remove"
buttonLabelClass="sr-only" buttonLabelClass="sr-only"
@ -297,6 +308,7 @@
dialogTitle="#{CmsDefaultStepsMessageBundle['media.medialists.media.remove.title']}" dialogTitle="#{CmsDefaultStepsMessageBundle['media.medialists.media.remove.title']}"
message="#{CmsDefaultStepsMessageBundle.getMessage('media.medialists.media.remove.message', [list.name, media.title])}" message="#{CmsDefaultStepsMessageBundle.getMessage('media.medialists.media.remove.message', [list.name, media.title])}"
/> />
</c:if>
</div> </div>
</li> </li>
</c:forEach> </c:forEach>
@ -305,6 +317,7 @@
</c:forEach> </c:forEach>
</ul> </ul>
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<div> <div>
<button class="btn btn-secondary media-save-order-button" <button class="btn btn-secondary media-save-order-button"
disabled="disabled" disabled="disabled"
@ -321,6 +334,7 @@
<span>#{CmsDefaultStepsMessageBundle['media.medialists.order.save']}</span> <span>#{CmsDefaultStepsMessageBundle['media.medialists.order.save']}</span>
</button> </button>
</div> </div>
</c:if>
</ui:define> </ui:define>
</ui:composition> </ui:composition>

View File

@ -22,6 +22,7 @@
#{CmsDefaultStepsMessageBundle['relatedinfo.sortattachments.errors.save']} #{CmsDefaultStepsMessageBundle['relatedinfo.sortattachments.errors.save']}
</div> </div>
</template> </template>
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<div class="text-right"> <div class="text-right">
<button class="btn btn-primary" <button class="btn btn-primary"
data-toggle="modal" data-toggle="modal"
@ -87,7 +88,9 @@
</form> </form>
</div> </div>
</div> </div>
</c:if>
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<div> <div>
<button class="btn btn-secondary attachments-save-order-button" <button class="btn btn-secondary attachments-save-order-button"
disabled="disabled" disabled="disabled"
@ -104,6 +107,7 @@
<span>#{CmsDefaultStepsMessageBundle['relatedinfo.attachmentlists.order.save']}</span> <span>#{CmsDefaultStepsMessageBundle['relatedinfo.attachmentlists.order.save']}</span>
</button> </button>
</div> </div>
</c:if>
<div id="messages"></div> <div id="messages"></div>
<ul class="cms-attachment-lists mt-3 list-group" <ul class="cms-attachment-lists mt-3 list-group"
data-baseUrl="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@relatedinfo-service/save-order"> data-baseUrl="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@relatedinfo-service/save-order">
@ -114,28 +118,30 @@
<div class="d-flex justify-content-between"> <div class="d-flex justify-content-between">
<div>#{list.name}</div> <div>#{list.name}</div>
<div class="cms-attachmentlist-buttons d-flex"> <div class="cms-attachmentlist-buttons d-flex">
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<button class="btn btn-secondary cms-sort-handle mr-2" <button class="btn btn-secondary cms-sort-handle mr-2"
type="button"> type="button">
<bootstrap:svgIcon icon="arrows-move" /> <bootstrap:svgIcon icon="arrows-move" />
<span class="sr-only">#{CmsDefaultStepsMessageBundle['relatedinfo.attachmentlists.move.button']}"</span> <span class="sr-only">#{CmsDefaultStepsMessageBundle['relatedinfo.attachmentlists.move.button']}"</span>
</button> </button>
</c:if>
<button class="btn btn-secondary mx-2" <button class="btn btn-secondary mx-2"
data-toggle="modal" data-toggle="modal"
data-target="#attachment-list-#{list.name}-info" data-target="#attachment-list-#{list.uuid}-info"
type="button"> type="button">
<bootstrap:svgIcon icon="info-circle" /> <bootstrap:svgIcon icon="info-circle" />
<span class="sr-only">#{CmsDefaultStepsMessageBundle['relatedinfo.attachmentlists.info.button']}"</span> <span class="sr-only">#{CmsDefaultStepsMessageBundle['relatedinfo.attachmentlists.info.button']}"</span>
</button> </button>
<div aria-hidden="true" <div aria-hidden="true"
aria-labelledby="attachmentlist-#{list.name}-info-title" aria-labelledby="attachmentlist-#{list.uuid}-info-title"
class="modal fade" class="modal fade"
id="attachment-list-#{list.name}-info" id="attachment-list-#{list.uuid}-info"
tabindex="-1"> tabindex="-1">
<div class="modal-dialog"> <div class="modal-dialog">
<div class="modal-content"> <div class="modal-content">
<div class="modal-header"> <div class="modal-header">
<h3 class="modal-title" <h3 class="modal-title"
id="attachmentlist-#{list.name}-info-title"> id="attachmentlist-#{list.uuid}-info-title">
#{CmsDefaultStepsMessageBundle.getMessage('relatedinfo.attachmentlists.info.dialog.title', [list.name])} #{CmsDefaultStepsMessageBundle.getMessage('relatedinfo.attachmentlists.info.dialog.title', [list.name])}
</h3> </h3>
<button <button
@ -164,6 +170,7 @@
</div> </div>
</div> </div>
</div> </div>
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<a class="btn btn-primary mx-2" <a class="btn btn-primary mx-2"
href="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@relatedinfo/attachmentlists/#{list.name}/@details"> href="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@relatedinfo/attachmentlists/#{list.name}/@details">
<bootstrap:svgIcon icon="pen" /> <bootstrap:svgIcon icon="pen" />
@ -199,6 +206,7 @@
contentSection="#{CmsRelatedInfoStep.sectionName}" contentSection="#{CmsRelatedInfoStep.sectionName}"
formParamName="assetIdentifier" formParamName="assetIdentifier"
/> />
</c:if>
</div> </div>
</div> </div>
<ul class="cms-attachments mt-3 list-group" <ul class="cms-attachments mt-3 list-group"
@ -222,11 +230,13 @@
<span class="cms-attachment-label">#{attachment.title}</span> <span class="cms-attachment-label">#{attachment.title}</span>
</div> </div>
<div class="cms-attachment-buttons d-flex"> <div class="cms-attachment-buttons d-flex">
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<button class="btn btn-secondary cms-sort-handle mr-2" <button class="btn btn-secondary cms-sort-handle mr-2"
type="button"> type="button">
<bootstrap:svgIcon icon="arrows-move" /> <bootstrap:svgIcon icon="arrows-move" />
<span class="sr-only">#{CmsDefaultStepsMessageBundle['relatedinfo.attachments.move.button']}"</span> <span class="sr-only">#{CmsDefaultStepsMessageBundle['relatedinfo.attachments.move.button']}"</span>
</button> </button>
</c:if>
<button class="btn btn-secondary mx-2" <button class="btn btn-secondary mx-2"
data-toggle="modal" data-toggle="modal"
data-target="#attachment-#{attachment.uuid}-info-dialog" data-target="#attachment-#{attachment.uuid}-info-dialog"
@ -274,6 +284,7 @@
</div> </div>
</div> </div>
</div> </div>
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<c:if test="#{attachment.assetType.equals(CmsRelatedInfoStep.relatedLinkType)}"> <c:if test="#{attachment.assetType.equals(CmsRelatedInfoStep.relatedLinkType)}">
<a class="btn btn-primary mx-2" <a class="btn btn-primary mx-2"
href="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@relatedinfo/attachmentlists/#{list.name}/links/#{attachment.assetUuid}/@details" href="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@relatedinfo/attachmentlists/#{list.name}/links/#{attachment.assetUuid}/@details"
@ -293,6 +304,7 @@
dialogTitle="#{CmsDefaultStepsMessageBundle['relatedinfo.attachment.remove.title']}" dialogTitle="#{CmsDefaultStepsMessageBundle['relatedinfo.attachment.remove.title']}"
message="#{CmsDefaultStepsMessageBundle.getMessage('relatedinfo.attachment.remove.message', [list.name, attachment.title])}" message="#{CmsDefaultStepsMessageBundle.getMessage('relatedinfo.attachment.remove.message', [list.name, attachment.title])}"
/> />
</c:if>
</div> </div>
</li> </li>
</c:forEach> </c:forEach>
@ -301,6 +313,7 @@
</c:forEach> </c:forEach>
</ul> </ul>
<c:if test="#{CmsSelectedDocumentModel.canEdit}">
<div> <div>
<button class="btn btn-secondary attachments-save-order-button" <button class="btn btn-secondary attachments-save-order-button"
disabled="disabled" disabled="disabled"
@ -317,6 +330,7 @@
<span>#{CmsDefaultStepsMessageBundle['relatedinfo.attachmentlists.order.save']}</span> <span>#{CmsDefaultStepsMessageBundle['relatedinfo.attachmentlists.order.save']}</span>
</button> </button>
</div> </div>
</c:if>
</ui:define> </ui:define>

View File

@ -15,7 +15,7 @@
<h3>#{CmsArticleMessageBundle.getMessage('basicproperties.name.header')}</h3> <h3>#{CmsArticleMessageBundle.getMessage('basicproperties.name.header')}</h3>
<div class="d-flex"> <div class="d-flex">
<pre class="mr-2">#{CmsArticlePropertiesStep.name}</pre> <pre class="mr-2">#{CmsArticlePropertiesStep.name}</pre>
<c:if test="#{CmsArticlePropertiesStep.canEdit}"> <c:if test="#{CmsSelectedDocumentModel.canEdit}">
<button class="btn btn-primary btn-sm" <button class="btn btn-primary btn-sm"
data-toggle="modal" data-toggle="modal"
data-target="#name-edit-dialog" data-target="#name-edit-dialog"
@ -28,7 +28,7 @@
</c:if> </c:if>
</div> </div>
<c:if test="#{CmsArticlePropertiesStep.canEdit}"> <c:if test="#{CmsSelectedDocumentModel.canEdit}">
<div aria-hidden="true" <div aria-hidden="true"
aria-labelledby="name-edit-dialog-title" aria-labelledby="name-edit-dialog-title"
class="modal fade" class="modal fade"
@ -98,7 +98,7 @@
hasUnusedLocales="#{!CmsArticlePropertiesStep.unusedTitleLocales.isEmpty()}" hasUnusedLocales="#{!CmsArticlePropertiesStep.unusedTitleLocales.isEmpty()}"
headingLevel="3" headingLevel="3"
objectIdentifier="#{CmsSelectedDocumentModel.itemPath}" objectIdentifier="#{CmsSelectedDocumentModel.itemPath}"
readOnly="#{!CmsArticlePropertiesStep.canEdit}" readOnly="#{!CmsSelectedDocumentModel.canEdit}"
removeButtonLabel="#{CmsArticleMessageBundle['basicproperties.title.remove']}" removeButtonLabel="#{CmsArticleMessageBundle['basicproperties.title.remove']}"
removeDialogCancelLabel="#{CmsArticleMessageBundle['basicproperties.title.remove.cancel']}" removeDialogCancelLabel="#{CmsArticleMessageBundle['basicproperties.title.remove.cancel']}"
removeDialogSubmitLabel="#{CmsArticleMessageBundle['basicproperties.title.remove.submit']}" removeDialogSubmitLabel="#{CmsArticleMessageBundle['basicproperties.title.remove.submit']}"
@ -132,7 +132,7 @@
hasUnusedLocales="#{!CmsArticlePropertiesStep.unusedDescriptionLocales.isEmpty()}" hasUnusedLocales="#{!CmsArticlePropertiesStep.unusedDescriptionLocales.isEmpty()}"
headingLevel="3" headingLevel="3"
objectIdentifier="#{CmsSelectedDocumentModel.itemPath}" objectIdentifier="#{CmsSelectedDocumentModel.itemPath}"
readOnly="#{!CmsArticlePropertiesStep.canEdit}" readOnly="#{!CmsSelectedDocumentModel.canEdit}"
removeButtonLabel="#{CmsArticleMessageBundle['basicproperties.description.remove']}" removeButtonLabel="#{CmsArticleMessageBundle['basicproperties.description.remove']}"
removeDialogCancelLabel="#{CmsArticleMessageBundle['basicproperties.description.remove.cancel']}" removeDialogCancelLabel="#{CmsArticleMessageBundle['basicproperties.description.remove.cancel']}"
removeDialogSubmitLabel="#{CmsArticleMessageBundle['basicproperties.description.remove.submit']}" removeDialogSubmitLabel="#{CmsArticleMessageBundle['basicproperties.description.remove.submit']}"

View File

@ -1,42 +0,0 @@
<!DOCTYPE html [<!ENTITY times '&#215;'>]>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:bootstrap="http://xmlns.jcp.org/jsf/composite/components/bootstrap"
xmlns:c="http://xmlns.jcp.org/jsp/jstl/core"
xmlns:libreccm="http://xmlns.jcp.org/jsf/composite/components/libreccm"
xmlns:librecms="http://xmlns.jcp.org/jsf/composite/components/librecms"
xmlns:ui="http://xmlns.jcp.org/jsf/facelets">
<ui:composition template="/WEB-INF/views/org/librecms/ui/contentsection/documents/authoringstep.xhtml">
<ui:param name="authoringStep"
value="/libreccm/@contentsections/info/documents/test-article/@article-text" />
<ui:define name="authoringStep">
<h2>#{CmsArticleMessageBundle['textstep.header']}</h2>
<librecms:cmsEditor addButtonLabel="#{CmsArticleMessageBundle['text.editor.add_variant']}"
addDialogLocaleSelectHelp="#{CmsAdminMessages['text.editor.add.locale.help']}"
addMethod="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@article-text/add"
editDialogValueHelp="#{CmsAdminMessages['text.editor.edit.value.help']}"
editDialogValueLabel="#{CmsAdminMessages['text.editor.edit.value.label']}"
editMethod="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@article-text/edit"
editorId="article-text-editor"
hasUnusedLocales="#{!CmsArticleTextBodyStep.unusedLocales.isEmpty()}"
headingLevel="3"
objectIdentifier="#{CmsSelectedDocumentModel.itemPath}"
removeMethod="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@article-text/remove"
title="#{CmsArticleMessageBundle['text.editor.header']}"
unusedLocales="#{CmsArticleTextBodyStep.unusedLocales}"
variantUrl="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@article-text-resources/variants"
variants="#{CmsArticleTextBodyStep.variants}"
wordCountUrl="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@article-text-resources/variants/wordcount"
/>
</ui:define>
<ui:define name="scripts">
<script src="#{request.contextPath}/assets/@content-sections/cms-editor.js"></script>
</ui:define>
</ui:composition>
</html>

View File

@ -17,6 +17,7 @@
addButtonLabel="#{CmsArticleMessageBundle['text.editor.add_variant']}" addButtonLabel="#{CmsArticleMessageBundle['text.editor.add_variant']}"
addDialogLocaleSelectHelp="#{CmsAdminMessages['text.editor.add.locale.help']}" addDialogLocaleSelectHelp="#{CmsAdminMessages['text.editor.add.locale.help']}"
addMethod="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@article-text/add" addMethod="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@article-text/add"
canEdit="#{CmsSelectedDocumentModel.canEdit}"
editorPageUrl="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@article-text/edit" editorPageUrl="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@article-text/edit"
hasUnusedLocales="#{!CmsArticleTextBodyStep.unusedLocales.isEmpty()}" hasUnusedLocales="#{!CmsArticleTextBodyStep.unusedLocales.isEmpty()}"
removeMethod="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@article-text/remove" removeMethod="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@article-text/remove"