HI If this question has been asked, please refer me. Thanks in advance I am currently using Struts2 with Spring. Basically I have struts action backed by "Service" and "DAO" injected by Spring.
I may be getting a java entity from the Service, for example a "Product". And the product object has attributes of english_name and french_name. I want to show one of the name depending on the language version user chose to view my pages. For example: I have Product.java String english_name String french_name ...setter getter.... Action.java Product product ...setter getter.... The problem is what is the best practice to show the attribute of product name depending on the language(locale) chosen? I know that for texts I can use getText or <s:text/> but how do I do it for java entities? I cant do something like <s:property value="product.%{text('productName')}" and in my properties productName=english_name right? and this doesnt look right Any suggestions? Thanks