jsf 2 - JSF localization of dynamic expressions -



jsf 2 - JSF localization of dynamic expressions -

this question has reply here:

string concatenation in el dynamic resourcebundle key 3 answers

i have bean status field can take 1 of 3 predefined values: active, blocked, deleted. each of those, defined label in properties file:

entity.status.active=active entity.status.blocked=blocked entity.status.deleted=deleted

is there way of displaying entity's status' label? more exactly, there way of combining static 'entity.status.' string dynamic status value key resource bundle? saw this question, doesn't reply needs completely

thanks.

you can utilize concat function this:

#{myresourcebundle['entity.statut.'.concat(mybean.status)]}

jsf jsf-2

Comments

Popular posts from this blog

c - Compilation of a code: unkown type name string -

java - Bypassing "final local variable defined in an enclosing type" -

json - Hibernate and Jackson (java.lang.IllegalStateException: Cannot call sendError() after the response has been committed) -