List Info

Thread: Created: (JBSEAM-1358) conversation stack not popping properly when




Created: (JBSEAM-1358) conversation stack not popping properly when
country flaguser name
United States
2007-05-27 11:37:08
conversation stack not popping properly when used with
pages.xml
------------------------------------------------------------
----

                 Key: JBSEAM-1358
                 URL: http://
jira.jboss.com/jira/browse/JBSEAM-1358
             Project: JBoss Seam
          Issue Type: Bug
          Components: Core
    Affects Versions: 1.3.0.ALPHA
            Reporter: Hung Tang


Assume there are two pages p1 and p2.  Entering p1 will
start a conversation c1.  p1 contains a s:link to p2, which
when clicked will start a new nested conversation c2.  In
p2, there's a s:link that goes back to p1 by invoking action
#{conversation.redirectToParent}.  

The strange part.

If the propagation=nested rule is specified as part of the
s:link, then the redirectToParent is working okay and the
conversationStack is consistent.
If the propagation=nested rule is specified as part of
p2.page.xml as <begin-conversation
nested="true"/>, then the redirectToParent does
not redirect to parent, and the conversationStack reports an
additional duplicate entry for p2. 

-- Code snippets
## page1.page.xml
<page>
  <description>Page 1</description>
  <begin-conversation join="true"/>
</page>

## page1.xhtml
<html>
<h:form>
<ui:repeat var="entry"
value="#">
  <h:outputText value="|"/>
  <h:commandLink value="#{entry.description}"
action="#{entry.select}"/>
</ui:repeat>
</h:form>

<s:link view="/page2.xhtml" value="Page
2"/>
</html>

## page2.page.xml
<page>
  <description>Page 2</description>
  <begin-conversation nested="true"/>
</page>

## page2.xhtml
<html>
<h:form>
<ui:repeat var="entry"
value="#">
  <h:outputText value="|"/>
  <h:commandLink value="#{entry.description}"
action="#{entry.select}"/>
</ui:repeat>
</h:form>

<s:link value="Back to parent"
action="#{conversation.redirectToParent}"/>
</html>

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the
administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atl
assian.com/software/jira

        
_______________________________________________
jbossseam-issues mailing list
jbossseam-issueslists.jboss.org
https://lists.jboss.org/mailman/listinfo/jbossseam-issu
es

