Friday, 15 August 2014

jsf - Clear input validation error from backing bean -


I have data with cell editor. And I only want to make some (selected) rows editable. And when the user uses the cell editor, I want to verify the input immediately after the value is set.

So I use the cell edit event in the data table and with the event handler I trigger the verification failure.

  & lt; P: ajax event = "cellEdit" listener = "# {bean.onEditCell}" update = ": formId: propertySelect" />  

It works like a magic if the user enters an invalid value, the editor is not closed and the error message is displayed.

What does not work after the user inputs a valid value?

I have lost one day while trying to solve it:

  • I want to reset, because the cell edit event is in "input validation failure status", then Does not trigger from Input validation when a user sets a new value - resetInput only works from the buttons I could not work on the value change it.
  • I did not know how to reset this field directly from javascript.
  • If I say "on-board" "remote command" a handler in the backing bean, but then I can not find the UINPot to call it reset value ().

      & lt; P: dataTable id = "propertySelect" value = "# {Bean.propertyValues}" var = "prop" editable = "true" editMode = "cell" scrollable = "true" scrollHeight = "200" widgetVar = "propSelectTable" filtered Gone value = "# {bean.filteredPVs}" & gt; & Lt; P: ajax event = "cellEdit" listener = "# {bean.edit seal}" update = ": # {formId}: Enable property" /> & Lt; P: ajax event = "filter" incomplete = "update toggle ()" /> & Lt; P: column id = "row selection" & gt; & Lt; F: Aspect Name = "Header" & gt; & Lt; P: Selection Boolean Checkbox id = "Toggle All" value = "# {Bean. SelectAllRows}" & gt; & Lt; P: Ajax listener = "# {bean.handleToggleAll}" update = ": # {formId}: Enable Property" /> & Lt; / P: selectBooleanCheckbox & gt; & Lt; / Ch: Aspect & gt; & Lt; P: Selection Boolean Checkbox Value = "# {Pro.Sected}" & gt; & Lt; P: ajax update = ": # {formId}: select property contact" incomplete = "update -toggle ()" listener = "# {beer.ro selector (support)}" /> & Lt; / P: selectBooleanCheckbox & gt; & Lt; / P: column & gt; & Lt; P: column headerText = "property" & gt; & Lt; H: output text value = "# {prop.name}" /> & Lt; / P: column & gt; & Lt; P: column header text = "description" & gt; & Lt; H: Output Text Value = "# {Pro.Description}" /> & Lt; / P: column & gt; & Lt; P: column header> text = "value" & gt; & Lt; P: Cell Editor sang = "# {Pro.sected}" & gt; & Lt; F: Aspect Name = "Output" & gt; & Lt; H: Output Text Value = "# {Bean DCPPV (Prop)}" /> & Lt; / Ch: Aspect & gt; & Lt; F: Aspect name = "input" & gt; & Lt; P: input text id = "pvSimple" value = "# {prop.uiValue}" provided = "# {prop.propertyValueUIElement eq 'INPUT}}" /> & Lt; P: InputTectoria ID = "PVieria" rows = "7" value = "# {PROPUVULU}" sung = "# {PROPERTY WAYE UEMENDT A 'TEXEAARA'}" /> & Lt; P: selectOneMenu id = "pvEnum" value = "# {prop.uiValue}" is provided = "# {prop.propertyValueUIElement eq 'SELECT_ONE_MENU'}" & gt; & Lt; F: selection item item label = "& lift; select value"; Item value = "" /> & Lt; F: selection item value = "# {prop.enumOptions}" var = "enum" itemLabel = "# {enum}" itemValue = "# {enum}" /> & Lt; / P: selectOneMenu & gt; & Lt; / Ch: Aspect & gt; & Lt; / P: cellEditor & gt; & Lt; H: Output Text Value = "-" Provided = "# {! Prop. Sealct}" /> & Lt; / P: column & gt; 
  • "or" PVNum ".


No comments:

Post a Comment