Control webapps STORE AND OMS UI by using roles and action in manifest
How-to Guide
Author:
Fluent Commerce
Changed on:
14 Sept 2023
Key Points
- describes how to set up the user to see the “query” only page or “edit” entity page by using User Roles and UserAction in Manifest.
- The below example demonstrates where "Finance" users in "query" only mode on OMS data and "CustomerService" cancel orders and other user actions.
Steps
Create a new user Finance and assign to ROLE: FINANCE_USERS role

Create a new user Customer Service and assigned to ROLE: CUSTOMER_SERVICE_USERS role

In my app reference setting (fc.mystique.manifest.oms3), include 2 fragment manifests, finance and customer service

In the customer service fragment manifest setting, apply CUSTOMER_SERVICE_USER into the roles:

For each page that requires user action, set the action:TRUE:

Login in as customer service user:

The user will only see the screens with roles include CUSTOMER_SERVICE_USER:

In the order page, the user action buttons are showing for customer service user

For finance manifest fragment, include the ROLES: FINANCE_USER

In this fragment, ensure all action is FALSE as the finance user is read only.

Login as finance user:

Only manifest fragment with role FINANCE_USER are displayed:

In the order detail screen, there are no user action buttons:

Result
By using User Roles and Manifest action:TRUE/FALSE, we can control user visibility.