You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Prakash Udupa (JIRA)" <de...@myfaces.apache.org> on 2014/02/18 21:22:20 UTC

[jira] [Updated] (TRINIDAD-2453) MoveChildComponentChange fails to apply document change for relocated component case

     [ https://issues.apache.org/jira/browse/TRINIDAD-2453?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Prakash Udupa updated TRINIDAD-2453:
------------------------------------

    Status: Patch Available  (was: Open)

> MoveChildComponentChange fails to apply document change for relocated component case
> ------------------------------------------------------------------------------------
>
>                 Key: TRINIDAD-2453
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-2453
>             Project: MyFaces Trinidad
>          Issue Type: Bug
>    Affects Versions: 2.1.0-core
>            Reporter: Prakash Udupa
>         Attachments: TRINIDAD-2453_over_trunk.patch
>
>   Original Estimate: 48h
>  Remaining Estimate: 48h
>
> MoveChildComponentChange has documentation that all participants in the move (child to move, the new parent at destination, common parent to both of these) should belong to the same document.
> This is failing in relocated components usecase when the first two components are in the same document, and when a common parent can be found in the same document.
> For example consider this case:
> Template definition for template1 is as follows:
> <commonParent2>
>   <facet1-reference/> <!-- facet1 contents from the base page will be relocated here -->
>   <facet2-reference/> <!-- facet2 contents from the base page will be relocated here -->
> <commonParent2>
> Base Page (uses template1) definition is as follows:
> <commonParent1>
>   <template1> <!-- UIXInclude component -->
>     <facet1>
>       <componentToMove/>
>     </facet1>
>     <facet2>
>       <destinationContainer/>
>     </facet2>
>   </template1>
> </commonParent2>
> In this case the "componentToMove" and "destinationContainer" are defined in the same document (Base Page), and the implementation in MoveChildComponentChange can easily record "commonParent1" as the common ancestor in which case all three participants belong to the same document and so the move document change should be successful. Instead the issue is that the implementation considers "commonParent2" as the common ancestor, this component belongs to a different document (template1), and results in the Move document change failing.
> I'll upload a patch that fixes this issue, and also cleans up the code in MoveChildComponentChange to improve readability and make it easy to understand.



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

[Commit Request] (TRINIDAD-2453) MoveChildComponentChange fails to apply document change for relocated component case

Posted by Prakash Udupa <pr...@oracle.com>.
Hi,

I uploaded "TRINIDAD-2453_over_trunk.patch", this is the patch file over Trinidad trunk for this issue. One of the 
developers with write permission, please commit this patch.

https://issues.apache.org/jira/browse/TRINIDAD-2453

Thanks,
Prakash


-------- Original Message --------
Subject: 	[jira] [Updated] (TRINIDAD-2453) MoveChildComponentChange fails to apply document change for relocated 
component case
Date: 	Tue, 18 Feb 2014 20:22:20 +0000 (UTC)
From: 	Prakash Udupa (JIRA) <de...@myfaces.apache.org>
Reply-To: 	MyFaces Development <de...@myfaces.apache.org>
To: 	dev@myfaces.apache.org



      [ https://issues.apache.org/jira/browse/TRINIDAD-2453?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Prakash Udupa updated TRINIDAD-2453:
------------------------------------

     Status: Patch Available  (was: Open)

> MoveChildComponentChange fails to apply document change for relocated component case
> ------------------------------------------------------------------------------------
>
>                 Key: TRINIDAD-2453
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-2453
>             Project: MyFaces Trinidad
>          Issue Type: Bug
>    Affects Versions: 2.1.0-core
>            Reporter: Prakash Udupa
>         Attachments: TRINIDAD-2453_over_trunk.patch
>
>   Original Estimate: 48h
>  Remaining Estimate: 48h
>
> MoveChildComponentChange has documentation that all participants in the move (child to move, the new parent at destination, common parent to both of these) should belong to the same document.
> This is failing in relocated components usecase when the first two components are in the same document, and when a common parent can be found in the same document.
> For example consider this case:
> Template definition for template1 is as follows:
> <commonParent2>
>   <facet1-reference/> <!-- facet1 contents from the base page will be relocated here -->
>   <facet2-reference/> <!-- facet2 contents from the base page will be relocated here -->
> <commonParent2>
> Base Page (uses template1) definition is as follows:
> <commonParent1>
>   <template1> <!-- UIXInclude component -->
>     <facet1>
>       <componentToMove/>
>     </facet1>
>     <facet2>
>       <destinationContainer/>
>     </facet2>
>   </template1>
> </commonParent2>
> In this case the "componentToMove" and "destinationContainer" are defined in the same document (Base Page), and the implementation in MoveChildComponentChange can easily record "commonParent1" as the common ancestor in which case all three participants belong to the same document and so the move document change should be successful. Instead the issue is that the implementation considers "commonParent2" as the common ancestor, this component belongs to a different document (template1), and results in the Move document change failing.
> I'll upload a patch that fixes this issue, and also cleans up the code in MoveChildComponentChange to improve readability and make it easy to understand.



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)