You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Dave (JIRA)" <de...@myfaces.apache.org> on 2009/06/20 14:10:07 UTC

[jira] Created: (TRINIDAD-1514) does not add index to id

<tr:iterator> does not add index to id
--------------------------------------

                 Key: TRINIDAD-1514
                 URL: https://issues.apache.org/jira/browse/TRINIDAD-1514
             Project: MyFaces Trinidad
          Issue Type: Bug
          Components: Components
    Affects Versions:  1.2.12-core
         Environment: IE7, Trinidad 1.2.11, JSF ri 1.2_12
            Reporter: Dave


<tr:iterator id="itr" value="#{bean.valueList}">

<f:subview id="subPage">
   <jsp:include page="subPage1.jsp" />
</f:subview>	

</tr:iterator>

subPage1.jsp
-------------------
<tr:commandLink id="command" ...>


All the comandLink IDs in the generated html are the same:  itr:subPage.command
Suppose the  valueList has 10 elements,  10 commandLinks will be generated. if any command link is clicked, all the 10 bound methods will be executed in server side.  

Indice need to be add to component id under <tr:iterator>. For the example above.  IDs should be

itr:0:subPage.command
itr:1:subPage.command
itr:2:subPage.command
itr:3:subPage.command
itr:4:subPage.command
itr:5:subPage.command
itr:6:subPage.command
itr:7:subPage.command
itr:8:subPage.command
itr:9:subPage.command

<tr:iterator> inside <tr:iterator> has the same problem.




-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Reopened: (TRINIDAD-1514) does not add index to id

