-
-
Notifications
You must be signed in to change notification settings - Fork 967
Description
Steps to Reproduce
Url mapping is:
"/admin/$controller/$action?/$id?(.$format)?"(namespace:"admin")
When g:link tag is used without a controller name, it intelligently findsout the name of current controller and does the proper reverse url mapping.
But when the controller is in a namespace, and no namespace is specified in the g:link tag, it will generate wrong urls and will not consider namespace for reverse url mapping:
So, for the url mapping example given above:
If i do <g:link action="create" class="btn btn-primary btn-xs">create</g:link>
And the current controller is PageController, which is in namespace admin. The generated url will be page/create and not admin/page/create
Expected Behaviour
Just like how link tag automatically figureout the controller name, it should also check if the controller is in a namespace, and automatically apply the proper reverse url mapping if there's a namespaced url mapping.
- Grails Version: 3.0.11