This content has been marked as final.
Show 2 replies
-
1. Re: creating Edit forms for transaltable entities - and kee
marius.oancea Oct 15, 2007 5:52 AM (in response to marius.oancea)Ad schematics:
Word Translation ==== ========== name : Translation --------------> language: String text: String
I replace the ascii art with some code. I think is better:@Entity @Name("word") public class Word { Set<Translation> name = new HashSet<Translation>(); // maybe better use a Map because for each language we have one name. // setters and getters } @Entity public class Translation { String languageStr; String text; // setters and getters }
Please ignore the missing identifiers but are not relevant. -
2. Re: creating Edit forms for transaltable entities - and kee
pmuir Oct 16, 2007 11:33 AM (in response to marius.oancea)Make it a map and do #{word.name[language]} where language is a variable that is scoped to longer than the request and so available when restoring the view.