Class sap.m.P13nColumnsPanelModule: sap/m/P13nColumnsPanel

extends P13nPanel

The P13nColumnsPanel control is used to define column-specific settings for table personalization.


Since: 1.26.0.
Constructor Summary
new sap.m.P13nColumnsPanel(sId?, mSettings?)Constructor for a new P13nColumnsPanel.
Event Summary
addColumnsItem(oControlEvent)Event raised when a columnsItem is added.
changeColumnsItems(oControlEvent)Event raised if columnsItems is changed or new one needs to be created in the model.
setData(oControlEvent)Event raised if setData is called in model.
Events borrowed from class sap.m.P13nPanel
Events borrowed from class sap.ui.core.Control
Method Summary
sap.m.P13nColumnsPanel.extend(sClassName, oClassInfo?, FNMetaImpl?)Creates a new subclass of class sap.m.P13nColumnsPanel with name sClassName and enriches it with the information contained in oClassInfo.
sap.m.P13nColumnsPanel.getMetadata()Returns a metadata object for class sap.m.P13nColumnsPanel.
addColumnsItem(oColumnsItem)Add ColumnsItem to columnsItems aggregation
addItem(oItem)Add item to items aggregation
attachAddColumnsItem(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the addColumnsItem event of this sap.m.P13nColumnsPanel.
attachChangeColumnsItems(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the changeColumnsItems event of this sap.m.P13nColumnsPanel.
attachSetData(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the setData event of this sap.m.P13nColumnsPanel.
bindColumnsItems(oBindingInfo)Binds aggregation columnsItems to model data.
destroyColumnsItems()Destroy all instances from columnsItems aggregation
destroyItems()Destroy all items from items aggregation
detachAddColumnsItem(fnFunction, oListener)Detaches event handler fnFunction from the addColumnsItem event of this sap.m.P13nColumnsPanel.
detachChangeColumnsItems(fnFunction, oListener)Detaches event handler fnFunction from the changeColumnsItems event of this sap.m.P13nColumnsPanel.
detachSetData(fnFunction, oListener)Detaches event handler fnFunction from the setData event of this sap.m.P13nColumnsPanel.
exit()Cleans up before destruction.
fireAddColumnsItem(mArguments?)Fires event addColumnsItem to attached listeners.
fireChangeColumnsItems(mArguments?)Fires event changeColumnsItems to attached listeners.
fireSetData(mArguments?)Fires event setData to attached listeners.
getColumnsItems()Gets content of aggregation columnsItems.
getOkPayload()Delivers a payload for columnsPanel that can be used at consumer side
getResetPayload()Delivers a payload for columnsPanel that can be used at consumer side
getVisibleItemsThreshold()Gets current value of property visibleItemsThreshold.
indexOfColumnsItem(oColumnsItem)Checks for the provided sap.m.P13nColumnsItem in the aggregation columnsItems.
insertColumnsItem(iIndex, oColumnsItem)Insert ColumnsItem to columnsItems aggregation
insertItem(iIndex, oItem)Add item to items aggregation
onBeforeNavigationFrom()This method is executed before navigation, to provide validation result(s) for columnsPanel
reInitialize()This method does a re-initialization of the panel
removeAllColumnsItems()Remove all ColumnsItems from columnsItems aggregation
removeAllItems()Remove all item from items aggregation
removeColumnsItem(oColumnsItem)Remove ColumnsItem from columnsItems aggregation
removeItem(oItem)Remove item from items aggregation
setVisibleItemsThreshold(iVisibleItemsThreshold)Sets a new value for property visibleItemsThreshold.
unbindColumnsItems()Unbinds aggregation columnsItems from model data.
Constructor Detail
new sap.m.P13nColumnsPanel(sId?, mSettings?)
Constructor for a new P13nColumnsPanel.

Accepts an object literal mSettings that defines initial property values, aggregated and associated objects as well as event handlers. See sap.ui.base.ManagedObject for a general description of the syntax of the settings object.

The supported settings are:

  • Properties
  • Aggregations
  • Events
    • addColumnsItem : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]
    • changeColumnsItems : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]
    • setData : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]

