I got view like this
<?xml version="1.0" encoding="UTF-8"?>
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
<S:Body>
<ns2:${servicename}Response xmlns:ns2="http://ws/">
<g:each in="${result}" var="record">
<return>
<g:each in="${parameters}" var="parameter">
<${parameter.name}>${record[parameter.name]}</${parameter.name}>
</g:each>
</return>
</g:each>
</ns2:${servicename}Response>
</S:Body>
</S:Envelope>
And it renders like this:
<?xml version="1.0" encoding="UTF-8"?>
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
<S:Body>
<ns2:${servicename}Response xmlns:ns2="http://ws/">
<return>
<column1>updated</column1>
<column2>update</column2>
<id>1</id>
</return>
</ns2:${servicename}Response>
</S:Body>
</S:Envelope>
as you can see, servicename variable is not replaced inside of element name with namespace. i tried to hack it several ways like passing the whole ns:servicename as variable, but nothing helped, there were always some undesirable side effects. How can i do this? i just want to replace the variable without additional validation/processing...
<?xml version="1.0" encoding="UTF-8"?>
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
<S:Body>
<%= """<ns2:${servicename}Response xmlns:ns2="http://ws/">""" %>
<g:each in="${result}" var="record">
<return>
<g:each in="${parameters}" var="parameter">
<${parameter.name}>${record[parameter.name]}</${parameter.name}>
</g:each>
</return>
</g:each>
<%= """</ns2:${servicename}Response>""" %>
</S:Body>
</S:Envelope>