getCurrentUserConfig
[ Function ]
public static getCurrentUserConfig(): TcHmi.Server.userConfigOnServer;
Returns the current user configuration.
Parameter
Name | Type | Description |
---|---|---|
- | - | - |
Return value
Type | Description |
---|---|
The configuration object of the currently logged on user. |
Available from 1.8 |
Sample - JavaScript
var userConfig = TcHmi.Server.getCurrentUserConfig();
if (userConfig.state === TcHmi.Server.userConfigState.usergroup) {
console.log('Current server is set to usergroup based configuration.');
} else if (userConfig.state === TcHmi.Server.userConfigState.noAuthRequired) {
console.log('Current server is set to "no auth required".');
} else {
console.log('Current server config is not known right now.');
}