Grials newbie - my boilerplate, generated view code is returning null when trying to resolve the entityName argument passed to the g:message tag. So...
<g:message code="default.show.label" args="[entityName]" />
renders as "Show null" instead of "Show [the domain class name]"
Any idea what may be going on here, or suggestions on how to diagnose this? I have been making incremental changes to both the views and the domain classes but wouldn't expect this to have made any difference
entityName is a variable and set by the set tag lib, which must placed before the message tags using this variable. e.g.
// first define the entity name var
<g:set var="entityName" value="${message(code: 'test', default: 'TEST')}"/>
// display msg
<g:message code="default.show.label" args="[entityName]" />
maybe you forget to define this var or accidentally deleted this line of code.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With