Click here to access the legacy version of this documentation.
This documentation will cover how to create and manage menu options within m-Power. The menu feature gives users a centralized location to find all the new applications you’ve created. Further, it is very simple to add/change menu options based on a User’s Role.
Please see the video below to get an overview of what the menuing system is, its benefits, and how to maximize its flexibility:
To begin, click on the “Admin Menu” button, then the “Application Menu & Security” button
Your screen should now look like the below. If it does not, please click here to learn how to upgrade your existing menu to this version.
The m-Power menu process is broken down into several key areas:
• Users – A list of users who are authorized to see elements on the menu
• Roles – A role is a group, to which users can belong. This role is then assigned specific applications that it can view within the menu. Users can belong to multiple roles
• Menu Options – These are links that end-users can access at runtime to access their applications.
• Menu Groups – m-Power menus support Major, Minor, and Sub-Minor Groups. These groups can be defined, ordered, and set up hierarchically to control which groups are owned by other groups
• Manage Application Security – This option lets you control which users (via their roles) shall be allowed to access which applications.
To add a user, click the “Manage Runtime Users” button. Then enter the user’s username. This is the only required field on the page. However, if you are securing by database table, you will want to enter the password here. The first name, last name, and email are not currently used but can be entered for your own reference.
Menuing is not controlled directly by user, instead it is dictated by a user’s role. Via the user update screen, you can select a user’s role from the dropdown of existing roles (Roles can be created on the Manage Roles screen, via the “Create Role” button).
Again, users can have an unlimited number of roles.
If you are configuring a Dictionary that will not utilize security, be sure to create a single user. You do not need to explicitly define a role for that user since this generic user will automatically belong to the “All Users” role.
Managing Runtime Roles
Once you’ve created your user, you can navigate to the User Roles screen.
On this screen, you will see a list of all of your existing roles, plus the “All Users” role. This role is automatically defaulted into your environment. All users are automatically entered into this group.
This screen gives you the ability to quickly assign several components to a group, including: users, menu options and security rules via the provided dropdown boxes. Navigate to the applicable tab to assign the selected element to this role. When completed, press "Save Role."
As a note, roles that have dependencies cannot be deleted. The system will alert you to this in the event you try to delete one with dependent users, menu options or security rules.
Roles can also have children assigned to them. As an example, lets say there are 3 roles: A, B, and C.
Let's also assume:
• Role A has a child of Role B
• Role B has a child of Role C
Users who have Role A assigned to them will automatically see applications in Roles A, B, and C.
Users who are assigned to Role B will see applications in Role B and Role C.
Users who belong to Role C will see only the role options for Role C.
This hierarchy will greatly enhance the efficiency of adding applications in a corporate environment where there is a defined employee structure.
There is a practical limit on the number of child roles that can be defined to a single parent. mrc recommends you do not exceed 25 child assigned to a single parent.
Manage Menu Options
Navigating to the Manage Menu Options screen, shows a list of all applications that have been defined for this Dictionary’s menu. If an application is not on this list, it cannot be displayed on the menu.
Click Create Menu Option…
If adding an m-Power app, use one of the 4 blue buttons to choose your app from the list. If you are adding a menu option outside of the current Dictionary, enter a unique Option ID. The other options available are broken down below:
• Description (Required) – This will be the text your end user sees that will make up the menu link
• Sequence # — Respective of it’s group, applications will display in numeric order of their sequence number. Applications with the same sequence number will be listed alphabetically.
• Title – Any text entered here will be displayed as title text for your end user when they hover their cursor over the link.
• Font Awesome Icon – Add a small icon to the left of text based menu. Click the “?” icon to pick from available options.
• Alternate Link Text – Only used on the Menu Card option, will serve as the action link
• URL (Required) – Controls where the user is directed after executing the link. This can be relative or static.
• Long Description – Used only in the Card Menu and replaces the description
• Group – Menu Options typically live in groups. Options include Major, Minor, and Sub-Minor Groups. Groups will be covered in more detail in the next section.
• Image URL – If you prefer to use your own menu icon, you can include it here. The image will be placed to the left of the link.
• Class – Any text entered will be automatically applied to link/anchor tag, allowing you to control the CSS styling.
• Roles – For a link to appear on the menu, a role must be given access to this option. More than one role can be defined per menu option. All users of the role provided will have access to see this menu option. Developers can choose an existing role or create a new one. Alternatively, developers can choose to assign roles on the “Manage Roles” screen
Once completed, press “Add Menu Option and Return to Manage Menu Options”
Manage Menu Groups
Menu Groups allow you to control Major, Minor, and Sub-Minor Groups. Here is an example of a menu with each:
Notice that the major groups are listed as tabs across the top of the page. Minor groups are listed on the left-hand side as buttons, and sub-minor groups are listed as column headings.
To manage these groups, click on the “Manage Menu Groups” button, then add or edit a group.
Group indicates the name of the group. This will be seen by your end-user
Group Type – Select if you would like to create a Major, Minor, or Sub-Minor Group.
If you’ve selected a Minor or Sub-Minor, you can specify who its parent it.
Lastly, the order allows you to control the order of this group, relative to its peers. In the event that two groups of the same type share the same order, the group will be ordered alphabetically.
Upgrading to this Menu option
-Log onto m-Power server and navigate to /mrc/development/m-power/mrcjava/WEB-INF/classes/DATADICTIONARY/. Look for all mrcmenu* files and delete them.
Then, back in your internet browser, within m-Power, click Admin Menu -> Legacy Admin -> Users Menu & Security.
This will create all the new menu files as well as convert over your existing data.
When the interface looks like this, you will have your visual confirmation that menu has been upgraded:
Manage Application Security
This step is optional and only used if you need to restrict application access for certain roles. To do so, click the "Secure New Application" button from within the "Manage Application Security" screen. Here specify which role should have access to which application.
More information about this feature can be found here.
The menu system allows for two different types of menu options:
Standard Link Based Menu – This option is largely explained above as it is the default option. The output of this option looks like the following:
The alternative menu design available to you is the Card Based Menu. Its output looks like this:
To configure which output is displayed, go to Admin Menu -> Edit Dictionary Files -> Servlet Properties.
**Changing this property requires that Tomcat is restarted
Note: You can change the height of the card via Admin Menu -> Edit Dictionary Files -> mrc Menu. Then click "Switch" and select "mrcmenu-card-layout.html." The height of the card can be controlled in the 1st line of code.
Developers also have the ability to customize the navigation bar menu. Valid choices are the Header Tree Menu and the Header Mega Menu:
An Example of the Header Tree Menu would be:
Notice that in the above example, the user would have to hover on each parent element to view its child element. “Web Apps” is the parent element, where “Reports” is the Minor Group, “Finance” is the Sub-Minor Group, and YTD Report & Year End Report are the specific Menu links.
The alternative option for the navigation menu would be the Header Mega Menu. An example of this can be found below:
In this case, “Web Apps” is the Major Group, “Reports” and “Retrievals” are the Minor Groups. Then, every other option is a valid link.
This option is particularly useful for customers who would like to see all of their menu options under a single Major group at one time.
The Header Mega Menu is not compatible with Sub-Minor Groups. Any menu option that has a parent of a Sub-Minor Group will be omitted from the menu.
**Any changes to the servlet properties file will require Tomcat to be restarted
Click here to learn how to promote Menu data to a separate production database.