sap.m.ViewSettingsDialog.extend(sClassName, oClassInfo?, FNMetaImpl?): function
Creates a new subclass of class sap.m.ViewSettingsDialog with name
sClassName
and enriches it with the information contained in
oClassInfo
.
oClassInfo
might contain the same kind of information as described in sap.ui.core.Control.extend.
Parameters:
{string} | sClassName | Name of the class being created |
{object} | oClassInfo? | Object literal with information about the class |
{function} | FNMetaImpl? | Constructor function for the metadata object; if not given, it defaults to sap.ui.core.ElementMetadata |
Returns:
{function} | Created class / constructor function |
Returns a metadata object for class sap.m.ViewSettingsDialog.
Returns:
Overwrites the aggregation setter in order to have ID validation logic as some strings are reserved for the predefined tabs.
Parameters:
{object} | oCustomTab | The custom tab to be added |
Returns:
Adds some filterItem to the aggregation filterItems
.
Parameters:
- Since:
- 1.16
Returns:
Adds a group item and sets the association to reflect the selected state.
Parameters:
Returns:
Adds a preset filter item and sets the association to reflect the selected state.
Parameters:
Returns:
Adds a sort item and sets the association to reflect the selected state.
Parameters:
Returns:
Attaches event handler
fnFunction
to the
cancel
event of this
sap.m.ViewSettingsDialog
.
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.ViewSettingsDialog
itself.
Called when the Cancel button is pressed. It can be used to set the state of custom filter controls.
Parameters:
{object} | oData? | An application-specific payload object that will be passed to the event handler along with the event object when firing the event |
{function} | fnFunction | The function to be called when the event occurs |
{object} | oListener? | Context object to call the event handler with. Defaults to this sap.m.ViewSettingsDialog itself |
Returns:
Attaches event handler
fnFunction
to the
confirm
event of this
sap.m.ViewSettingsDialog
.
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.ViewSettingsDialog
itself.
Indicates that the user has pressed the OK button and the selected sort, group, and filter settings should be applied to the data on this page. Note: Custom tabs are not converted to event parameters automatically. For custom tabs, you have to read the state of your controls inside the callback of this event.
Parameters:
{object} | oData? | An application-specific payload object that will be passed to the event handler along with the event object when firing the event |
{function} | fnFunction | The function to be called when the event occurs |
{object} | oListener? | Context object to call the event handler with. Defaults to this sap.m.ViewSettingsDialog itself |
Returns:
Attaches event handler
fnFunction
to the
filterDetailPageOpened
event of this
sap.m.ViewSettingsDialog
.
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.ViewSettingsDialog
itself.
Fired when the filter detail page is opened.
Parameters:
{object} | oData? | An application-specific payload object that will be passed to the event handler along with the event object when firing the event |
{function} | fnFunction | The function to be called when the event occurs |
{object} | oListener? | Context object to call the event handler with. Defaults to this sap.m.ViewSettingsDialog itself |
Returns:
Attaches event handler
fnFunction
to the
resetFilters
event of this
sap.m.ViewSettingsDialog
.
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.ViewSettingsDialog
itself.
Called when the reset filters button is pressed. It can be used to clear the state of custom filter controls.
Parameters:
{object} | oData? | An application-specific payload object that will be passed to the event handler along with the event object when firing the event |
{function} | fnFunction | The function to be called when the event occurs |
{object} | oListener? | Context object to call the event handler with. Defaults to this sap.m.ViewSettingsDialog itself |
Returns:
Binds aggregation
customTabs
to model data.
See ManagedObject.bindAggregation for a detailed description of the possible properties of oBindingInfo
.
Parameters:
{object} | oBindingInfo | The binding information |
- Since:
- 1.30
Returns:
Binds aggregation
filterItems
to model data.
See ManagedObject.bindAggregation for a detailed description of the possible properties of oBindingInfo
.
Parameters:
{object} | oBindingInfo | The binding information |
- Since:
- 1.16
Returns:
Binds aggregation
groupItems
to model data.
See ManagedObject.bindAggregation for a detailed description of the possible properties of oBindingInfo
.
Parameters:
{object} | oBindingInfo | The binding information |
- Since:
- 1.16
Returns:
Binds aggregation
presetFilterItems
to model data.
See ManagedObject.bindAggregation for a detailed description of the possible properties of oBindingInfo
.
Parameters:
{object} | oBindingInfo | The binding information |
- Since:
- 1.16
Returns:
Binds aggregation
sortItems
to model data.
See ManagedObject.bindAggregation for a detailed description of the possible properties of oBindingInfo
.
Parameters:
{object} | oBindingInfo | The binding information |
- Since:
- 1.16
Returns:
Destroys all the customTabs in the aggregation customTabs
.
- Since:
- 1.30
Returns:
Destroys all the filterItems in the aggregation filterItems
.
- Since:
- 1.16
Returns:
Destroys all the groupItems in the aggregation groupItems
.
- Since:
- 1.16
Returns:
Destroys all the presetFilterItems in the aggregation presetFilterItems
.
- Since:
- 1.16
Returns:
Destroys all the sortItems in the aggregation sortItems
.
- Since:
- 1.16
Returns:
Detaches event handler
fnFunction
from the
cancel
event of this
sap.m.ViewSettingsDialog
.
The passed function and listener object must match the ones used for event registration.
Parameters:
{function} | fnFunction | The function to be called, when the event occurs |
{object} | oListener | Context object on which the given function had to be called |
Returns:
Detaches event handler
fnFunction
from the
confirm
event of this
sap.m.ViewSettingsDialog
.
The passed function and listener object must match the ones used for event registration.
Parameters:
{function} | fnFunction | The function to be called, when the event occurs |
{object} | oListener | Context object on which the given function had to be called |
Returns:
Detaches event handler
fnFunction
from the
filterDetailPageOpened
event of this
sap.m.ViewSettingsDialog
.
The passed function and listener object must match the ones used for event registration.
Parameters:
{function} | fnFunction | The function to be called, when the event occurs |
{object} | oListener | Context object on which the given function had to be called |
Returns:
Detaches event handler
fnFunction
from the
resetFilters
event of this
sap.m.ViewSettingsDialog
.
The passed function and listener object must match the ones used for event registration.
Parameters:
{function} | fnFunction | The function to be called, when the event occurs |
{object} | oListener | Context object on which the given function had to be called |
Returns:
Fires event cancel
to attached listeners.
Parameters:
{Map} | mArguments? | The arguments to pass along with the event |
Returns:
Fires event
confirm
to attached listeners.
Expects the following event parameters:
sortItem
of type sap.m.ViewSettingsItem
The selected sort item.sortDescending
of type boolean
The selected sort order (true = descending, false = ascending).groupItem
of type sap.m.ViewSettingsItem
The selected group item.groupDescending
of type boolean
The selected group order (true = descending, false = ascending).presetFilterItem
of type sap.m.ViewSettingsItem
The selected preset filter item.filterItems
of type sap.m.ViewSettingsItem[]
The selected filters in an array of ViewSettingsItem.filterKeys
of type object
The selected filter items in an object notation format: { key: boolean }. If a custom control filter was displayed (for example, the user clicked on the filter item), the value for its key is set to true to indicate that there has been an interaction with the control.filterString
of type string
The selected filter items in a string format to display in the control's header bar in format "Filtered by: key (subkey1, subkey2, subkey3)".
Parameters:
{Map} | mArguments? | The arguments to pass along with the event |
Returns:
Fires event
filterDetailPageOpened
to attached listeners.
Expects the following event parameters:
parentFilterItem
of type sap.m.ViewSettingsFilterItem
The filter item for which the details are opened.
Parameters:
{Map} | mArguments? | The arguments to pass along with the event |
Returns:
Fires event resetFilters
to attached listeners.
Parameters:
{Map} | mArguments? | The arguments to pass along with the event |
Returns:
Gets content of aggregation
customTabs
.
The list of all the custom tabs.
- Since:
- 1.30
Returns:
Gets content of aggregation
filterItems
.
The list of items with key and value that can be filtered on (for example, a list of columns for a table). A filterItem is associated with one or more detail filters.
- Since:
- 1.16
Returns:
getGroupDescending(): boolean
Gets current value of property
groupDescending
.
Determines whether the group order is descending or ascending (default).
Default value is false
.
Returns:
{boolean} | Value of property groupDescending |
Gets content of aggregation
groupItems
.
The list of items with key and value that can be grouped on (for example, a list of columns for a table).
- Since:
- 1.16
Returns:
Gets content of aggregation
presetFilterItems
.
The list of preset filter items with key and value that allows the selection of more complex or custom filters. These entries are displayed at the top of the filter tab.
- Since:
- 1.16
Returns:
Returns the selected filters as an array of ViewSettingsItems.
It can be used to create matching sorters and filters to apply the selected settings to the data.
Returns:
getSelectedFilterKeys(): object
Gets the selected filter object in format {key: boolean}.
It can be used to create matching sorters and filters to apply the selected settings to the data.
Returns:
{object} | An object with item and subitem keys |
getSelectedFilterString(): string
Gets the filter string in format: "filter name (subfilter1 name, subfilter2 name, ...), ...". For custom and preset filters it will only add the filter name to the resulting string.
Returns:
{string} | The selected filter string |
ID of the element which is the current target of the association selectedGroupItem
, or null
.
Returns:
ID of the element which is the current target of the association selectedPresetFilterItem
, or null
.
Returns:
ID of the element which is the current target of the association selectedSortItem
, or null
.
Returns:
getSortDescending(): boolean
Gets current value of property
sortDescending
.
Determines whether the sort order is descending or ascending (default).
Default value is false
.
Returns:
{boolean} | Value of property sortDescending |
Gets content of aggregation
sortItems
.
The list of items with key and value that can be sorted over (for example, a list of columns for a table).
- Since:
- 1.16
Returns:
getTitle(): string
Gets current value of property
title
.
Defines the title of the dialog. If not set and there is only one active tab, the dialog uses the default "View" or "Sort", "Group", "Filter" respectively.
Returns:
{string} | Value of property title |
indexOfCustomTab(oCustomTab): int
Checks for the provided sap.m.ViewSettingsCustomTab
in the aggregation customTabs
. and returns its index if found or -1 otherwise.
Parameters:
- Since:
- 1.30
Returns:
{int} | The index of the provided control in the aggregation if found, or -1 otherwise |
indexOfFilterItem(oFilterItem): int
Checks for the provided sap.m.ViewSettingsItem
in the aggregation filterItems
. and returns its index if found or -1 otherwise.
Parameters:
- Since:
- 1.16
Returns:
{int} | The index of the provided control in the aggregation if found, or -1 otherwise |
indexOfGroupItem(oGroupItem): int
Checks for the provided sap.m.ViewSettingsItem
in the aggregation groupItems
. and returns its index if found or -1 otherwise.
Parameters:
- Since:
- 1.16
Returns:
{int} | The index of the provided control in the aggregation if found, or -1 otherwise |
indexOfPresetFilterItem(oPresetFilterItem): int
Checks for the provided sap.m.ViewSettingsItem
in the aggregation presetFilterItems
. and returns its index if found or -1 otherwise.
Parameters:
- Since:
- 1.16
Returns:
{int} | The index of the provided control in the aggregation if found, or -1 otherwise |
indexOfSortItem(oSortItem): int
Checks for the provided sap.m.ViewSettingsItem
in the aggregation sortItems
. and returns its index if found or -1 otherwise.
Parameters:
- Since:
- 1.16
Returns:
{int} | The index of the provided control in the aggregation if found, or -1 otherwise |
Inserts a customTab into the aggregation customTabs
.
Parameters:
{sap.m.ViewSettingsCustomTab} | oCustomTab | the customTab to insert; if empty, nothing is inserted |
{int} | iIndex | the 0 -based index the customTab should be inserted at; for a negative value of iIndex , the customTab is inserted at position 0; for a value greater than the current size of the aggregation, the customTab is inserted at the last position |
- Since:
- 1.30
Returns:
Inserts a filterItem into the aggregation filterItems
.
Parameters:
{sap.m.ViewSettingsItem} | oFilterItem | the filterItem to insert; if empty, nothing is inserted |
{int} | iIndex | the 0 -based index the filterItem should be inserted at; for a negative value of iIndex , the filterItem is inserted at position 0; for a value greater than the current size of the aggregation, the filterItem is inserted at the last position |
- Since:
- 1.16
Returns:
Inserts a groupItem into the aggregation groupItems
.
Parameters:
{sap.m.ViewSettingsItem} | oGroupItem | the groupItem to insert; if empty, nothing is inserted |
{int} | iIndex | the 0 -based index the groupItem should be inserted at; for a negative value of iIndex , the groupItem is inserted at position 0; for a value greater than the current size of the aggregation, the groupItem is inserted at the last position |
- Since:
- 1.16
Returns:
Inserts a presetFilterItem into the aggregation presetFilterItems
.
Parameters:
{sap.m.ViewSettingsItem} | oPresetFilterItem | the presetFilterItem to insert; if empty, nothing is inserted |
{int} | iIndex | the 0 -based index the presetFilterItem should be inserted at; for a negative value of iIndex , the presetFilterItem is inserted at position 0; for a value greater than the current size of the aggregation, the presetFilterItem is inserted at the last position |
- Since:
- 1.16
Returns:
Inserts a sortItem into the aggregation sortItems
.
Parameters:
{sap.m.ViewSettingsItem} | oSortItem | the sortItem to insert; if empty, nothing is inserted |
{int} | iIndex | the 0 -based index the sortItem should be inserted at; for a negative value of iIndex , the sortItem is inserted at position 0; for a value greater than the current size of the aggregation, the sortItem is inserted at the last position |
- Since:
- 1.16
Returns:
Opens the ViewSettingsDialog relative to the parent control.
Parameters:
{string} | sPageId? | The ID of the initial page to be opened in the dialog. The available values are "sort", "group", "filter" or IDs of custom tabs. |
Returns:
Removes all the controls from the aggregation
customTabs
.
Additionally, it unregisters them from the hosting UIArea.
- Since:
- 1.30
Returns:
Removes all filter Items and resets the remembered page if it was a filter detail page and all of its filter items are being removed.
Returns:
Removes all the controls from the aggregation
groupItems
.
Additionally, it unregisters them from the hosting UIArea.
- Since:
- 1.16
Returns:
Removes all the controls from the aggregation
presetFilterItems
.
Additionally, it unregisters them from the hosting UIArea.
- Since:
- 1.16
Returns:
Removes all the controls from the aggregation
sortItems
.
Additionally, it unregisters them from the hosting UIArea.
- Since:
- 1.16
Returns:
Removes a customTab from the aggregation customTabs
.
Parameters:
- Since:
- 1.30
Returns:
Removes a filter Item and resets the remembered page if it was the filter detail page of the removed filter.
Parameters:
Returns:
Removes a groupItem from the aggregation groupItems
.
Parameters:
- Since:
- 1.16
Returns:
Removes a presetFilterItem from the aggregation presetFilterItems
.
Parameters:
- Since:
- 1.16
Returns:
Removes a sortItem from the aggregation sortItems
.
Parameters:
- Since:
- 1.16
Returns:
Forward the busy state setting to the internal dialog instance. Needed because of the not-bullet proof implementation of setBusy in sap.ui.core.Control
Parameters:
{boolean} | bBusy | The busy state flag |
Returns:
Sets a new value for property
groupDescending
.
Determines whether the group order is descending or ascending (default).
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is false
.
Parameters:
{boolean} | bGroupDescending | New value for property groupDescending |
Returns:
Sets the selected filter object in format {key: boolean}.
Parameters:
{object} | oSelectedFilterKeys | A configuration object with filter item and sub item keys in the format: { key: boolean }. Setting boolean to true will set the filter to true, false or omitting an entry will set the filter to false. It can be used to set the dialog state based on presets. |
Returns:
Sets the selected group item (either by key or by item).
Parameters:
Returns:
Sets the selected preset filter item.
Parameters:
Returns:
Sets the selected sort item (either by key or by item).
Parameters:
Returns:
Sets a new value for property
sortDescending
.
Determines whether the sort order is descending or ascending (default).
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is false
.
Parameters:
{boolean} | bSortDescending | New value for property sortDescending |
Returns:
Sets the title of the internal dialog.
Parameters:
{string} | sTitle | The title text for the dialog |
Returns:
Unbinds aggregation customTabs
from model data.
- Since:
- 1.30
Returns:
Unbinds aggregation filterItems
from model data.
- Since:
- 1.16
Returns:
Unbinds aggregation groupItems
from model data.
- Since:
- 1.16
Returns:
Unbinds aggregation presetFilterItems
from model data.
- Since:
- 1.16
Returns:
Unbinds aggregation sortItems
from model data.
- Since:
- 1.16
Returns: