|
|
Hi all,
I'm having problem passing a variable from a custom tag library to a template view:
Tag:
def showBasketItem = { attrs, body ->
log.debug "ATTRS = ${attrs.lineItem}"
def journeyCode = attrs.lineItem.productType.toString().toLowerCase()
render(template:"/${journeyCode}/basketItem", model:"[lineItem:attrs.lineItem]")
}
log output is fine...
Template:
<g:set var="accom" value="${lineItem.accommodation}"/>
I get a null pointer when trying to call the accommodation property on lineItem.
Any ideas?
Martin
Grails version: 1.0.2
Groovy version 1.6 beta 1
|