In addition, all settings applicable to the base type sap.m.P13nPanel can be used as well.

Parameters:
{string}sId? id for the new control, generated automatically if no id is given
{object}mSettings? initial settings for the new control
Event Detail
addColumnsItem(oControlEvent)
Event raised when a columnsItem is added.
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
{sap.m.P13nColumnsItem}oControlEvent.getParameters.newItemcolumnsItem that needs to be added in the model.
Since:
1.26.0
changeColumnsItems(oControlEvent)
Event raised if columnsItems is changed or new one needs to be created in the model.
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
{sap.m.P13nColumnsItem[]}oControlEvent.getParameters.newItems Contains columnsItems that needs to be created in the model.
{sap.m.P13nColumnsItem[]}oControlEvent.getParameters.existingItems Contains columnsItems that needs to be changed in the model.
Since:
1.26.7
setData(oControlEvent)
Event raised if setData is called in model. The event serves the purpose of minimizing such calls since they can take up a lot of performance.
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
Since:
1.26.7
Method Detail
sap.m.P13nColumnsPanel.extend(sClassName, oClassInfo?, FNMetaImpl?): function
Creates a new subclass of class sap.m.P13nColumnsPanel 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.P13nPanel.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
sap.m.P13nColumnsPanel.getMetadata(): sap.ui.base.Metadata
Returns a metadata object for class sap.m.P13nColumnsPanel.
Returns:
{sap.ui.base.Metadata} Metadata object describing this class
addColumnsItem(oColumnsItem): sap.m.P13nColumnsPanel
Add ColumnsItem to columnsItems aggregation
Parameters:
{sap.m.P13nColumnsItem}oColumnsItem is the new ColumnsItem that shall be added
Since:
1.26.0
Returns:
{sap.m.P13nColumnsPanel}this to allow method chaining.
addItem(oItem): sap.m.P13nColumnsPanel
Add item to items aggregation
Parameters:
{sap.m.P13nItem}oItem is the new item that shall be added
Since:
1.26.0
Returns:
{sap.m.P13nColumnsPanel}this to allow method chaining.
attachAddColumnsItem(oData?, fnFunction, oListener?): sap.m.P13nColumnsPanel
Attaches event handler fnFunction to the addColumnsItem event of this sap.m.P13nColumnsPanel.

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.P13nColumnsPanel itself.

Event raised when a columnsItem is added.

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.P13nColumnsPanel itself
Since:
1.26.0
Returns:
{sap.m.P13nColumnsPanel} Reference to this in order to allow method chaining
attachChangeColumnsItems(oData?, fnFunction, oListener?): sap.m.P13nColumnsPanel
Attaches event handler fnFunction to the changeColumnsItems event of this sap.m.P13nColumnsPanel.

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.P13nColumnsPanel itself.

Event raised if columnsItems is changed or new one needs to be created in the model.

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.P13nColumnsPanel itself
Since:
1.26.7
Returns:
{sap.m.P13nColumnsPanel} Reference to this in order to allow method chaining
attachSetData(oData?, fnFunction, oListener?): sap.m.P13nColumnsPanel
Attaches event handler fnFunction to the setData event of this sap.m.P13nColumnsPanel.

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.P13nColumnsPanel itself.

Event raised if setData is called in model. The event serves the purpose of minimizing such calls since they can take up a lot of performance.

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.P13nColumnsPanel itself
Since:
1.26.7
Returns:
{sap.m.P13nColumnsPanel} Reference to this in order to allow method chaining
bindColumnsItems(oBindingInfo): sap.m.P13nColumnsPanel
Binds aggregation columnsItems to model data.

See ManagedObject.bindAggregation for a detailed description of the possible properties of oBindingInfo.

