You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Peter Ertl (JIRA)" <ji...@apache.org> on 2011/09/06 22:25:10 UTC

[jira] [Commented] (WICKET-4032) ComponentStringResourceLoader must not include the index of repeater items in resource lookup but still resolve properties to them

    [ https://issues.apache.org/jira/browse/WICKET-4032?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13098321#comment-13098321 ] 

Peter Ertl commented on WICKET-4032:
------------------------------------


I added a fix that resolves a resource key against AbstractRepeater and it's associated repeater items in the same manner.

For example in the following hierarchy

MyPage
  -- MyRepeater (id = "repeater")
    -- MyRepeaterItem (id = "3")
      -- MyWebMarkupContainer (id = "container")
 
the key = 'label' resolved against base component "container" will cause a lookup in that order

- MyPage.properties with key = "repeater.container.label"
- MyRepeater.properties with key = "container.label"
- MyRepeaterItem.properties with key = "container.label"
- MyWebMarkupContainer.properties with key = "label"

Please verify the fix and let me know if something is broken or missing ...


> ComponentStringResourceLoader must not include the index of repeater items in resource lookup but still resolve properties to them
> ----------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: WICKET-4032
>                 URL: https://issues.apache.org/jira/browse/WICKET-4032
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket
>    Affects Versions: 1.4.18
>            Reporter: Nathan Messer
>            Assignee: Peter Ertl
>             Fix For: 1.4.19
>
>         Attachments: resource-lookup.zip, resource-lookup2.zip, resourceloadingissue.patch, resourceloadingissue.patch
>
>
> Issue when using a StringResourceModel to lookup a resource for a component underneath a repeating view.
> When a StringResourceModel is used by a component under a repeating view, the ComponentStringResourceLoader doesn't find the resource.
> This seems to be a problem introduced by the fix for 3671.
> In ComponentStringResourceLoader, getResourcePath excludes all AbstractRepeaters, however getComponentStack doesn't leading to the two being out of sync for the elements of the component hierarchy under the repeating view.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira