The NotificationListGroup
control is used for grouping notification items of the same type.
The group handles specific behavior for different use cases:
autoPriority
- determines the group priority to the highest priority of an item in the group.enableCollapseButtonWhenEmpty
- determines if the collapse/expand button for an empty group is displayed.showEmptyGroup
- determines if the header/footer of an empty group is displayed.Constructor for a new NotificationListGroup
.
Accepts an object literal mSettings
that defines initial property values, aggregated and associated objects as well as event handlers. See sap.ui.base.ManagedObject#constructor for a general description of the syntax of the settings object.
new sap.m.NotificationListGroup(sId?, mSettings?)
Param | Type | Default Value | Description |
---|---|---|---|
sId? | string | ID for the new control, generated automatically if no ID is given |
|
mSettings? | object | Initial settings for the new control |
Name | Type | Default Value | Description |
---|---|---|---|
authorName | string | empty string | Determines the notification group's author name. Visibility: public |
authorPicture | sap.ui.core.URI | Determines the URL of the notification group's author picture. Visibility: public |
|
autoPriority | boolean | true | Determines if the group will automatically set the priority based on the highest priority of its notifications or get its priority from the |
collapsed | boolean | false | Determines if the group is collapsed or expanded. Visibility: public |
datetime | string | empty string | Determines the due date of the NotificationListGroup. Visibility: public |
enableCollapseButtonWhenEmpty | boolean | false | Determines if the collapse/expand button for an empty group is displayed. Visibility: public |
showEmptyGroup | boolean | false | Determines if the group header/footer of the empty group will be always shown. By default groups with 0 notifications are not shown. Visibility: public |
showItemsCounter | boolean | true | Determines if the items counter inside the group header will be visible. Note: Counter value represents the number of currently visible (loaded) items inside the group. Visibility: public |
Name | Type | Default Value | Description |
---|---|---|---|
authorName | string | empty string | Determines the notification author name. Visibility: public |
authorPicture | sap.ui.core.URI | Determines the URL of the notification author picture. Visibility: public |
|
datetime | string | empty string | The time stamp of the Notification. Visibility: public |
priority | sap.ui.core.Priority | None | Determines the priority of the Notification. Visibility: public |
showButtons | boolean | true | Determines the action buttons visibility. Note: Action buttons are not shown when Notification List Groups are collapsed. Visibility: public |
showCloseButton | boolean | true | Determines the visibility of the close button. Visibility: public |
title | string | empty string | Determines the title of the NotificationListBase item. Visibility: public |
counter | int | Defines the counter value of the list items. Visibility: public |
|
highlight | string | None | Defines the highlight state of the list items. Valid values for the Accessibility support is provided through the associated highlightText property. If the |
highlightText | string | empty string | Defines the semantics of the highlight property for accessibility purposes. |
navigated | boolean | false | The navigated state of the list item. If set to |
selected | boolean | false | Defines the selected state of the list items. Note: Binding the |
type | sap.m.ListType | Inactive | Defines the visual indication and behavior of the list items, e.g. |
unread | boolean | false | Activates the unread indicator for the list item, if set to |
visible | boolean | true | Whether the control should be visible on the screen. If set to false, a placeholder is rendered instead of the real control. Visibility: public |
Default Aggregation: items
Name | Cardinality | Type | Description |
---|---|---|---|
_collapseButton | 0..1 | sap.m.Button |
The collapse/expand button. |
items (default) | 0..n | sap.m.NotificationListItem |
The NotificationListItems inside the group. |
Event | Description |
---|---|
onCollapse |
|
Method | Description |
---|---|
addItem |
Adds some item to the aggregation items. |
attachOnCollapse |
Attaches event handler When called, the context of the event handler (its
|
destroyItems |
Destroys all the items in the aggregation items. |
detachOnCollapse |
Detaches event handler The passed function and listener object must match the ones used for event registration. |
sap.m.NotificationListGroup.extend |
Creates a new subclass of class sap.m.NotificationListGroup with name
|
fireOnCollapse |
Fires event onCollapse to attached listeners. |
getAuthorName |
Gets current value of property authorName. Determines the notification group's author name. Default value is |
getAuthorPicture |
Gets current value of property authorPicture. Determines the URL of the notification group's author picture. |
getAutoPriority |
Gets current value of property autoPriority. Determines if the group will automatically set the priority based on the highest priority of its notifications or get its priority from the Default value is |
getCollapsed |
Gets current value of property collapsed. Determines if the group is collapsed or expanded. Default value is |
getDatetime |
Gets current value of property datetime. Determines the due date of the NotificationListGroup. Default value is |
getEnableCollapseButtonWhenEmpty |
Gets current value of property enableCollapseButtonWhenEmpty. Determines if the collapse/expand button for an empty group is displayed. Default value is |
getItems |
Gets content of aggregation items. The NotificationListItems inside the group. |
sap.m.NotificationListGroup.getMetadata |
Returns a metadata object for class sap.m.NotificationListGroup. |
getShowEmptyGroup |
Gets current value of property showEmptyGroup. Determines if the group header/footer of the empty group will be always shown. By default groups with 0 notifications are not shown. Default value is |
getShowItemsCounter |
Gets current value of property showItemsCounter. Determines if the items counter inside the group header will be visible. Note: Counter value represents the number of currently visible (loaded) items inside the group. Default value is |
indexOfItem |
Checks for the provided |
insertItem |
Inserts a item into the aggregation items. |
removeAllItems |
Removes all the controls from the aggregation items. Additionally, it unregisters them from the hosting UIArea. |
removeItem |
Removes a item from the aggregation items. |
setAuthorName |
Sets a new value for property authorName. Determines the notification group's author name. When called with a value of Default value is |
setAuthorPicture |
Sets a new value for property authorPicture. Determines the URL of the notification group's author picture. When called with a value of |
setAutoPriority |
Sets a new value for property autoPriority. Determines if the group will automatically set the priority based on the highest priority of its notifications or get its priority from the When called with a value of Default value is |
setCollapsed |
Sets a new value for property collapsed. Determines if the group is collapsed or expanded. When called with a value of Default value is |
setDatetime |
Sets a new value for property datetime. Determines the due date of the NotificationListGroup. When called with a value of Default value is |
setEnableCollapseButtonWhenEmpty |
Sets a new value for property enableCollapseButtonWhenEmpty. Determines if the collapse/expand button for an empty group is displayed. When called with a value of Default value is |
setShowEmptyGroup |
Sets a new value for property showEmptyGroup. Determines if the group header/footer of the empty group will be always shown. By default groups with 0 notifications are not shown. When called with a value of Default value is |
setShowItemsCounter |
Sets a new value for property showItemsCounter. Determines if the items counter inside the group header will be visible. Note: Counter value represents the number of currently visible (loaded) items inside the group. When called with a value of Default value is |
Adds some item to the aggregation items.
Param | Type | DefaultValue | Description |
---|---|---|---|
oItem | sap.m.NotificationListItem |
The item to add; if empty, nothing is inserted |
Attaches event handler fnFunction
to the onCollapse event of this sap.m.NotificationListGroup
.
When called, the context of the event handler (its this
) will be bound to oListener
if specified, otherwise it will be bound to this sap.m.NotificationListGroup
itself.
onCollapse
event is called when collapse property value is changed
Param | Type | DefaultValue | Description |
---|---|---|---|
oData | object |
An application-specific payload object that will be passed to the event handler along with the event object when firing the event |
|
fnFunction | function(sap.ui.base.Event) : void |
The function to be called when the event occurs |
|
oListener | object |
Context object to call the event handler with. Defaults to this |
Detaches event handler fnFunction
from the onCollapse event of this sap.m.NotificationListGroup
.
The passed function and listener object must match the ones used for event registration.
Param | Type | DefaultValue | Description |
---|---|---|---|
fnFunction | function(sap.ui.base.Event) : void |
The function to be called, when the event occurs |
|
oListener | object |
Context object on which the given function had to be called |
Creates a new subclass of class sap.m.NotificationListGroup with name sClassName
and enriches it with the information contained in oClassInfo
.
oClassInfo
might contain the same kind of information as described in sap.m.NotificationListBase.extend.
Param | Type | DefaultValue | Description |
---|---|---|---|
sClassName | string |
Name of the class being created |
|
oClassInfo | object |
Object literal with information about the class |
|
FNMetaImpl | function |
Constructor function for the metadata object; if not given, it defaults to the metadata implementation used by this class |
Fires event onCollapse to attached listeners.
Param | Type | DefaultValue | Description |
---|---|---|---|
mParameters | object |
Parameters to pass along with the event |
|
collapsed | boolean |
Indicates exact collapse direction |
Gets current value of property authorName.
Determines the notification group's author name.
Default value is empty string
.
Gets current value of property authorPicture.
Determines the URL of the notification group's author picture.
Gets current value of property autoPriority.
Determines if the group will automatically set the priority based on the highest priority of its notifications or get its priority from the priority
property.
Default value is true
.
Gets current value of property collapsed.
Determines if the group is collapsed or expanded.
Default value is false
.
Gets current value of property datetime.
Determines the due date of the NotificationListGroup.
Default value is empty string
.
Gets current value of property enableCollapseButtonWhenEmpty.
Determines if the collapse/expand button for an empty group is displayed.
Default value is false
.
Returns a metadata object for class sap.m.NotificationListGroup.
Gets current value of property showEmptyGroup.
Determines if the group header/footer of the empty group will be always shown. By default groups with 0 notifications are not shown.
Default value is false
.
Gets current value of property showItemsCounter.
Determines if the items counter inside the group header will be visible.
Note: Counter value represents the number of currently visible (loaded) items inside the group.
Default value is true
.
Checks for the provided sap.m.NotificationListItem
in the aggregation items. and returns its index if found or -1 otherwise.
Param | Type | DefaultValue | Description |
---|---|---|---|
oItem | sap.m.NotificationListItem |
The item whose index is looked for |
Inserts a item into the aggregation items.
Param | Type | DefaultValue | Description |
---|---|---|---|
oItem | sap.m.NotificationListItem |
The item to insert; if empty, nothing is inserted |
|
iIndex | int |
The |
Removes all the controls from the aggregation items.
Additionally, it unregisters them from the hosting UIArea.
Removes a item from the aggregation items.
Param | Type | DefaultValue | Description |
---|---|---|---|
vItem | int string sap.m.NotificationListItem |
The item to remove or its index or id |
Sets a new value for property authorName.
Determines the notification group's author name.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is empty string
.
Param | Type | DefaultValue | Description |
---|---|---|---|
sAuthorName | string | '' |
New value for property |
Sets a new value for property authorPicture.
Determines the URL of the notification group's author picture.
When called with a value of null
or undefined
, the default value of the property will be restored.
Param | Type | DefaultValue | Description |
---|---|---|---|
sAuthorPicture | sap.ui.core.URI |
New value for property |
Sets a new value for property autoPriority.
Determines if the group will automatically set the priority based on the highest priority of its notifications or get its priority from the priority
property.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is true
.
Param | Type | DefaultValue | Description |
---|---|---|---|
bAutoPriority | boolean | true |
New value for property |
Sets a new value for property collapsed.
Determines if the group is collapsed or expanded.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is false
.
Param | Type | DefaultValue | Description |
---|---|---|---|
bCollapsed | boolean | false |
New value for property |
Sets a new value for property datetime.
Determines the due date of the NotificationListGroup.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is empty string
.
Param | Type | DefaultValue | Description |
---|---|---|---|
sDatetime | string | '' |
New value for property |
Sets a new value for property enableCollapseButtonWhenEmpty.
Determines if the collapse/expand button for an empty group is displayed.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is false
.
Param | Type | DefaultValue | Description |
---|---|---|---|
bEnableCollapseButtonWhenEmpty | boolean | false |
New value for property |
Sets a new value for property showEmptyGroup.
Determines if the group header/footer of the empty group will be always shown. By default groups with 0 notifications are not shown.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is false
.
Param | Type | DefaultValue | Description |
---|---|---|---|
bShowEmptyGroup | boolean | false |
New value for property |
Sets a new value for property showItemsCounter.
Determines if the items counter inside the group header will be visible.
Note: Counter value represents the number of currently visible (loaded) items inside the group.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is true
.
Param | Type | DefaultValue | Description |
---|---|---|---|
bShowItemsCounter | boolean | true |
New value for property |