Parameters:
{object}oBindingInfo The binding information
Since:
1.26.0
Returns:
{sap.m.P13nColumnsPanel} Reference to this in order to allow method chaining
destroyColumnsItems(): sap.m.P13nColumnsPanel
Destroy all instances from columnsItems aggregation
Since:
1.26.0
Returns:
{sap.m.P13nColumnsPanel}this to allow method chaining.
destroyItems(): sap.m.P13nColumnsPanel
Destroy all items from items aggregation
Since:
1.26.0
Returns:
{sap.m.P13nColumnsPanel}this to allow method chaining.
detachAddColumnsItem(fnFunction, oListener): sap.m.P13nColumnsPanel
Detaches event handler fnFunction from the addColumnsItem event of this sap.m.P13nColumnsPanel.

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
Since:
1.26.0
Returns:
{sap.m.P13nColumnsPanel} Reference to this in order to allow method chaining
detachChangeColumnsItems(fnFunction, oListener): sap.m.P13nColumnsPanel
Detaches event handler fnFunction from the changeColumnsItems event of this sap.m.P13nColumnsPanel.

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
Since:
1.26.7
Returns:
{sap.m.P13nColumnsPanel} Reference to this in order to allow method chaining
detachSetData(fnFunction, oListener): sap.m.P13nColumnsPanel
Detaches event handler fnFunction from the setData event of this sap.m.P13nColumnsPanel.

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
Since:
1.26.7
Returns:
{sap.m.P13nColumnsPanel} Reference to this in order to allow method chaining
exit()
Cleans up before destruction.
fireAddColumnsItem(mArguments?): sap.m.P13nColumnsPanel
Fires event addColumnsItem to attached listeners.

Expects the following event parameters:

  • newItem of type sap.m.P13nColumnsItemcolumnsItem that needs to be added in the model.
Parameters:
{Map}mArguments? The arguments to pass along with the event
Since:
1.26.0
Returns:
{sap.m.P13nColumnsPanel} Reference to this in order to allow method chaining
fireChangeColumnsItems(mArguments?): sap.m.P13nColumnsPanel
Fires event changeColumnsItems to attached listeners.

Expects the following event parameters:

  • newItems of type sap.m.P13nColumnsItem[]Contains columnsItems that needs to be created in the model.
  • existingItems of type sap.m.P13nColumnsItem[]Contains columnsItems that needs to be changed in the model.
Parameters:
{Map}mArguments? The arguments to pass along with the event
Since:
1.26.7
Returns:
{sap.m.P13nColumnsPanel} Reference to this in order to allow method chaining
fireSetData(mArguments?): sap.m.P13nColumnsPanel
Fires event setData to attached listeners.
Parameters:
{Map}mArguments? The arguments to pass along with the event
Since:
1.26.7
Returns:
{sap.m.P13nColumnsPanel} Reference to this in order to allow method chaining
getColumnsItems(): sap.m.P13nColumnsItem[]
Gets content of aggregation columnsItems.

List of columns that has been changed.

Since:
1.26.0
Returns:
{sap.m.P13nColumnsItem[]}
getOkPayload(): object
Delivers a payload for columnsPanel that can be used at consumer side
Since:
1.26.7
Returns:
{object} oPayload, which contains useful information
getResetPayload(): object
Delivers a payload for columnsPanel that can be used at consumer side
Since:
1.28
Returns:
{object} oPayload, which contains useful information
getVisibleItemsThreshold(): int
Gets current value of property visibleItemsThreshold.

Specifies a threshold of visible items. If the end user makes a lot of columns visible, this might cause performance to slow down. When this happens, the user can receive a corresponding warning triggered by the visibleItemsThreshold property. The property needs to be activated and set to the required value by the consuming application to ensure that the warning message is shown when the threshold has been exceeded. In the following example the message will be shown if more than 100 visible columns are selected:

