You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by ayman elwany <ay...@gmail.com> on 2010/03/24 14:26:08 UTC
Feedback panel -- message resource bundle
Hi all,
I update my feedback panel messages using "wicketApplication.properties"
and attach the message to the component path :
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
EXAMPLE :
Required=${label}
MinimumValidator=${label}
distributorForm.autoCompletePanel.borderOne.autoOne.Required=Do Not Submit
Claim Without this field.
distributorForm.autoCompletePanel.borderOne.autoOne.MinimumValidator=value
must be > 0.
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
I have 2 problems with this approach :
1- Difficulty in reusing messages : ex. If I I want to reuse the the same
validator message MinimumValidator in other 3 components I 'll have to copy
it 3 times for the other 3 compnents.
2- Message Resource keys :
a- more suitable and short keys instead of using component path
as a key
b- Reusing this key in any component in any other component in any
page
Any help????
Re: Feedback panel -- message resource bundle
Posted by ayman elwany <ay...@gmail.com>.
Any another approach that's help me to to use resources key instead of
companent path key ????
On Wed, Mar 24, 2010 at 3:26 PM, ayman elwany <ay...@gmail.com> wrote:
> Hi all,
>
> I update my feedback panel messages using "wicketApplication.properties"
> and attach the message to the component path :
>
>
> ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
> EXAMPLE :
>
> Required=${label}
> MinimumValidator=${label}
> distributorForm.autoCompletePanel.borderOne.autoOne.Required=Do Not
> Submit Claim Without this field.
> distributorForm.autoCompletePanel.borderOne.autoOne.MinimumValidator=value
> must be > 0.
>
>
> ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> I have 2 problems with this approach :
>
> 1- Difficulty in reusing messages : ex. If I I want to reuse the the
> same validator message MinimumValidator in other 3 components I 'll have to
> copy it 3 times for the other 3 compnents.
>
> 2- Message Resource keys :
>
> a- more suitable and short keys instead of using component path
> as a key
> b- Reusing this key in any component in any other component in
> any page
>
>
> Any help????
>
>
>