I want to render same template on one page which should display the value depending on the param value(3 or 4).
View is —
<td >
<g:render template="gdxqStatusTemplate" model="[param:3]" /> </td>
</td>
<td> </td>
<td >
<g:render template="gdxqStatusTemplate" model="[param:4]" /> </td>
</td>
Controller has –
[ total3:totalValue3,total4:totalValue4]
how to show the appropriate value of total in template code –
<table >
<tr ><td class="InputText" nowrap><b> MessageQ Status,/td>
<tr> <td class="NoLight" nowrap>Total MessageQ : ${total+params}***/* IT SHOWS "total4" NOT THE VALUE.*/***
</td></tr>
<tr height=30></tr>
</table>
Yo must change:
By
And in your template replace:
By:
For documentation check: http://grails.org/doc/2.0.x/ref/Tags/render.html