Posted by "Andrew Robinson (JIRA)" <de...@myfaces.apache.org>.
     [ https://issues.apache.org/jira/browse/TRINIDAD-1514?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew Robinson reopened TRINIDAD-1514:
---------------------------------------


Okay, I was able to reproduce the problem. The links are getting the correct javascript but not the correct client ID inside the include with Trinidad 1.2.11.

I'll upload the test case.

> <tr:iterator> does not add index to id
> --------------------------------------
>
>                 Key: TRINIDAD-1514
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-1514
>             Project: MyFaces Trinidad
>          Issue Type: Bug
>          Components: Components
>    Affects Versions:  1.2.12-core
>         Environment: IE7, Trinidad 1.2.11, JSF ri 1.2_12
>            Reporter: Dave
>
> <tr:iterator id="itr" value="#{bean.valueList}">
> <f:subview id="subPage">
>    <jsp:include page="subPage1.jsp" />
> </f:subview>	
> </tr:iterator>
> subPage1.jsp
> -------------------
> <tr:commandLink id="command" ...>
> All the comandLink IDs in the generated html are the same:  itr:subPage.command
> Suppose the  valueList has 10 elements,  10 commandLinks will be generated. if any command link is clicked, all the 10 bound methods will be executed in server side.  
> Indice need to be add to component id under <tr:iterator>. For the example above.  IDs should be
> itr:0:subPage.command
> itr:1:subPage.command
> itr:2:subPage.command
> itr:3:subPage.command
> itr:4:subPage.command
> itr:5:subPage.command
> itr:6:subPage.command
> itr:7:subPage.command
> itr:8:subPage.command
> itr:9:subPage.command
> <tr:iterator> inside <tr:iterator> has the same problem.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (TRINIDAD-1514) does not add index to id

Posted by "Andrew Robinson (JIRA)" <de...@myfaces.apache.org>.
     [ https://issues.apache.org/jira/browse/TRINIDAD-1514?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew Robinson resolved TRINIDAD-1514.
---------------------------------------

       Resolution: Fixed
    Fix Version/s:  1.2.12-core

Changed the code so that client IDs get reset for all UIXCollection children, not just EditableValueHolder, UIXCollection and UIXShowDetail components

> <tr:iterator> does not add index to id
> --------------------------------------
>
>                 Key: TRINIDAD-1514
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-1514
>             Project: MyFaces Trinidad
>          Issue Type: Bug
>          Components: Components
>    Affects Versions:  1.2.12-core
>         Environment: IE7, Trinidad 1.2.11, JSF ri 1.2_12
>            Reporter: Dave
>            Assignee: Andrew Robinson
>             Fix For:  1.2.12-core
>
>         Attachments: TRINIDAD-1514.tar.bz2
>
>
> <tr:iterator id="itr" value="#{bean.valueList}">
> <f:subview id="subPage">
>    <jsp:include page="subPage1.jsp" />
> </f:subview>	
> </tr:iterator>
> subPage1.jsp
> -------------------
> <tr:commandLink id="command" ...>
> All the comandLink IDs in the generated html are the same:  itr:subPage.command
> Suppose the  valueList has 10 elements,  10 commandLinks will be generated. if any command link is clicked, all the 10 bound methods will be executed in server side.  
> Indice need to be add to component id under <tr:iterator>. For the example above.  IDs should be
> itr:0:subPage.command
> itr:1:subPage.command
> itr:2:subPage.command
> itr:3:subPage.command
> itr:4:subPage.command
> itr:5:subPage.command
> itr:6:subPage.command
> itr:7:subPage.command
> itr:8:subPage.command
> itr:9:subPage.command
> <tr:iterator> inside <tr:iterator> has the same problem.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (TRINIDAD-1514) does not add index to id

Posted by "Andrew Robinson (JIRA)" <de...@myfaces.apache.org>.
    [ https://issues.apache.org/jira/browse/TRINIDAD-1514?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12722671#action_12722671 ] 

Andrew Robinson commented on TRINIDAD-1514:
-------------------------------------------

Work-around, remove the f:subview, the stamps are correctly created when the subview is not there.

> <tr:iterator> does not add index to id
> --------------------------------------
>
>                 Key: TRINIDAD-1514
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-1514
>             Project: MyFaces Trinidad
>          Issue Type: Bug
>          Components: Components
>    Affects Versions:  1.2.12-core
>         Environment: IE7, Trinidad 1.2.11, JSF ri 1.2_12
>            Reporter: Dave
>         Attachments: TRINIDAD-1514.tar.bz2
>
>
> <tr:iterator id="itr" value="#{bean.valueList}">
> <f:subview id="subPage">
>    <jsp:include page="subPage1.jsp" />
> </f:subview>	
> </tr:iterator>
> subPage1.jsp
> -------------------
> <tr:commandLink id="command" ...>
> All the comandLink IDs in the generated html are the same:  itr:subPage.command
> Suppose the  valueList has 10 elements,  10 commandLinks will be generated. if any command link is clicked, all the 10 bound methods will be executed in server side.  
> Indice need to be add to component id under <tr:iterator>. For the example above.  IDs should be
> itr:0:subPage.command
> itr:1:subPage.command
> itr:2:subPage.command
> itr:3:subPage.command
> itr:4:subPage.command
> itr:5:subPage.command
> itr:6:subPage.command
> itr:7:subPage.command
> itr:8:subPage.command
> itr:9:subPage.command
> <tr:iterator> inside <tr:iterator> has the same problem.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (TRINIDAD-1514) does not add index to id

Posted by "Andrew Robinson (JIRA)" <de...@myfaces.apache.org>.
    [ https://issues.apache.org/jira/browse/TRINIDAD-1514?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12722637#action_12722637 ] 

Andrew Robinson edited comment on TRINIDAD-1514 at 6/22/09 8:28 AM:
--------------------------------------------------------------------

That is not a bug. The include only happens once, and then the include will stamp out the component the include builds once per iteration. There is only one link component in your example, not several. You can also use f:setPropertyActionListener to set data based on the index or use the event passed into the actionListener to determine which loop is executing as the action event will be executed in context.

You can go to the demo here:
http://www.irian.at/trinidad-demo/faces/components/iterator.jspx

See _idJsp10:0:_idJsp12 vs _idJsp10:1:_idJsp12

To see that client ID's correctly get the index. If you have a use case otherwise, then submit a test case that shows when the client ID is not different per component stamp.

      was (Author: arobinson74):
    That is not a bug. The include only happens once, and then the include will stamp out the component the include builds once per iteration. There is only one link component in your example, not several. You can also use f:setPropertyActionListener to set data based on the index or use the event passed into the actionListener to determine which loop is executing as the action event will be executed in context.

In the future, please discuss issues on the users mailing list before submitting bugs.
  
> <tr:iterator> does not add index to id
> --------------------------------------
>
>                 Key: TRINIDAD-1514
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-1514
>             Project: MyFaces Trinidad
>          Issue Type: Bug
>          Components: Components
>    Affects Versions:  1.2.12-core
>         Environment: IE7, Trinidad 1.2.11, JSF ri 1.2_12
>            Reporter: Dave
>
> <tr:iterator id="itr" value="#{bean.valueList}">
> <f:subview id="subPage">
>    <jsp:include page="subPage1.jsp" />
> </f:subview>	
> </tr:iterator>
> subPage1.jsp
> -------------------
> <tr:commandLink id="command" ...>
> All the comandLink IDs in the generated html are the same:  itr:subPage.command
> Suppose the  valueList has 10 elements,  10 commandLinks will be generated. if any command link is clicked, all the 10 bound methods will be executed in server side.  
> Indice need to be add to component id under <tr:iterator>. For the example above.  IDs should be
> itr:0:subPage.command
> itr:1:subPage.command
> itr:2:subPage.command
> itr:3:subPage.command
> itr:4:subPage.command
> itr:5:subPage.command
> itr:6:subPage.command
> itr:7:subPage.command
> itr:8:subPage.command
> itr:9:subPage.command
> <tr:iterator> inside <tr:iterator> has the same problem.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (TRINIDAD-1514) does not add index to id

Posted by "Andrew Robinson (JIRA)" <de...@myfaces.apache.org>.
     [ https://issues.apache.org/jira/browse/TRINIDAD-1514?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew Robinson resolved TRINIDAD-1514.
---------------------------------------

    Resolution: Fixed

> <tr:iterator> does not add index to id
> --------------------------------------
>
>                 Key: TRINIDAD-1514
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-1514
>             Project: MyFaces Trinidad
>          Issue Type: Bug
>          Components: Components
>    Affects Versions:  1.2.12-core
>         Environment: IE7, Trinidad 1.2.11, JSF ri 1.2_12
>            Reporter: Dave
>            Assignee: Andrew Robinson
>             Fix For:  1.2.12-core
>
>         Attachments: TRINIDAD-1514.tar.bz2
>
>
> <tr:iterator id="itr" value="#{bean.valueList}">
> <f:subview id="subPage">
>    <jsp:include page="subPage1.jsp" />
> </f:subview>	
> </tr:iterator>
> subPage1.jsp
> -------------------
> <tr:commandLink id="command" ...>
> All the comandLink IDs in the generated html are the same:  itr:subPage.command
> Suppose the  valueList has 10 elements,  10 commandLinks will be generated. if any command link is clicked, all the 10 bound methods will be executed in server side.  
> Indice need to be add to component id under <tr:iterator>. For the example above.  IDs should be
> itr:0:subPage.command
> itr:1:subPage.command
> itr:2:subPage.command
> itr:3:subPage.command
> itr:4:subPage.command
> itr:5:subPage.command
> itr:6:subPage.command
> itr:7:subPage.command
> itr:8:subPage.command
> itr:9:subPage.command
> <tr:iterator> inside <tr:iterator> has the same problem.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (TRINIDAD-1514) does not add index to id

Posted by "Andrew Robinson (JIRA)" <de...@myfaces.apache.org>.
     [ https://issues.apache.org/jira/browse/TRINIDAD-1514?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew Robinson resolved TRINIDAD-1514.
---------------------------------------

    Resolution: Invalid

That is not a bug. The include only happens once, and then the include will stamp out the component the include builds once per iteration. There is only one link component in your example, not several. You can also use f:setPropertyActionListener to set data based on the index or use the event passed into the actionListener to determine which loop is executing as the action event will be executed in context.

In the future, please discuss issues on the users mailing list before submitting bugs.

> <tr:iterator> does not add index to id
> --------------------------------------
>
>                 Key: TRINIDAD-1514
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-1514
>             Project: MyFaces Trinidad
>          Issue Type: Bug
>          Components: Components
>    Affects Versions:  1.2.12-core
>         Environment: IE7, Trinidad 1.2.11, JSF ri 1.2_12
>            Reporter: Dave
>
> <tr:iterator id="itr" value="#{bean.valueList}">
> <f:subview id="subPage">
>    <jsp:include page="subPage1.jsp" />
> </f:subview>	
> </tr:iterator>
> subPage1.jsp
> -------------------
> <tr:commandLink id="command" ...>
> All the comandLink IDs in the generated html are the same:  itr:subPage.command
> Suppose the  valueList has 10 elements,  10 commandLinks will be generated. if any command link is clicked, all the 10 bound methods will be executed in server side.  
> Indice need to be add to component id under <tr:iterator>. For the example above.  IDs should be
> itr:0:subPage.command
> itr:1:subPage.command
> itr:2:subPage.command
> itr:3:subPage.command
> itr:4:subPage.command
> itr:5:subPage.command
> itr:6:subPage.command
> itr:7:subPage.command
> itr:8:subPage.command
> itr:9:subPage.command
> <tr:iterator> inside <tr:iterator> has the same problem.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Reopened: (TRINIDAD-1514) does not add index to id

Posted by "Andrew Robinson (JIRA)" <de...@myfaces.apache.org>.
     [ https://issues.apache.org/jira/browse/TRINIDAD-1514?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew Robinson reopened TRINIDAD-1514:
---------------------------------------


Found a use case where this still does not work

> <tr:iterator> does not add index to id
> --------------------------------------
>
>                 Key: TRINIDAD-1514
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-1514
>             Project: MyFaces Trinidad
>          Issue Type: Bug
>          Components: Components
>    Affects Versions:  1.2.12-core
>         Environment: IE7, Trinidad 1.2.11, JSF ri 1.2_12
>            Reporter: Dave
>            Assignee: Andrew Robinson
>             Fix For:  1.2.12-core
>
>         Attachments: TRINIDAD-1514.tar.bz2
>
>
> <tr:iterator id="itr" value="#{bean.valueList}">
> <f:subview id="subPage">
>    <jsp:include page="subPage1.jsp" />
> </f:subview>	
> </tr:iterator>
> subPage1.jsp
> -------------------
> <tr:commandLink id="command" ...>
> All the comandLink IDs in the generated html are the same:  itr:subPage.command
> Suppose the  valueList has 10 elements,  10 commandLinks will be generated. if any command link is clicked, all the 10 bound methods will be executed in server side.  
> Indice need to be add to component id under <tr:iterator>. For the example above.  IDs should be
> itr:0:subPage.command
> itr:1:subPage.command
> itr:2:subPage.command
> itr:3:subPage.command
> itr:4:subPage.command
> itr:5:subPage.command
> itr:6:subPage.command
> itr:7:subPage.command
> itr:8:subPage.command
> itr:9:subPage.command
> <tr:iterator> inside <tr:iterator> has the same problem.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (TRINIDAD-1514) does not add index to id

Posted by "Andrew Robinson (JIRA)" <de...@myfaces.apache.org>.
    [ https://issues.apache.org/jira/browse/TRINIDAD-1514?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12722658#action_12722658 ] 

Andrew Robinson edited comment on TRINIDAD-1514 at 6/22/09 9:08 AM:
--------------------------------------------------------------------

Okay, I was able to reproduce the problem. The links are not getting the correct client ID inside the include with Trinidad 1.2.11.

I'll upload the test case.

      was (Author: arobinson74):
    Okay, I was able to reproduce the problem. The links are getting the correct javascript but not the correct client ID inside the include with Trinidad 1.2.11.

I'll upload the test case.
  
> <tr:iterator> does not add index to id
> --------------------------------------
>
>                 Key: TRINIDAD-1514
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-1514
>             Project: MyFaces Trinidad
>          Issue Type: Bug
>          Components: Components
>    Affects Versions:  1.2.12-core
>         Environment: IE7, Trinidad 1.2.11, JSF ri 1.2_12
>            Reporter: Dave
>         Attachments: TRINIDAD-1514.tar.bz2
>
>
> <tr:iterator id="itr" value="#{bean.valueList}">
> <f:subview id="subPage">
>    <jsp:include page="subPage1.jsp" />
> </f:subview>	
> </tr:iterator>
> subPage1.jsp
> -------------------
> <tr:commandLink id="command" ...>
> All the comandLink IDs in the generated html are the same:  itr:subPage.command
> Suppose the  valueList has 10 elements,  10 commandLinks will be generated. if any command link is clicked, all the 10 bound methods will be executed in server side.  
> Indice need to be add to component id under <tr:iterator>. For the example above.  IDs should be
> itr:0:subPage.command
> itr:1:subPage.command
> itr:2:subPage.command
> itr:3:subPage.command
> itr:4:subPage.command
> itr:5:subPage.command
> itr:6:subPage.command
> itr:7:subPage.command
> itr:8:subPage.command
> itr:9:subPage.command
> <tr:iterator> inside <tr:iterator> has the same problem.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.