Letractively / jcatapult

Automatically exported from code.google.com/p/jcatapult
0 stars 0 forks source link

JCatapult MVC localization doesn't work well with arrays #82

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
The JCatapult MVC allows you to have multiple input fields that populate
objects in an array like this:

[@jc.text name="array[0].value"/]

This can also be used in a loop and with DHTML to dynamically add new
fields on the fly or populate as many fields as there are in a database
(for example). Currently, everything MUST be localized using the name of
the input field. This would require the ResourceBundle to look like this:

array[0].value=Value
array[1].value=Value
array[2].value=Value
...

This will become very cumbersome for large arrays.

I think we should add a new localization attribute to the tags that
overrides this behavior. Something like this should work:

[@jc.text name="array[0].value] labelKey="array.value"/]

And then the ResourceBundle will look like:

array.value=Value

Original issue reported on code.google.com by bpontare...@gmail.com on 29 Aug 2008 at 4:29

GoogleCodeExporter commented 8 years ago
Added support for labelKey attribute.

Original comment by bpontare...@gmail.com on 30 Aug 2008 at 8:08