customData>
core:CustomData key="p13nDialogSettings"
value='\{"columns":\{"visible": true, "payload": \{"visibleItemsThreshold": 3\}\}\}' />
/customData>

Default value is -1.

Since:
1.26.7
Returns:
{int} Value of property visibleItemsThreshold
indexOfColumnsItem(oColumnsItem): int
Checks for the provided sap.m.P13nColumnsItem in the aggregation columnsItems. and returns its index if found or -1 otherwise.
Parameters:
{sap.m.P13nColumnsItem}oColumnsItem The columnsItem whose index is looked for
Since:
1.26.0
Returns:
{int} The index of the provided control in the aggregation if found, or -1 otherwise
insertColumnsItem(iIndex, oColumnsItem): sap.m.P13nColumnsPanel
Insert ColumnsItem to columnsItems aggregation
Parameters:
{int}iIndex is the index where the columnsItem item shall be inserted
{sap.m.P13nColumnsItem}oColumnsItem is the new columnsItem that shall be inserted
Since:
1.26.0
Returns:
{sap.m.P13nColumnsPanel}this to allow method chaining.
insertItem(iIndex, oItem): sap.m.P13nColumnsPanel
Add item to items aggregation
Parameters:
{int}iIndex is the index where the new item shall be inserted
{sap.m.P13nItem}oItem is the new item that shall be added
Since:
1.26.0
Returns:
{sap.m.P13nColumnsPanel}this to allow method chaining.
onBeforeNavigationFrom(): boolean
This method is executed before navigation, to provide validation result(s) for columnsPanel
Since:
1.26.7
Returns:
{boolean} true if it is allowed to navigate away from this panel, false if it is not allowed
reInitialize()
This method does a re-initialization of the panel
Since:
1.28
removeAllColumnsItems(): sap.m.P13nColumnsItem[]
Remove all ColumnsItems from columnsItems aggregation
Since:
1.26.0
Returns:
{sap.m.P13nColumnsItem[]} An array of the removed items (might be empty).
removeAllItems(): sap.m.P13nItem[]
Remove all item from items aggregation
Since:
1.26.0
Returns:
{sap.m.P13nItem[]} An array of the removed items (might be empty).
removeColumnsItem(oColumnsItem): sap.m.P13nColumnsItem
Remove ColumnsItem from columnsItems aggregation
Parameters:
{sap.m.P13nColumnsItem}oColumnsItem is the ColumnsItem that shall be removed
Since:
1.26.0
Returns:
{sap.m.P13nColumnsItem} The removed item or null.
removeItem(oItem): sap.m.P13nItem
Remove item from items aggregation
Parameters:
{sap.m.P13nItem}oItem is the item that shall be removed
Since:
1.26.0
Returns:
{sap.m.P13nItem} The removed item or null.
setVisibleItemsThreshold(iVisibleItemsThreshold): sap.m.P13nColumnsPanel
Sets a new value for property visibleItemsThreshold.

Specifies a threshold of visible items. If the end user makes a lot of columns visible, this might cause performance to slow down. When this happens, the user can receive a corresponding warning triggered by the visibleItemsThreshold property. The property needs to be activated and set to the required value by the consuming application to ensure that the warning message is shown when the threshold has been exceeded. In the following example the message will be shown if more than 100 visible columns are selected:

customData>
core:CustomData key="p13nDialogSettings"
value='\{"columns":\{"visible": true, "payload": \{"visibleItemsThreshold": 3\}\}\}' />
/customData>

When called with a value of null or undefined, the default value of the property will be restored.

Default value is -1.

Parameters:
{int}iVisibleItemsThreshold New value for property visibleItemsThreshold
Since:
1.26.7
Returns:
{sap.m.P13nColumnsPanel} Reference to this in order to allow method chaining
unbindColumnsItems(): sap.m.P13nColumnsPanel
Unbinds aggregation columnsItems from model data.
Since:
1.26.0
Returns:
{sap.m.P13nColumnsPanel} Reference to this in order to allow method chaining