Some Bugfixes
parent
6f026f99a7
commit
6b48c5deec
|
|
@ -48,8 +48,8 @@ public class MultiPartArticleSectionManager {
|
|||
|
||||
article.addSection(section);
|
||||
section.setRank(article.getSections().size() - 1);
|
||||
itemRepo.save(article);
|
||||
sectionRepo.save(section);
|
||||
itemRepo.save(article);
|
||||
}
|
||||
|
||||
@Transactional(Transactional.TxType.REQUIRED)
|
||||
|
|
|
|||
|
|
@ -151,7 +151,7 @@ public class MvcMpaSectionsStep extends AbstractMvcAuthoringStep {
|
|||
final String sectionIdentifier,
|
||||
@PathParam(MvcAuthoringSteps.DOCUMENT_PATH_PATH_PARAM_NAME)
|
||||
final String documentPath,
|
||||
@FormParam("initialLocal") @DefaultValue("")
|
||||
@FormParam("initialLocale") @DefaultValue("")
|
||||
final String initialLocaleParam,
|
||||
@FormParam("title") @DefaultValue("")
|
||||
final String title,
|
||||
|
|
@ -662,7 +662,7 @@ public class MvcMpaSectionsStep extends AbstractMvcAuthoringStep {
|
|||
}
|
||||
row.setTitle(
|
||||
globalizationHelper.getValueFromLocalizedString(
|
||||
section.getText()
|
||||
section.getTitle()
|
||||
)
|
||||
);
|
||||
|
||||
|
|
|
|||
|
|
@ -13,11 +13,24 @@
|
|||
<ui:define name="authoringStep">
|
||||
<h2>#{CmsMpaMessageBundle.getMessage('sectionsstep.header', [CmsMpaSectionsStep.articleTitle])}</h2>
|
||||
|
||||
<c:choose>
|
||||
<c:when test="#{initialLocaleMissing}">
|
||||
<div class="alert alert-danger">
|
||||
#{CmsMpaMessageBundle['sectionsstep.error.initial_locale_missing']}
|
||||
</div>
|
||||
</c:when>
|
||||
<c:when test="#{titleMissing}">
|
||||
<div>
|
||||
#{CmsMpaMessageBundle['sectionsstep.error.title_missing']}
|
||||
</div>
|
||||
</c:when>
|
||||
</c:choose>
|
||||
|
||||
<c:if test="#{CmsMpaSectionsStep.canEdit}">
|
||||
<div class="text-right">
|
||||
<button
|
||||
class="btn btn-secondary"
|
||||
data-target="add-section-dialog"
|
||||
data-target="#add-section-dialog"
|
||||
data-toggle="modal"
|
||||
type="button"
|
||||
>
|
||||
|
|
@ -50,12 +63,12 @@
|
|||
</span>
|
||||
</button>
|
||||
</div>
|
||||
<div class="modal-content">
|
||||
<div class="modal-body">
|
||||
<bootstrap:formGroupSelect
|
||||
help="#{CmsMpaMessageBundle['sectionsstep.sections.add.dialog.initial_locale.help']}"
|
||||
inputId="locale"
|
||||
label="#{CmsMpaMessageBundle['sectionsstep.sections.add.dialog.initial_locale.label']}"
|
||||
name="locale"
|
||||
name="initialLocale"
|
||||
options="#{CmsMpaCreateStep.availableLocales}"
|
||||
required="true"
|
||||
selectedOptions="#{[CmsMpaCreateStep.initialLocale]}" />
|
||||
|
|
@ -65,16 +78,18 @@
|
|||
inputId="title"
|
||||
label="#{CmsMpaMessageBundle['sectionsstep.sections.add.dialog.title.label']}"
|
||||
name="title"
|
||||
required="true" />
|
||||
required="true"
|
||||
value="#{title}" />
|
||||
|
||||
<bootstrap:formGroupTextarea
|
||||
cols="80"
|
||||
help="#{CmsMpaMessageBundle['sectionsstep.sections.add.dialog.text.help']}"
|
||||
inputId="summary"
|
||||
label="#{CmsMpaMessageBundle['sectionsstep.sections.add.dialog.text.label']}"
|
||||
name="summary"
|
||||
name="text"
|
||||
required="true"
|
||||
rows="16"
|
||||
rows="10"
|
||||
value="#{text}"
|
||||
/>
|
||||
|
||||
</div>
|
||||
|
|
@ -102,13 +117,13 @@
|
|||
</p>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
<table>
|
||||
<table class="table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>#{CmsMpaMessageBundle['sectionsstep.sections.section.title']}</th>
|
||||
<th>#{CmsMpaMessageBundle['sectionsstep.sections.text']}</th>
|
||||
<th>#{CmsMpaMessageBundle['sectionsstep.sections.pagebreak']}</th>
|
||||
<th>#{CmsMpaMessageBundle['sectionsstep.sections.actions']}</th>
|
||||
<th colspan="2">#{CmsMpaMessageBundle['sectionsstep.sections.actions']}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
|
@ -140,6 +155,8 @@
|
|||
<bootstrap:svgIcon icon="eye" />
|
||||
<span class="sr-only">#{CmsMpaMessageBundle['sectionsstep.sections.section.show_details']}</span>
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
<c:if test="#{CmsMpaSectionsStep.canEdit}">
|
||||
<libreccm:deleteDialog
|
||||
actionTarget="#{mvc.basePath}/#{ContentSectionModel.sectionName}/documents/#{CmsSelectedDocumentModel.itemPath}/@mpa-sections/#{section.sectionId}/@remove"
|
||||
|
|
|
|||
|
|
@ -114,3 +114,5 @@ sectionstep.textstep.header.edit=Edit text for locale {2} of section {1} of mult
|
|||
sectionstep.textstep.text.editor.header=Text
|
||||
authoringsteps.sections.label=Sections
|
||||
sectionsstep.sections.empty=This multipart article has no sections yet.
|
||||
sectionsstep.error.initial_locale_missing=Initial locale is missing.
|
||||
sectionsstep.error.title_missing=Title for the new section is missing.
|
||||
|
|
|
|||
|
|
@ -114,3 +114,5 @@ sectionstep.textstep.header.edit=Text f\u00fcr Sprache {2} des Abschnitts {1} de
|
|||
sectionstep.textstep.text.editor.header=Text
|
||||
authoringsteps.sections.label=Abschnitte
|
||||
sectionsstep.sections.empty=Diese mehrteilige Artikel hat noch keine Abschnitte.
|
||||
sectionsstep.error.initial_locale_missing=Es wurde keine initiale Sprache f\u00fcr den neuen Abschnitt angegeben.
|
||||
sectionsstep.error.title_missing=Der Titel f\u00fcr den neuen Abschnitt wurde nicht angegeben.
|
||||
|
|
|
|||
Loading…
Reference in New Issue