-
Type: Sub-task
-
Status: Resolved
-
Priority: Minor
-
Resolution: Fixed
-
Affects Version/s: 5.1.3.2
-
Fix Version/s: 5.1.4
-
Component/s: None
The current extended_file_widget.xhtml template looks like this
<nxu:methodResult name="immutable"
value="#
">
<nxu:methodResult name="onlineEditable"
value="#
">
<nxu:methodResult name="isLiveEditable"
value="#
">
<h:panelGroup
rendered="#
">
<h:outputText value=" | " />
<h:commandLink action="#
{FileManageWS.edit}"
rendered="#
">
<f:param name="fileFieldFullName"
value="#
" />
<f:param name="filename" value="#
" />
<f:param name="filenameFieldFullName"
value="#
" />
<h:outputText value="#
</h:commandLink>
</h:panelGroup>
</nxu:methodResult>
</nxu:methodResult>
</nxu:methodResult>
The command links itself should upgraded to something like:
<h:outputLink
value="#{nxd:liveEditUrl(changeableDocument, widget.fieldDefinitions[0].schemaName, widget.fieldDefinitions[0].fieldName, widget.fieldDefinitions[1].fieldName)}"
rendered="#{editable}">
<h:outputText value="#{messages['label.document.directEdit']}
" />
</h:outputLink>
However the rendering condition is currently dependent on several seam action listeners. This should be factorized into a single seam component call that takes the document model and the property name as parameters (do not hardcode the check on currentDocument only).