MSS Add-On 1.0 Tweaks – Context Menu Control in Hierarchy View
Our customer (on EHP minus 2) decided on a multi country implementation of MSS Add-on 1.0 with a unique requirement:
One Role to Rule them all: A Single portal role has to be assigned to Managers (irrespective of country) and a single role for employees across the globe. This did create some unique challenges, this series of blogs describes approaches on how to address some of the scenarios.
Organizational Chart Visualization by Nakisa was used for the Hierarchical team representation for the Team View application as shown:
The context menu formed is static and not configurable. This was not supporting the business case as applications (for e.g.: Time Request on Behalf) were not used by all reporting employees of a manager.
Some other requirements were:
- Compensation Profile should be hidden if a reporting employee belongs to Blue Collar group.
- Leave Request on Behalf of employees should be hidden if the reporting employee is belongs to a particular PSA
- Many more iterations of this nature.
WD Component HIER_VIS_UI_WRAPPER is used for hierarchy view. As overwrite of FILL_HIERARCHY_DATA Method of the Component Controller would be first step.
A break as shown below to understand how standard source builds the context menu.
In LS_HIER_DATA, BOX_DATA contains employee related info.
CONT_MENU gives you the Context Menu build. Append this on runtime based on your requirements and you have context menuy control in MSS. This can be appended in employee level as NAVBOX is bound per PERNR.
This approach is used in Hierarchy view. For GRID or LIST View, NAVBOX is not readily editable. However FILL_MENU_LIST and UPDATE_DATA method in Component controller of HRMSS_TEAM_HIERARCHY could be enhanced to achieve the functionality.
Alternate approach would be building a wrapper to achieve the same functionality.
Special thanks to Kumarpal Jain and Sriranjani Chimakurthy.