Privileged Navigation

As with most every database solution, one of your primary goals is to facilitate easy navigation. You want users to be able to get to where they wish to go without hassle. You also want relevant navigation based on the fact that a database isn't just a one-trick pony. A lot of software tends to focus on one singular thing. However, in many database systems you may be catering to wider range of users.

This is where it becomes helpful to have a navigational method which is not only flexible, but easy to maintain. Using a portal to accomplish this is an obvious solution. But what about making the portal vary the navigational options based on the logged in user?

This can be done when you marry FileMaker's native security controls with the values shown within a portal. In this video, we walk through a "build it with me" approach to implementing this exact feature. Setting up a navigational sidebar menu system which responds to the user who's logged in. This system can either be a bit more general or as granular as desired.

AttachmentSize
PrivilegedNavigation.zip1.74 MB

Comments

Hi, very interesting, there's a way to highlight the portal row (menu) referring to the active layout?
Thanks,

--
Mirco

There are a number of ways to do this; they all involve conditional formatting on the button (or button bar) object in the portal.

One way is to store the layout name in a field in the Menu table; compare the result of Get ( LayoutName ) to the value in the menu record. You could also use more of the custom functions mentioned by Matt since the principle is the same: use the design functions to list the LayoutIDs and the LayoutNames, then cross-reference the position in each list - store the layout ID in the menu table rather than the layout name.

Or you could modify the Menu Dispatch script to simply put the name of the menu item in a global variable (e.g. $$currentMenuChoice) and have your conditional formatting check that.

--
Daniel Farnan

Ignorance is curable, not preventable

You can use the pilcrow character in the text of the button label and FileMaker will render it correctly, e.g. ButtonText¶SecondLine

--
Daniel Farnan

Ignorance is curable, not preventable

This is an area where it's probably better to switch this to a button that shows a card window. The window displays a list view layout of the menu table, which means that your navigation object (the button, and not a portal) becomes context-independent.

The portal setup requires either a cross-join to the GLOBALS table from every "anchor" TO - in which case you have a cross-join between EVERY anchor TO in your solution, which will have a serious impact on performance - OR a separate instance of the GLOBALS and Menu TO group attached to the anchor TO, in which case you have to modify the portal object and every contained object to make sure the correct TO is being referenced, which makes development extremely painful.

Compare that to the cost of the user making an extra click to display the menu navigation system and then decide on your approach.

--
Daniel Farnan

Ignorance is curable, not preventable