Useful JavaScript functions in Mendix client API
JavaScript functions that are available in the Mendix client API. These can be used in the browser console or in JavaScript actions (nanoflows).
This list is not complete, and these functions are not documented by Mendix. Which means support is limited.
mx.session.getConfig()
Locale
Returns object with the user locale info (language code, first day of the week, date and number patterns etc.) of the current user.
Constants
Returns array with objects containing the constants exposed to client.
isDevModeEnabled
Returns boolean.
Metadata
Returns array with objects containing all entities and attributes available to the current user1.
Similar to the mx.meta.getMap();
Roles
Returns array of user roles of current user.
User
Returns object current user (system.user or it’s specialization administration.account, company.employee) with attributes and it’s values.
sessionObjectId
Returns integer sessionObjectId
Demo Users
Returns an array with objects containing the demo users; username, password and roles.
mx.meta.getMap()
getMap
Returns array with objects containing all entities and attributes available to the user1.
Similar to the mx.session.getConfig(“metadata”)