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

Update title metadata on the corresponding tree node and correspendin… #4749

Merged
merged 1 commit into from
Oct 20, 2021
Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
<!--@elvariable id="root" type="org.primefaces.model.TreeNode"-->
<!--@elvariable id="buttonUpdate" type="java.lang.String"-->
<!--@elvariable id="node" type="org.primefaces.model.TreeNode"-->
<p:remoteCommand name="updateTitleMetadata" update="@(.ui-tree, .stripe.selected)" />
<p:treeTable value="#{root}"
var="item"
nodeVar="node"
Expand All @@ -47,7 +48,7 @@
disabled="#{not item.editable or readOnly}"
required="#{item.required and (not empty param['editForm:save'] or not empty param['editForm:saveContinue'])}"
styleClass="#{not item.editable or readOnly ? 'read-only disabled' : ''}">
<p:ajax event="blur" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata()' : ''}"/>
<p:ajax event="blur" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata(); updateTitleMetadata();' : ''}"/>
</p:inputText>
</h:panelGroup>

Expand All @@ -60,7 +61,7 @@
disabled="#{not item.editable or readOnly}"
required="#{item.required and (not empty param['editForm:save'] or not empty param['editForm:saveContinue'])}"
styleClass="#{not item.editable or readOnly ? 'read-only disabled' : ''}">
<p:ajax event="blur" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata()' : ''}"/>
<p:ajax event="blur" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata(); updateTitleMetadata();' : ''}"/>
</p:inputTextarea>
</h:panelGroup>

Expand All @@ -72,7 +73,7 @@
disabled="#{not item.editable or readOnly}"
required="#{item.required and (not empty param['editForm:save'] or not empty param['editForm:saveContinue'])}"
styleClass="#{not item.editable or readOnly ? 'read-only disabled' : ''}">
<p:ajax event="blur" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata()' : ''}"/>
<p:ajax event="blur" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata(); updateTitleMetadata();' : ''}"/>
</p:spinner>
</h:panelGroup>

Expand All @@ -85,7 +86,7 @@
showOn="button"
required="#{item.required and (not empty param['editForm:save'] or not empty param['editForm:saveContinue'])}"
disabled="#{not item.editable or readOnly}">
<p:ajax event="dateSelect" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata()' : ''}"/>
<p:ajax event="dateSelect" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata(); updateTitleMetadata();' : ''}"/>
</p:calendar>
</h:panelGroup>

Expand All @@ -98,7 +99,7 @@
disabled="#{not item.editable or readOnly}"
showCheckbox="true">
<f:selectItems value="#{item.items}"/>
<p:ajax event="change" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata()' : ''}"/>
<p:ajax event="change" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata(); updateTitleMetadata();' : ''}"/>
</p:selectManyMenu>
</h:panelGroup>

Expand All @@ -116,7 +117,7 @@
itemLabel="#{msgs.notSelected}"
noSelectionOption="true"/>
<f:selectItems value="#{item.items}"/>
<p:ajax event="change" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata()' : ''}"/>
<p:ajax event="change" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata(); updateTitleMetadata();' : ''}"/>
</p:selectOneMenu>
</h:panelGroup>

Expand All @@ -130,7 +131,7 @@
layout="grid"
columns="1">
<f:selectItems value="#{item.items}"/>
<p:ajax event="blur" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata()' : ''}"/>
<p:ajax event="blur" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata(); updateTitleMetadata();' : ''}"/>
</p:selectOneRadio>
</h:panelGroup>

Expand All @@ -140,7 +141,7 @@
<p:selectBooleanCheckbox id="selectBooleanCheckbox"
disabled="#{not item.editable or readOnly}"
value="#{item.active}">
<p:ajax event="change" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata()' : ''}"/>
<p:ajax event="change" oncomplete="#{request.requestURI.contains('metadataEditor') ? 'preserveMetadata(); updateTitleMetadata();' : ''}"/>
</p:selectBooleanCheckbox>
</h:panelGroup>

Expand Down