LIDOR SYSTEMS

Advanced User Interface Controls and Components

IntegralUI Web

Native Angular 4 and AngularJS UI Components


Menu / Data Binding


In this sample we are using an arbitrary data source to load the content of Menu. In order this to work, you need to match the data fields from your data source to the fields of menu item objects. You can use any custom names for your data, as long as you match those names with object fields, the Menu will be populated.

For purpose of data binding, we are using the dataFields attribute which accepts an object containing all names for the data fields (this property can also be used as parameter in loadData method, as it is in this example case). This property allows you to link fields from your data source to the fields of menu item objects in the Menu.

Default settings for this property are:

dataFields = {

enabled: 'enabled',

hasChildren: 'hasChildren',

icon: 'icon',

id : 'id',

items: 'items',

pid : 'pid',

style: 'style',

text : 'text'

value: 'value'

}