Shortcut Technical Reference
Summary
- Shortcuts are defined in Shortcut State
- programmatic access to Shortcuts is through Shortcut API
Shortcut State
The Shortcut section of Initial Adaptable State contains a single collection of Shortcut objects:
| Property | Description |
|---|---|
| Shortcuts | Collection of Shortcuts - designed to speed up data entry |
Shortcut Object
The Shortcut object contains 4 mandatory properties:
| Property | Description |
|---|---|
| Name | Name of the Shortcut |
| Scope | Numeric Columns where Shortcut is applied |
| ShortcutKey | Key which triggers the Shortcut when pressed |
| ShortcutOperation | The Operation: 'Add', 'Subtract', 'Multiply', 'Divide' |
| ShortcutValue | Value acting as 2nd operand for ShortcutOperation (1st operand is the cell value) |
| IsReadOnly | Sets Entity to ReadOnly (overwriting a Strategy Entitlement of 'Full') |
| IsSuspended | Suspends (i.e. turns off) an Adaptable Object |
Shortcut API
The Shortcut API section of Adaptable API contains many Shortcut-related methods including enabling fetching, creating, editing, deleting and suspending Shortcuts.
| Method | Description |
|---|---|
| addShortcut(shortcut) | Adds new Shortcut to the state |
| deleteShortcut(shortcut) | Deletes Shortcut from the state |
| editShortcut(shortcut) | Edits Shortcut in state |
| getActiveShortcuts(config) | Gets all active (not-suspended) Shortcuts in Adaptable State |
| getShortcutById(id, config) | Retrieves Shortcut by Id |
| getShortcutByName(name) | Retrieves a Shortcut by its Name |
| getShortcuts(config) | Gets all Shortcuts in Adaptable State |
| getShortcutState() | Retrieves Shortcut section from Adaptable State |
| getSuspendedShortcuts(config) | Gets all suspended Shortcuts in Adaptable State |
| openShortcutSettingsPanel() | Opens Settings Panel with Shortcut section selected and visible |
| suspendAllShortcut() | Suspends all Shortcuts |
| suspendShortcut(shortcut) | Suspends Shortcut definition |
| unSuspendAllShortcut() | Activates all suspended Shortcut |
| unSuspendShortcut(shortcut) | Activates a suspended Shortcut definition |