ICEfaces
  1. ICEfaces
  2. ICE-1459

RowSelector doesn't correctly work with two portlets

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.6DR#3
    • Fix Version/s: 1.6.1
    • Component/s: Framework
    • Labels:
      None
    • Environment:
      any

      Description

      Contribution from Dan Leahu:

      *****
      RowSelector doesn't correctly work with two portlets because the method generated at onclick event on the row through JScript doesn't consider the current table we're in. We've fixed that by changing into TableRenderer, this:

           rowSelectionFunctionName = "ice_tableRowClicked" + rowSelectorNumber(facesContext);

      into this:

      public String textToJSMethodName(String text) {
             return text.replaceAll(":","_");
      }

      rowSelectorId = textToJSMethodName(uiComponent.getClientId(facesContext));
      rowSelectionFunctionName = "ice_tableRowClicked" + rowSelectorId;

      The method rowSelectorNumber(...) which looks like this:

      private int rowSelectorNumber(FacesContext context){
             Map m = context.getExternalContext().getRequestMap();
             String key = RowSelector.class.getName() + "-Selector";
             Integer I = (Integer)m.get(key);
             int i = 0;
             if(I != null){
                 i = I.intValue();
                 i++;
             }

             I = new Integer(i);
             m.put(key, I);
             return i;
         }

      contains String key = RowSelector.class.getName() + "-Selector" which never gets an actual value as the key isn't set anywhere. We think that RowSelector should namespace its parameters by using ids which are sure to be unique hence the modifications we've done.

        Activity

        Ken Fyten made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Assignee Priority P2
        Assignee Mark Collette [ mark.collette ]
        Mark Collette made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Fix Version/s 1.6.1 [ 10070 ]
        Fix Version/s 1.7 [ 10080 ]
        Resolution Fixed [ 1 ]
        Hide
        Mark Collette added a comment -

        I took our internal "async-portlets" portlet code, and added a dataTable with a rowSelector to the timezone portlet, and then added that portlet twice, and successfully interacted with the rowSelector (and the rest of the UI too) in each, without the other being affected.

        Show
        Mark Collette added a comment - I took our internal "async-portlets" portlet code, and added a dataTable with a rowSelector to the timezone portlet, and then added that portlet twice, and successfully interacted with the rowSelector (and the rest of the UI too) in each, without the other being affected.
        Ken Fyten made changes -
        Fix Version/s 1.7 [ 10080 ]
        Fix Version/s 1.6.1 [ 10070 ]
        Hide
        Mark Collette added a comment -

        According to the Subversion commit logs, this was fixed on November 30, 2006 by Rob Mayhew as part of IRAPtor 1056.

        Show
        Mark Collette added a comment - According to the Subversion commit logs, this was fixed on November 30, 2006 by Rob Mayhew as part of IRAPtor 1056.
        Ken Fyten made changes -
        Fix Version/s 1.6.1 [ 10070 ]
        Fix Version/s 1.7 [ 10080 ]
        Assignee Priority P2
        Assignee Jack van Ooststroom [ jack.van.ooststroom ] Mark Collette [ mark.collette ]
        Ken Fyten made changes -
        Assignee User Deryk.sinotte [ deryk.sinotte ] Jack van Ooststroom [ jack.van.ooststroom ]
        Hide
        Dan Leahu added a comment -

        Hi,

        This issue was originally reported for IceFaces 1.5.3. Is this solved in 1.6 final release?

        Thanks.

        Show
        Dan Leahu added a comment - Hi, This issue was originally reported for IceFaces 1.5.3. Is this solved in 1.6 final release? Thanks.
        Ken Fyten made changes -
        Fix Version/s 1.7 [ 10080 ]
        Fix Version/s 1.6 [ 10031 ]
        Ken Fyten made changes -
        Fix Version/s 1.6 [ 10031 ]
        Fix Version/s 1.6DR#4 [ 10060 ]
        Ken Fyten made changes -
        Assignee Priority P2
        Assignee Adnan Durrani [ adnan.durrani ] Deryk Sinotte [ deryk.sinotte ]
        Ken Fyten made changes -
        Fix Version/s 1.6DR#4 [ 10060 ]
        Ken Fyten made changes -
        Assignee Priority P2
        Assignee Ken Fyten [ ken.fyten ] Adnan Durrani [ adnan.durrani ]
        Philip Breau made changes -
        Field Original Value New Value
        Assignee Ken Fyten [ ken.fyten ]
        Philip Breau created issue -

          People

          • Assignee:
            Unassigned
            Reporter:
            Philip Breau
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: