I created a mvc-portlet
module in Liferay 7.x, that has 2 portlets, test and test2. Each portlet has its own Language.porperties
. Each property is its subfolder
resources/content/test/Language.properties
and
resources/content/test2/Language.properties.
In the portlet compoent properties I have
"javax.portlet.resource-bundle=content.test.Language"
and
"javax.portlet.resource-bundle=content.test2.Language"
but the default values (for the mvc-portlet
template) for the keys won’t load. What am I doing wrong here?
You can find some sample code here: https://github.com/charalamposc/liferay-literals
So, I found a solution (don’t know if it's the best - but it works). I implemented two resource bundle loaders (https://help.liferay.com/hc/en-us/articles/360029317371-Resource-Bundle-Override), one for every resource. It seems, it adds an additional resource bundle to the module components.