System Status

The System Status function keeps run-time users dynamically updated with information about their application.

A StatusMessage is displayed to the user. It is associated with a StatusType that has a default colour (though this can be changed through CSS Variables when creating a custom theme).

Additionally Default Status Message and Type can be provided, to be displayed when there is no 'active' message.

Status Types

Each message is associated with a StatusType that has a default colour.

tip

The colours used for each Status Type can be changed through CSS Variables using a Custom Theme

The 4 Status Types and their associated default colours are:

  • Info (Blue)

  • Success (Green)

  • Warning (Amber)

  • Error (Red)

Displaying System Status Message

The System Status message (or Default message) can be displayed in 5 ways:

  • As an Alert (which will popup and also appear in the Alert Toolbar and ToolPanel)

  • Via the SystemStatus Function Button in the Dashbhoard which shows an icon appropriate to the Message Type and opens the System Status Popup.

  • In the System Status Toolbar

  • In the System Status ToolPanel

  • In a Div to be provided by the user in Container Options

    caution

    The SystemStatusMessageDisplayDiv property in System Status State is deprecated

note

In addition, AdapTable will automatically fire the SystemStatusMessageChanged Event whenever the System Status message changes

Default Message and Status Type

Developers can provide values for the DefaultStatusMessage and DefaultStatusType properties.

These are the Message and Status Type which are displayed when no message has been set or the previous message was cleared.

important

Adaptable ensures the Default Message is displayed only when there is no 'live' Status Message to show

Predefined Config

System Status Predefined Config is defined as follows:

PropertyDescriptionDefault
DefaultStatusFurtherInformationDefault additional information display''
DefaultStatusMessageDefault status message to display"No Message"
DefaultStatusTypeDefault status type to displayInfo'
MaxMessagesInStoreHow many Messages held in State at any one time; when limit is breached, oldest Message is removed100
ShowAlertShow an Alert when a System Status message is sent.false

Example

export default {
SystemStatus: {
ShowAlert: false,
DefaultStatusMessage: 'Server is up.',
DefaultStatusType: 'Info',
DefaultStatusFurtherInformation: 'All services are running fully.'
},
} as PredefinedConfig;

In this example we have provided a Default Message, Further Information and Type to be used when the message is cleared / or there is no explicit System Status message.

API

The System Status API contains the following methods:

MethodDescription
clearSystemStatus()Clears current System Status message
deleteAllSystemStatusMessages()Deletes all System Status messages - will show Default
fireSystemStatusMessageChangedEvent(systemStatusMessageInfo)Fires SystemStatusMessageChanged Event
getCurrentSystemStatusMessageInfo()Retrieves current System Status Message
getSystemStatusState()Retrieves System Status section from Adaptable State
setDefaultMessage()Sets System Status message to be default Message, Type and Information
setErrorSystemStatus(statusMessage, furtherInformation)Sets an Error System Status Message
setInfoSystemStatus(statusMessage, furtherInformation)Sets an Info System Status Message
setSuccessSystemStatus(statusMessage, furtherInformation)Sets a Success System Status Message
setSystemStatus(statusMessage, messageType, statusFurtherInformation)Sets a new System Status message; appears in System Status toolbar, tool panel (and popup).
setWarningSystemStatus(statusMessage, furtherInformation)Sets a Warning System Status Message
showSystemStatusPopup()Opens System Status popup

UI Elements

System Status includes the following UI Elements:

  • Popup - Shows the all the System Status messages which have been set, together with a clear button for the most recent one. The message is coloured in line with the Message Type.

  • Toolbar - Same as Popup above.

  • Tool Panel - Same as Toolbar above.

  • Column Menu - Show System Status Column Menu Item opens the System Status popup.

  • Context Menu - Show System Status Context Menu Item opens the System Status popup.

note

In addition the Status System Function Button in the Dashboard will display with the colour associated with the current Status Type.

Entitlements

System Status Entitlement Rules:

  • Full: System Status messages can be read and cleared

  • Hidden: Everything is hidden from the User

  • ReadOnly: n/a

FAQ

Can I choose where System Status messages are displayed (in the same way as Alerts)?

Yes, to an extent. The System Status messsage will always display in the Toolbar and ToolPanel but you can additionally provide a Div (in Container Options) where it will display.

Alternatively you can listen to the SystemStatusMessageChanged Event and display messages where required.

More Information