Description
I'll have a go at creating a pluggable interface for vetoing menu items and produce an implementation which can veto based on Group membership.
Gary
--On 17 October 2007 14:48 -0500 Tom Barton <tbarton@uchicago.edu> wrote:
> On the call today I took an AI to dig out Gary's suggested approach for a
> work around to deploy at Duke to prevent the UI from letting TAadmins
> choose a path through the UI that is frustratingly slow, ie, to
> selectively disable the Manage Groups task. Hre's the gist of what Gary
> wrote.
>
> This idea will need to be elaborated into an actual code change so that
> it can be evaluated for suitability. Shilen, is that up your alley, or is
> that more yours, Gary?
>
> Tom
>
> on 7/14/2007 Gary wrote:
> > [AI]
will share an email with the list giving an idea of how to
> > modify menu items based on who you are and which groups you belong to.
>
> The UI customisation guide on the Wiki gives an overview:
> <https://wiki.internet2.edu/confluence/display/GrouperWG/Customizing+the+
> Grouper+UI+v1.0#CustomizingtheGrouperUIv1.0-menu> however, the url will
> change with the official release of Version 1.2.
>
> Basically, subclass PrepareMenuAction and override the method:
>
> protected boolean isValidMenuItem(Map item,GrouperSession
> grouperSession,HttpServletRequest request)
>
> - put your logic first but if not returning false, delegate to the super
> class.
>
> In order to have the UI use the PrepareMenuAction subclass you must
> override / replace the prepareMenu.do action config in struts-config.xml.