Is there a mechanism in
JSF 1.1 to execute and action even if there are validation errors without using immediate attribute.
Lets take an example: We have a JSF page with
- One input field that is has value pointing to a Integer in a backing bean
- Table with Integer input fields pointing to List<Integer> in backing bean.
- Button to add new rows to table.
Backing bean:
JSP:
With this setup the user should be able to add new rows to the table. How ever adding new rows should be possible even if there are validation/conversion errors.
Scenario 1:
- User types "foo" to the count-field
- User presses Add Row-button
FAILURE: new row is not added because there are conversion errors on the count-field
Scenario 2:
- Add the "immediate=true" for the commandButton
- User inserts "3" for the first value field in the table.
- User presses the Add Row-button
FAILURE: New row is added but the inserted value "3" is disregarded (changes back to "0" in the page).
Applying the immediate=true for input fields would not help much as that would required adding it to all fileds in the page (including the count field). And still the Add Row-action should be executed even if there are errors on field validations/conversions.
Any ideas how to solve the problem?