ICEfaces
  1. ICEfaces
  2. ICE-4066

panelTabSet ignore parent's rendered attribute when put in UISeries component

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.7, 1.7.1, 1.7.2, 1.7.2 SP1
    • Fix Version/s: 1.7.2-SP2, 1.8RC2, 1.8
    • Component/s: ICE-Components
    • Labels:
      None
    • Environment:
      ANY

      Description

      see the following code:

      <ice:form>
      <ice:panelSeries value="#{bean.list}" var="item">

      <ice:panelGroup rendered="false">

      <ice:panelTabSet id="icePnlTbSet" var="tab"
      value="#{bean.listqq}" title="title">
      <ice:panelTab label="#{tab}" title="#{tab}">
      <ice:panelGroup style="height:50px;">
      <ice:outputText value="#{tab}" />
      </ice:panelGroup>
      </ice:panelTab>
      </ice:panelTabSet>
      <!--
      <ice:outputText value="#{bean.qq}"/>
      -->
      </ice:panelGroup>

      </ice:panelSeries>
      </ice:form>

      It will complain undefined property "listqq" in the bean which should not be rendered at all. To compare, uncomment the outputText and it has no problem.
      This is also a problem for ice:dataTable

        Issue Links

          Activity

          Sam Xiao created issue -
          Hide
          Sam Xiao added a comment -

          test case for tomcat 6.0 with ICEfaces 1.7.2 SP1

          Show
          Sam Xiao added a comment - test case for tomcat 6.0 with ICEfaces 1.7.2 SP1
          Sam Xiao made changes -
          Field Original Value New Value
          Attachment ICE-4066.war [ 11513 ]
          Sam Xiao made changes -
          Salesforce Case [50070000007cWeq]
          Ken Fyten made changes -
          Fix Version/s 1.8 [ 10161 ]
          Ken Fyten made changes -
          Assignee Priority P1
          Ken Fyten made changes -
          Assignee Adnan Durrani [ adnan.durrani ]
          Adnan Durrani made changes -
          Status Open [ 1 ] In Progress [ 3 ]
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #18366 Wed Feb 18 12:58:15 MST 2009 adnan.durrani Fix for ICE-4066 (panelTabSet ignore parent's rendered attribute when put in UISeries component)
          Files Changed
          Commit graph MODIFY /icefaces/trunk/icefaces/component/src/com/icesoft/faces/component/panelseries/UISeries.java
          Commit graph MODIFY /icefaces/trunk/icefaces/component/src/com/icesoft/faces/component/paneltabset/PanelTabSet.java
          Commit graph MODIFY /icefaces/trunk/icefaces/component/src/com/icesoft/faces/component/util/CustomComponentUtils.java
          Hide
          Adnan Durrani added a comment -

          Modified: D:\work\development\head\svn\ossrepo\icefaces\trunk\icefaces\component\src\com\icesoft\faces\component\panelseries\UISeries.java
          Modified: D:\work\development\head\svn\ossrepo\icefaces\trunk\icefaces\component\src\com\icesoft\faces\component\paneltabset\PanelTabSet.java
          Modified: D:\work\development\head\svn\ossrepo\icefaces\trunk\icefaces\component\src\com\icesoft\faces\component\util\CustomComponentUtils.java
          Sending content: D:\work\development\head\svn\ossrepo\icefaces\trunk\icefaces\component\src\com\icesoft\faces\component\panelseries\UISeries.java
          Sending content: D:\work\development\head\svn\ossrepo\icefaces\trunk\icefaces\component\src\com\icesoft\faces\component\paneltabset\PanelTabSet.java
          Sending content: D:\work\development\head\svn\ossrepo\icefaces\trunk\icefaces\component\src\com\icesoft\faces\component\util\CustomComponentUtils.java
          Completed: At revision: 18366

          Show
          Adnan Durrani added a comment - Modified: D:\work\development\head\svn\ossrepo\icefaces\trunk\icefaces\component\src\com\icesoft\faces\component\panelseries\UISeries.java Modified: D:\work\development\head\svn\ossrepo\icefaces\trunk\icefaces\component\src\com\icesoft\faces\component\paneltabset\PanelTabSet.java Modified: D:\work\development\head\svn\ossrepo\icefaces\trunk\icefaces\component\src\com\icesoft\faces\component\util\CustomComponentUtils.java Sending content: D:\work\development\head\svn\ossrepo\icefaces\trunk\icefaces\component\src\com\icesoft\faces\component\panelseries\UISeries.java Sending content: D:\work\development\head\svn\ossrepo\icefaces\trunk\icefaces\component\src\com\icesoft\faces\component\paneltabset\PanelTabSet.java Sending content: D:\work\development\head\svn\ossrepo\icefaces\trunk\icefaces\component\src\com\icesoft\faces\component\util\CustomComponentUtils.java Completed: At revision: 18366
          Adnan Durrani made changes -
          Status In Progress [ 3 ] Resolved [ 5 ]
          Resolution Fixed [ 1 ]
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #18426 Wed Feb 25 08:58:51 MST 2009 adnan.durrani The ICE-4066 fix backported to the 1.7 branch
          Files Changed
          Commit graph MODIFY /icefaces/branches/icefaces-1.7/icefaces/component/src/com/icesoft/faces/component/paneltabset/PanelTabSet.java
          Commit graph MODIFY /icefaces/branches/icefaces-1.7/icefaces/component/src/com/icesoft/faces/component/panelseries/UISeries.java
          Commit graph MODIFY /icefaces/branches/icefaces-1.7/icefaces/component/src/com/icesoft/faces/component/util/CustomComponentUtils.java
          Hide
          Adnan Durrani added a comment -

          Fix backported to 1.7 branch:

          Modified: D:\work\development\freshcopy\svn\ossrepo\icefaces\branches\icefaces-1.7\icefaces\component\src\com\icesoft\faces\component\panelseries\UISeries.java
          Modified: D:\work\development\freshcopy\svn\ossrepo\icefaces\branches\icefaces-1.7\icefaces\component\src\com\icesoft\faces\component\paneltabset\PanelTabSet.java
          Modified: D:\work\development\freshcopy\svn\ossrepo\icefaces\branches\icefaces-1.7\icefaces\component\src\com\icesoft\faces\component\util\CustomComponentUtils.java
          Sending content: D:\work\development\freshcopy\svn\ossrepo\icefaces\branches\icefaces-1.7\icefaces\component\src\com\icesoft\faces\component\panelseries\UISeries.java
          Sending content: D:\work\development\freshcopy\svn\ossrepo\icefaces\branches\icefaces-1.7\icefaces\component\src\com\icesoft\faces\component\paneltabset\PanelTabSet.java
          Sending content: D:\work\development\freshcopy\svn\ossrepo\icefaces\branches\icefaces-1.7\icefaces\component\src\com\icesoft\faces\component\util\CustomComponentUtils.java
          Completed: At revision: 18426

          Show
          Adnan Durrani added a comment - Fix backported to 1.7 branch: Modified: D:\work\development\freshcopy\svn\ossrepo\icefaces\branches\icefaces-1.7\icefaces\component\src\com\icesoft\faces\component\panelseries\UISeries.java Modified: D:\work\development\freshcopy\svn\ossrepo\icefaces\branches\icefaces-1.7\icefaces\component\src\com\icesoft\faces\component\paneltabset\PanelTabSet.java Modified: D:\work\development\freshcopy\svn\ossrepo\icefaces\branches\icefaces-1.7\icefaces\component\src\com\icesoft\faces\component\util\CustomComponentUtils.java Sending content: D:\work\development\freshcopy\svn\ossrepo\icefaces\branches\icefaces-1.7\icefaces\component\src\com\icesoft\faces\component\panelseries\UISeries.java Sending content: D:\work\development\freshcopy\svn\ossrepo\icefaces\branches\icefaces-1.7\icefaces\component\src\com\icesoft\faces\component\paneltabset\PanelTabSet.java Sending content: D:\work\development\freshcopy\svn\ossrepo\icefaces\branches\icefaces-1.7\icefaces\component\src\com\icesoft\faces\component\util\CustomComponentUtils.java Completed: At revision: 18426
          Ken Fyten made changes -
          Fix Version/s 1.7.3 [ 10162 ]
          Assignee Priority P1
          Hide
          Joanne Bai added a comment -

          QA tested it successfully on ICEfaces-1.8.0 build 3 + tomcat6 for IE6, FF2, Opera9.27. Both ice:panelTabSet and ice:dataTable passed the test.

          Show
          Joanne Bai added a comment - QA tested it successfully on ICEfaces-1.8.0 build 3 + tomcat6 for IE6, FF2, Opera9.27. Both ice:panelTabSet and ice:dataTable passed the test.
          Ken Fyten made changes -
          Fix Version/s 1.8RC2 [ 10163 ]
          Fix Version/s 1.8 [ 10161 ]
          Hide
          Ken Fyten added a comment -

          Follow-up regression created by this fix is noted in ICE-4253.

          Show
          Ken Fyten added a comment - Follow-up regression created by this fix is noted in ICE-4253 .
          Adnan Durrani made changes -
          Link This issue depends on ICE-4253 [ ICE-4253 ]
          Ken Fyten made changes -
          Fix Version/s 1.8 [ 10161 ]
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #18758 Mon Apr 06 12:21:53 MDT 2009 adnan.durrani Fix for ICE-4324 (REGRESSION of ICE-4066 : input component values being applied to other rows in some specific scenarios)
          The fix of ICE-4066, caused ICE-4324 and ICE-4253. So in this commit we have rectified the fix of ICE-4066 which invalidates the following cases ICE-4324 and ICE-4253, as they were ever exist.
          Files Changed
          Commit graph MODIFY /icefaces/trunk/icefaces/component/src/com/icesoft/faces/component/panelseries/UISeries.java
          Commit graph MODIFY /icefaces/trunk/icefaces/component/src/com/icesoft/faces/component/paneltabset/PanelTabSet.java
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #18759 Mon Apr 06 13:01:50 MDT 2009 adnan.durrani Backporting fix for ICE-4324 (REGRESSION of ICE-4066 : input component values being applied to other rows in some specific scenarios)
          The fix of ICE-4066, caused ICE-4324 and ICE-4253. So in this commit we have rectified the fix of ICE-4066 which invalidates the following cases ICE-4324 and ICE-4253, as they were ever exist.
          Files Changed
          Commit graph MODIFY /icefaces/branches/icefaces-1.7/icefaces/component/src/com/icesoft/faces/component/paneltabset/PanelTabSet.java
          Commit graph MODIFY /icefaces/branches/icefaces-1.7/icefaces/component/src/com/icesoft/faces/component/panelseries/UISeries.java
          Hide
          Joanne Bai added a comment -

          verified on 1.7.2-SP2 build 3 with success (tomcat 6 + IE6 and FF2)

          Show
          Joanne Bai added a comment - verified on 1.7.2-SP2 build 3 with success (tomcat 6 + IE6 and FF2)
          Ken Fyten made changes -
          Status Resolved [ 5 ] Closed [ 6 ]
          Assignee Adnan Durrani [ adnan.durrani ]
          Hide
          ?ukasz Pogorzelski added a comment -

          The problem has been fixed only partially. As I see in the code:

          UISeries.java
              public Object getValue() {
                  try {
                      return super.getValue();
                  } catch (Exception e) {
                      //ICE-4066
                      if (CustomComponentUtils.isAncestorRendered(this)) {
                          throw new FacesException(e);
                      }
                  }
                  return null;
              }
          

          the method isAncestorRenderer finds the first ancestor and evaluates its rendered attribute. But what if ancestor rendered attribute is a value binding, and that ancestor should not be rendered at all ? Value binding is correct only for this panelGroup which is not rendered too. Below is a sample code:

          <ice:panelSeries value="#{bean.list}" var="item">
          
              <ice:panelGroup rendered="false">
          
                  <ice:panelPopup rendered="#{bean.visible}">
          
                      <ice:panelTabSet id="icePnlTbSet" var="tab" value="#{bean.listqq}" title="title">
                      <ice:panelTab label="#{tab}" title="#{tab}">
                          <ice:panelGroup style="height:50px;">
                          <ice:outputText value="#{tab}" />
                          </ice:panelGroup>
                       </ice:panelTab>
                       </ice:panelTabSet>
          
                  </ice:panelPopup>
          
              </ice:panelGroup>
          
          </ice:panelSeries>
          
          Show
          ?ukasz Pogorzelski added a comment - The problem has been fixed only partially. As I see in the code: UISeries.java public Object getValue() { try { return super .getValue(); } catch (Exception e) { //ICE-4066 if (CustomComponentUtils.isAncestorRendered( this )) { throw new FacesException(e); } } return null ; } the method isAncestorRenderer finds the first ancestor and evaluates its rendered attribute. But what if ancestor rendered attribute is a value binding, and that ancestor should not be rendered at all ? Value binding is correct only for this panelGroup which is not rendered too. Below is a sample code: <ice:panelSeries value= "#{bean.list}" var = "item" > <ice:panelGroup rendered= " false " > <ice:panelPopup rendered= "#{bean.visible}" > <ice:panelTabSet id= "icePnlTbSet" var = "tab" value= "#{bean.listqq}" title= "title" > <ice:panelTab label= "#{tab}" title= "#{tab}" > <ice:panelGroup style= "height:50px;" > <ice:outputText value= "#{tab}" /> </ice:panelGroup> </ice:panelTab> </ice:panelTabSet> </ice:panelPopup> </ice:panelGroup> </ice:panelSeries>

            People

            • Assignee:
              Unassigned
              Reporter:
              Sam Xiao
            • Votes:
              2 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: