ICEfaces
  1. ICEfaces
  2. ICE-2367

Allow panelTabSet to change tabs without validation

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.7DR#2
    • Fix Version/s: 1.7.1
    • Component/s: ICE-Components
    • Labels:
      None
    • Environment:
      All

      Description

      First off, I'm not saying that panelTabSet should always switch tabs without validation, just that it should have an attribute that can determine if it does or not. Something like "immediate" should suffice.

        Issue Links

          Activity

          Hide
          Michael Thiem added a comment -

          default behaviour until 1.6.1 was that validation errors prevented a tab change. since 1.6.2 it is just the other way round and validation errors do allow tab changes. seems there's a regression since 1.6.2. However an additional attribute would solve the issue for both cases.

          Show
          Michael Thiem added a comment - default behaviour until 1.6.1 was that validation errors prevented a tab change. since 1.6.2 it is just the other way round and validation errors do allow tab changes. seems there's a regression since 1.6.2. However an additional attribute would solve the issue for both cases.
          Hide
          Ken Fyten added a comment -

          After some consideration it seems that the expected behavior in this case would be that the tab would not switch if a component on the form was in an invalid state. This would be consistent with any other component that could fire an action event (button).

          However, in order to provide more flexibility to component users it would also be a good idea to add support for both the 'immediate' and 'partialSubmit' attributes to the panelTabSet component.

          Developers could override the default behavior via 'immediate=true' if desired, thus having the panels switch regardless of the state of the components within them.

          Setting 'partialSubmit=false' would allow the panelTabSet to enforce the 'required=true' attributes on any input components on the visible tab (or in the form, for that matter).

          Does this seem reasonable?

          Show
          Ken Fyten added a comment - After some consideration it seems that the expected behavior in this case would be that the tab would not switch if a component on the form was in an invalid state. This would be consistent with any other component that could fire an action event (button). However, in order to provide more flexibility to component users it would also be a good idea to add support for both the 'immediate' and 'partialSubmit' attributes to the panelTabSet component. Developers could override the default behavior via 'immediate=true' if desired, thus having the panels switch regardless of the state of the components within them. Setting 'partialSubmit=false' would allow the panelTabSet to enforce the 'required=true' attributes on any input components on the visible tab (or in the form, for that matter). Does this seem reasonable?
          Hide
          Adnan Durrani added a comment -

          trunk: revision 16651

          Following two attributes added to the panelTabSet:

          • partialSubmit (default value true)
          • immediate

          To stop the validation on tabchange the immediate attribute can be set to true.
          Tabchange uses partialSubmit by default, to use the full submit set the partialSubmit to false.

          Show
          Adnan Durrani added a comment - trunk: revision 16651 Following two attributes added to the panelTabSet: partialSubmit (default value true) immediate To stop the validation on tabchange the immediate attribute can be set to true. Tabchange uses partialSubmit by default, to use the full submit set the partialSubmit to false.
          Hide
          Ken Fyten added a comment -

          Need this applied to the icefaces-1.7 branch for 1.7.1 also.

          Show
          Ken Fyten added a comment - Need this applied to the icefaces-1.7 branch for 1.7.1 also.
          Hide
          Adnan Durrani added a comment -

          branch 1.7 revision 16680

          Show
          Adnan Durrani added a comment - branch 1.7 revision 16680
          Hide
          Mark Collette added a comment -

          Reverted a change I'd made, back to Adnan's commit, to fix a regression.

          Subversion 18887
          icefaces\component\src\com\icesoft\faces\component\paneltabset\PanelTabSet.java

          Show
          Mark Collette added a comment - Reverted a change I'd made, back to Adnan's commit, to fix a regression. Subversion 18887 icefaces\component\src\com\icesoft\faces\component\paneltabset\PanelTabSet.java

            People

            • Assignee:
              Unassigned
              Reporter:
              Mark Collette
            • Votes:
              7 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: