Code: Select all
<p:column headerText="Time From" >
<p:cellEditor>
<f:facet name="output">
<p:calendar pattern="dd/MM/yyyy HH:mm:ss.SSS" value="#{aa.timeFrom}"/>
</f:facet>
<f:facet name="input">
<p:calendar pattern="dd/MM/yyyy HH:mm:ss.SSS" value="#{aa.timeFrom}"/>
</f:facet>
</p:cellEditor>
</p:column>
<p:column headerText="Time To">
<p:cellEditor>
<f:facet name="output">
<p:calendar pattern="dd/MM/yyyy HH:mm:ss.SSS" value="#{aa.timeTo}"/>
</f:facet>
<f:facet name="input">
<p:calendar pattern="dd/MM/yyyy HH:mm:ss.SSS" value="#{aa.timeTo}"/>
</f:facet>
</p:cellEditor>
</p:column>
Code: Select all
<p:commandButton value="Submit" action="#{aa.submit}" />
"'123456' could not be understood as a date and time. Example: 15/01/2018 11:54:02.247"
The submit action is called when the user clicks on "submit" button. The problem is that in the submit action, the invalid values returned are null and not the values entered by the user. The valid values are correctly set. How can I get the invalid values entered by the user in the submit action? In the above example, I would like to get "123456" instead of null.
If invalid values cannot be returned, then is it possible to find which cells have invalid values in the submit action? I want to distinguish between values not entered and invalid values entered (Both of the date/times are optional).