Commented: (JBSEAM-1358) conversation stack not popping properly whe
country flaguser name
United States
2007-05-27 11:57:18
    [ http://jira.jboss.com/jira/browse/JBS
EAM-1358?page=comments#action_12363284 ] 
            
Hung Tang commented on JBSEAM-1358:
-----------------------------------

I suspect that the <begin-conversation
nested="true"> is the culprit for this and it's
being read again when invoking the s:link so that's why
there's another new nested conversation started.  When this
happen, there's a duplicate entry at the top of the stack
and the redirectToParent will appear that it it didn't
redirect to anywhere.

Question is why is the page read again during an s:link?  

I think it's because I didn't specify a "view"
attribute so s:link may just re-render the same view.  I
just tried specifying a "fake" view for the s:link
in page2.xhtml and the problem seems to be fixed, but this
is a hack.  

I had opened [http://
jira.jboss.com/jira/browse/JBSEAM-1313]  for including
an additional option to s:link to
"return-to-parent".  

> conversation stack not popping properly when used with
pages.xml
>
------------------------------------------------------------
----
>
>                 Key: JBSEAM-1358
>                 URL: http://
jira.jboss.com/jira/browse/JBSEAM-1358
>             Project: JBoss Seam
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 1.3.0.ALPHA
>            Reporter: Hung Tang
>
> Assume there are two pages p1 and p2.  Entering p1 will
start a conversation c1.  p1 contains a s:link to p2, which
when clicked will start a new nested conversation c2.  In
p2, there's a s:link that goes back to p1 by invoking action
#{conversation.redirectToParent}.  
> The strange part.
> If the propagation=nested rule is specified as part of
the s:link, then the redirectToParent is working okay and
the conversationStack is consistent.
> If the propagation=nested rule is specified as part of
p2.page.xml as <begin-conversation
nested="true"/>, then the redirectToParent does
not redirect to parent, and the conversationStack reports an
additional duplicate entry for p2. 
> -- Code snippets
> ## page1.page.xml
> <page>
>   <description>Page 1</description>
>   <begin-conversation join="true"/>
> </page>
> ## page1.xhtml
> <html>
> <h:form>
> <ui:repeat var="entry"
value="#">
>   <h:outputText value="|"/>
>   <h:commandLink
value="#{entry.description}"
action="#{entry.select}"/>
> </ui:repeat>
> </h:form>
> <s:link view="/page2.xhtml"
value="Page 2"/>
> </html>
> ## page2.page.xml
> <page>
>   <description>Page 2</description>
>   <begin-conversation nested="true"/>
> </page>
> ## page2.xhtml
> <html>
> <h:form>
> <ui:repeat var="entry"
value="#">
>   <h:outputText value="|"/>
>   <h:commandLink
value="#{entry.description}"
action="#{entry.select}"/>
> </ui:repeat>
> </h:form>
> <s:link value="Back to parent"
action="#{conversation.redirectToParent}"/>
> </html>

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the
administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atl
assian.com/software/jira

        
_______________________________________________
jbossseam-issues mailing list
jbossseam-issueslists.jboss.org
https://lists.jboss.org/mailman/listinfo/jbossseam-issu
es

Closed: (JBSEAM-1358) conversation stack not popping properly when u
country flaguser name
United States
2007-05-29 18:11:12
     [ http://jira.jboss.com/jira/browse/JBSEAM-1358?page=all
]

Gavin King closed JBSEAM-1358.
------------------------------

    Resolution: Rejected

Correct, page actions ALWAYS execute on every request to the
page. (An s:link with no explicit view attribute is a
request back to the page.)

So to change this behavior, specify an explicit view on
s:link.

> conversation stack not popping properly when used with
pages.xml
>
------------------------------------------------------------
----
>
>                 Key: JBSEAM-1358
>                 URL: http://
jira.jboss.com/jira/browse/JBSEAM-1358
>             Project: JBoss Seam
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 1.3.0.ALPHA
>            Reporter: Hung Tang
>
> Assume there are two pages p1 and p2.  Entering p1 will
start a conversation c1.  p1 contains a s:link to p2, which
when clicked will start a new nested conversation c2.  In
p2, there's a s:link that goes back to p1 by invoking action
#{conversation.redirectToParent}.  
> The strange part.
> If the propagation=nested rule is specified as part of
the s:link, then the redirectToParent is working okay and
the conversationStack is consistent.
> If the propagation=nested rule is specified as part of
p2.page.xml as <begin-conversation
nested="true"/>, then the redirectToParent does
not redirect to parent, and the conversationStack reports an
additional duplicate entry for p2. 
> -- Code snippets
> ## page1.page.xml
> <page>
>   <description>Page 1</description>
>   <begin-conversation join="true"/>
> </page>
> ## page1.xhtml
> <html>
> <h:form>
> <ui:repeat var="entry"
value="#">
>   <h:outputText value="|"/>
>   <h:commandLink
value="#{entry.description}"
action="#{entry.select}"/>
> </ui:repeat>
> </h:form>
> <s:link view="/page2.xhtml"
value="Page 2"/>
> </html>
> ## page2.page.xml
> <page>
>   <description>Page 2</description>
>   <begin-conversation nested="true"/>
> </page>
> ## page2.xhtml
> <html>
> <h:form>
> <ui:repeat var="entry"
value="#">
>   <h:outputText value="|"/>
>   <h:commandLink
value="#{entry.description}"
action="#{entry.select}"/>
> </ui:repeat>
> </h:form>
> <s:link value="Back to parent"
action="#{conversation.redirectToParent}"/>
> </html>

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the
administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atl
assian.com/software/jira

        
_______________________________________________
jbossseam-issues mailing list
jbossseam-issueslists.jboss.org
https://lists.jboss.org/mailman/listinfo/jbossseam-issu
es

[1-3]

about | contact  Other archives ( Real Estate discussion Medical topics )