Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Validate task and tasks status in combination #5878

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Kitodo/src/main/resources/messages/errors_de.properties
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ errorInitializingProjects=Fehler beim Initialisieren der Projektliste
errorFallBackMessage=Es gab einen Fehler in der Programmausf\u00FChrung. <br/> Leider ist das anwender- und entwicklerfreundlichere M\u00F6glichkeit der Fehlerbehandlung durch Folgelink und M\u00F6glichkeit der Fehlerbenachrichtigung per Email <br/> der Datei kitodo_config.properties abgeschaltet. <br/> <br/> Bitten Sie Ihren Administrator diese M\u00F6glichkeiten der Fehlerbehandlung in kitodo_config.properties einzustellen.
fileExists=Eine Datei mit dem Namen {0} existiert bereits. Daher kann diese Datei nicht hochgeladen werden.
fileNotFound=Datei nicht gefunden: {0}.
fillOutAllOrNone=''{0}'': Bitte f\u00FCllen Sie alle oder keines dieser Felder aus!

# G
granularity.download.error=Fehler beim Vorbereiten der Daten f\u00fcr den Download
Expand Down
1 change: 1 addition & 0 deletions Kitodo/src/main/resources/messages/errors_en.properties
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ errorExporting=Error exporting ''{0}'' with ID {1}
errorFallBackMessage=There has been a program execution error. <br/> Unfortunately the user-friendly feature of a link provided for the continuation of work <br/> and the e-mail bug reporting function in kitodo_config.properties is disabled or incorrectly set up. <br/> <br/> Please ask your administrator to change the settings in kitodo_config.properties to display this error in a user-friendly format. zzz
fileExists=A file with the name {0} already exists. Therefore, this file cannot be uploaded.
fileNotFound=File not found: {0}.
fillOutAllOrNone=''{0}'': Please fill out all or none of these fields!

# G
granularity.download.error=An error arose while preparing the data for download
Expand Down
10 changes: 6 additions & 4 deletions Kitodo/src/main/webapp/WEB-INF/resources/css/pattern-library.css
Original file line number Diff line number Diff line change
Expand Up @@ -1221,10 +1221,12 @@ tr.ui-expanded-row-content:hover .ui-datatable tbody {
border: solid var(--default-border-width) var(--medium-gray);
}

.ui-state-error .ui-picklist-list {
background: #fef1ec;
border: 1px solid #cd0a0a;
color: #cd0a0a;
.ui-state-error .ui-picklist-list,
.ui-state-error .ui-selectonemenu-label,
.ui-state-error .ui-selectonemenu-trigger {
background: var(--error-background);
border: 1px solid var(--focused-orange);
color: var(--focused-orange);
}

.row-expansion-wrapper > table {
Expand Down
26 changes: 21 additions & 5 deletions Kitodo/src/main/webapp/pages/extendedSearch.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@
xmlns:f="http://xmlns.jcp.org/jsf/core"
xmlns:h="http://xmlns.jcp.org/jsf/html"
xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
xmlns:p="http://primefaces.org/ui">
xmlns:p="http://primefaces.org/ui"
xmlns:o="http://omnifaces.org/ui">
<ui:define name="contentHeader">
<h3>#{msgs.extendedSearch}</h3>

Expand All @@ -27,6 +28,7 @@
icon="fa fa-search"
iconPos="right"
styleClass="right"
update="searchTabView"
rendered="#{SecurityAccessController.hasAuthorityToViewTaskList()}"/>
<p:commandButton id="submitProcessSearch"
value="#{msgs.searchForVolume}"
Expand All @@ -35,12 +37,19 @@
icon="fa fa-search"
iconPos="right"
styleClass="right"
update="searchTabView"
rendered="#{SecurityAccessController.hasAuthorityToViewProcessList()}"/>
</ui:define>

<ui:define name="pageTabView">
<p:tabView id="searchTabView">
<p:tab id="searchTab" title="#{msgs.details}">
<o:validateAllOrNone id="processPropertyValidation"
message="#{err.fillOutAllOrNone}"
components="processProperty processPropertyTitle"/>
<o:validateAllOrNone id="taskStatusValidation"
message="#{err.fillOutAllOrNone}"
components="taskName taskStatus"/>
<p:panelGrid id="processSearch-grid">
<!-- process title -->
<p:row>
Expand Down Expand Up @@ -85,7 +94,9 @@
</p:selectOneMenu>
</p:column>
<p:column>
<p:selectOneMenu value="#{SearchForm.processPropertyTitle}">
<p:selectOneMenu id="processPropertyTitle"
label="#{msgs.value}"
value="#{SearchForm.processPropertyTitle}">
<f:selectItem itemValue="#{null}" itemLabel="#{msgs.notSelected}" noSelectionOption="true"/>
<f:selectItems value="#{SearchForm.processPropertyTitles}"
var="proc" itemLabel="#{proc}"
Expand All @@ -100,21 +111,26 @@
</p:row>
<!--steps -->
<p:row>
<p:column><p:outputLabel value="#{msgs.task}"/></p:column>
<p:column><p:outputLabel for="taskName" value="#{msgs.task}"/></p:column>
<p:column>
<p:selectOneMenu value="#{SearchForm.stepOperand}">
<f:selectItems value="#{SearchForm.operands}"/>
</p:selectOneMenu>
</p:column>
<p:column>
<p:selectOneMenu id="taskStatus" value="#{SearchForm.status}">
<p:selectOneMenu id="taskStatus"
label="#{msgs.taskStatus}"
value="#{SearchForm.status}"
requiredMessage="Bitte geben Sie sowohl den Aufgabenstatus als auch -titel an">
<f:selectItem itemValue="#{null}" itemLabel="#{msgs.notSelected}" noSelectionOption="true"/>
<f:selectItems value="#{SearchForm.stepstatus}" var="stepstatus"
itemLabel="#{HelperForm.getTranslated(stepstatus.title)}" itemValue="#{stepstatus.searchString}"/>
</p:selectOneMenu>
</p:column>
<p:column>
<p:selectOneMenu id="taskName" value="#{SearchForm.stepname}">
<p:selectOneMenu id="taskName"
value="#{SearchForm.stepname}"
requiredMessage="Bitte geben Sie sowohl den Aufgabenstatus als auch -titel an">
<f:selectItem itemValue="#{null}" itemLabel="#{msgs.notSelected}" noSelectionOption="true"/>
<f:selectItems value="#{SearchForm.stepTitles}" var="stepTitles" itemLabel="#{stepTitles}"
itemValue="#{stepTitles}"/>
Expand Down