I have an application with numerous Controllers. Of those, I have one that I want Update only capability, no Add and Delete functions. I've added the redirects to the class Controller for the Create and Delete, but I want to prevent the Delete and Add buttons from appearing on the different views; list, show, edit. I need full CRUD capabilities for the other classes in my application so I want the Add and Delete buttons to appear for all of the other classes in my application.
I tried editing the list.gsp with:
<g:if test="${className != 'MyUpdateOnlyClass'}">
<span class="menuButton"><g:link class="create" action="create">New ${className}</g:link></span>
</g:if>
But the "New MyUpdateOnlyClass" button still shows in the navigation bar at the top of the list page.
Any suggestions for removing the Add and delete buttons from the various views?