Create a top level navigation level menu and in window navigation. To recap the steps in the video:
Create in Window Navigation
- Open the
Businesses
dashboard - Open the
Contact Details
Tab - Drag the
ContactManager
dashboard onto the header of the grid viewBusiness Contacts
- a button will appear
Go into App Mode to test the new button – it will open the Contact Manager
dashboard.
Create a top level menu in your app
Now we'll create a top level menu for the application, and look at how to navigate directly to the application using the URL:
- Open the configuration form for the application
ContactManager
- Go to the section Menus, and add a new menu - You can define a number of different top level menus under an application, but in most cases you only need one.
- Set the Name of the menu to
Default
- Click add a new sub menu - this will appear in the header of the PhixFlow application
- Name:
Contacts Manager
- Display Name:
Manage
- Name:
- Save your changes
- Set the Name of the menu to
- Add a Menu Items to open the
ContactManager
dashboard:- Action:
ContactManager
- Action:
Sharing these actions between buttons and menu items is reasonably safe - all they do currently is open a dashboard, it is unlikely that someone will add a lot of extra logic to them later
Create the action
- Before adding a menu item to open the
Businesses
dashboard, you will need to add an action to do so. - Open the stream configuration form for
Businesses
- Add a new action
- Name: Open Businesses only - this is an internal name, it is useful to make this as descriptive as possible, to help keep your configuration well organised
- Display Name: Businesses - this is the name that will appear in the menu
- Action Completion:
- Tick Open Post Dashboard, then Save
- Set the Dashboard to
Businesses
- Leave the Expression blank - this means that every time the action is run, we will open this dashboard
Note: you can also set Close Parent Dashboard - this is useful in some workflows, when after moving to a new dashboard, you want to close the dashboard that the user started from; We want to open a single dashboard every time it is pressed; if we implement a workflow, we might need something more complex here, to open different dashboards depending on the data being handled
Create the menu item
- Open the menu configuration again and add a menu item to open the
Businesses
dashboard:- Name:
Businesses
- Action:
Open Businesses Only
- Name:
- Apply all changes
Switch to App Mode. Load your application by going to the PhixFlow icon in the top left hand corner of the application. Clicking the icon will give you a list of available applications - select Contact Manager
.
You will see your new menu. Check this works by going to each menu item and checking that the correct dashboard opens.
Look at the URL in your browser. You will see that PhixFlow has appended the name of the application to the base URL. It will also have added a direction to the Default top level menu.
Application URLs
You can grab this URL to share with users of the application, but you can also construct them yourself. The format is:
[base url]?application=[application name] |
In this case, something like:
https://hosted.phixflow.com/train/start.html?application=Contact Manager |
(Note that you don't need to put a direction to the Default top level menu at the end of the URL.)
Default Actions
Set the default action on the top-level menu. This action will run when the application is started, and we will use the default action to open the Businesses
dashboard when the application starts:
- Open the top level menu
- Set the Default Action to be
Open Businesses Only
- Save your changes
Refresh the browser page to restart the application - you will see that the Businesses
dashboard opens straight away.
Next video: 12. Validate Input