Message Boards

« Back to 2.- Usage ( From Xml file to CRUD Portlet)

English language properties suggestions

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
English language properties suggestions
Answer
8/16/12 10:14 PM
Hi Jack,

I'm attaching an updated Portlet_Language_en_properties.vm with a few corrections.

Hope I'm not being a pest. emoticon

- Deb
Attachments: Portlet_Language_en_properties.vm (4.0k)

RE: English language properties suggestions
Answer
8/17/12 1:02 AM as a reply to Deb Troxel.
After looking at the language properties some more, I propose that the messages that are not dependent on the table currently being processed be moved out of the foreach applications loop. These entries get written into the file over and over for each table. It doesn't hurt, but it makes the file messy when there are multiple tables. I'm attaching another updated properties.vm so you can see what I mean. This change could be applied to all the language properties templates. (Let me know if you would like me to contribute those edits.)

I also notice inconsistencies with the generated language key, where the lookup key doesn't match the property name. This is probably because my class name is different from my file name (I used mixed case for the class and all lower case for the table name.) For example, a quick search for the ..."-added-successfully" message in the generated code shows a couple instances that use the File name and one that uses the Class instance name. (Portlet_editXXXXXX_jsp.vm is the one that doesn't match the others.) On the other hand, Portlet_XXXXXXValidator_java.vm uses the FileDef name when adding errors, but the language properties uses the ClassDef name when defining the field error keys.

I'm willing to help track these down in detail if you want. Let me know.

n the meantime, I will just regenerate my portlets using matching class and table names.

- Deb
Attachments: Portlet_Language_en_properties.vm (4.0k)

RE: English language properties suggestions
Answer
8/17/12 8:01 AM as a reply to Deb Troxel.
Hola Deb,


This is great!!!, I will change also all other language files, they all have the same structure, and syntax. A few versions before, it was a must, to match file names and class names. This changed, it was a big number of lines modified in the conversion, and seems some references were left behind unchanged.

Please, please, please, emoticon if you can track them down, it will be of great help.


Thank you very much for your collaborations, Jack.

RE: English language properties suggestions
Answer
8/17/12 8:56 AM as a reply to Deb Troxel.
Thanks for your contributions Deb!