Setting Entitlements in AdapTable
Summary
- AdapTable provides advanced permissioning capability via Entitlements
- Entitlements can be provided in 2 ways:
- as a 'hard-coded list'
- via a function
- Every Module in AdapTable can be given one of 3 Access Levels:
ReadOnlyHiddenFull
- Additionally a different Default Entitlement level can be specified in preference to the default value of
Full - The Entitlement applies to all objects in the Module - but this can be overridden on a per-object basis
AdapTable uses Entitlements to manage permissions in the AdapTable UI.
Entitlements ensure runtime-users can only view or edit relevant Modules and Adaptable Objects.
Access Levels
Each Module has an AccessLevel that can be one of 3 values:
FullReadOnlyHidden
Hidden Access Level
With the Hidden Access Level, all UI elements connected to the Module are hidden from the user.
The Module in question never appears in any of the UI components that AdapTable provides:
Full Access Level
With the Full Access Level, the Module is always visible and editable, and can be accessed in all AdapTable's UI components.
Everything can be done by the user - creating, editing, sharing, suspending and deleting objects as required.
Note
- Object-level Entitlements take precedence over Module Entitlements
- This means that a
ReadOnlyobject cannot be edited in a Module with aFullAccess Level
ReadOnly Access Level
The ReadOnly Access Level displays the Module but restricts some actions.
The ReadOnly behaviour for an Entitlement differs by Module and use case.
As a general rule, if the Module performs an action but does not contain an object (e.g. Smart Edit, Bulk Update or Cell Summary) the ReadOnly behaviour is identical to that as for Hidden.
However, if the Module contains a collection of Adaptable Objects (e.g. Format Columns, or Custom Sorts), these objects are active - and viewable by the run-time user - but they cannot be edited, deleted or suspended; nor can new objects be created.
Hint
- The
ReadOnlyEntitlement allows users to select pre-existing Adaptable Objects (e.g. Layouts or Reports) - But simultaneously it prevents them from editing them or creating new ones
Find Out More
- The
ReadOnlyEntitlement behaviour can include some special use cases that are worth noting - Consult Modules Entitlements ReadOnly Behaviour for full details of what
ReadOnlymeans for each Module
Object Entitlements
Sometimes setting a Module level restriction of Entitlements is insufficient.
For instance, a user might require a Module to have a Full entitlement (i.e. it's editable) but one particular Object should be ReadOnly (i.e. cannot be deleted).
For these use cases Object Entitlements can be set which will override the Module's Entitlement.
Additional Entitlement Rules
For some AdapTable Modules providing an Entitlement of Full or ReadOnly is insufficient to ensure availability.
Additional configuration settings are required - supplied typically in Adaptable Options.
Find Out More
See Additional Module Entitlement Rules for the full list of rules and exceptions
UI Constructs
Entitlements are UI constructs only - AdapTable guarantees that end users will not see, in the AdapTable UI, elements like menus, toolbars, settings screens etc. related to Modules to which they are not entitled.
Caution
Objects provided in Initial Adaptable State or accessed via Adaptable API bypass Entitlements entirely
Hint
To ensure that the Adaptable Api is not called for functions with an Entitlement of Hidden, wrap your api call in the getEntitlementAccessLevelForModule function in Entitlement API:
if (entitlementApi.getEntitlementAccessLevelForModule('Layout')=='Full'){
layoutApi.doSomething....
}Configuring Entitlements
Developers are able to configure 2 Entitlement-related properties in Entitlement Options.
Note
- In both cases the property can be provided in one of 2 ways:
- with a 'hard-coded' list, or via a function invoked by AdapTable as required
Setting Default Entitlement
Developers can set the Default Access Level for all Entitlements.
Caution
If this is not provided, then Adaptable's default value of Full will be used
For instance a Hidden setting will remove all Modules, and only those explicity permissioned will be available.
Providing Module Entitlements
Developers can explicitly set the AccessLevel for each Module in AdapTable.
This is set by the moduleEntitlements property of Entitlement Options.
Note
Any Module not given an explicit Entitlement will use that provided by defaultAccessLevel
Find Out More
- See Module Entitlements for full details on how to set Entitlements
Permissions in AdapTable
FAQ
Can I hide all Modules and only choose the ones my users can see?
Yes, set the defaultAccessLevel property in Entitlement Options to Hidden