Class sap.collaboration.components.socialtimeline.ComponentModule: sap/collaboration/components/socialtimeline/Component

extends UIComponent

Social Timeline

Deprecated API:Since version 1.34.0. For new integrations and existing implementations running on release 1.32 or later, use the Group Feed component (sap.collaboration.components.feed.Component), Business Object mode(sap.collaboration.FeedType.BusinessObjectGroups). Note that the Group Feed component does not display any updates related to the business object from the back-end system (system updates).

Constructor Summary
new sap.collaboration.components.socialtimeline.Component(sId?, mSettings?)Constructor for the Social Timeline Component.
Event Summary
customActionPress(oEventData)Event fire when a custom action is clicked
Method Summary
sap.collaboration.components.socialtimeline.Component.createContent()The method to create the Content (UI Control Tree) of the Component.
sap.collaboration.components.socialtimeline.Component.exit()Cleans up the component instance before destruction.
sap.collaboration.components.socialtimeline.Component.extend(sClassName, oClassInfo?, FNMetaImpl?)Creates a new subclass of class sap.collaboration.components.socialtimeline.Component with name sClassName and enriches it with the information contained in oClassInfo.
sap.collaboration.components.socialtimeline.Component.getMetadata()Returns a metadata object for class sap.collaboration.components.socialtimeline.Component.
sap.collaboration.components.socialtimeline.Component.init()Initializes the Component instance after creation.
sap.collaboration.components.socialtimeline.Component.onAfterRendering()Function is called when the rendering of the Component Container is completed.
sap.collaboration.components.socialtimeline.Component.onBeforeRendering()Function is called when the rendering of the Component Container is started.
sap.collaboration.components.socialtimeline.Component.setBusinessObject(oObject)Set the current business object for the social timeline to display.
sap.collaboration.components.socialtimeline.Component.setSettings(settings)Setter for the Component settings.
attachCustomActionPress(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the customActionPress event of this sap.collaboration.components.socialtimeline.Component.
detachCustomActionPress(fnFunction, oListener)Detaches event handler fnFunction from the customActionPress event of this sap.collaboration.components.socialtimeline.Component.
fireCustomActionPress(mArguments?)Fires event customActionPress to attached listeners.
getAlignment()Gets current value of property alignment.
getAxisOrientation()Getter for property axisOrientation.
getCustomFilter()Getter for property customFilter.
getEnableSocial()Gets current value of property enableSocial.
getNoDataText()Getter for property noDataText.
getShowIcons()Getter for property showIcons.
getVisible()Getter for property visible.
getWidth()Getter for property width.
setAlignment(sAlignment)Sets a new value for property alignment.
setAxisOrientation(oAxisOrientation)Setter for property axisOrientation.
setCustomFilter(sCustomFilter)Sets a new value for property customFilter.
setEnableSocial(bEnableSocial)Sets a new value for property enableSocial.
setNoDataText(sNoDataText)Setter for property noDataText.
setShowIcons(bShowIcons)Setter for property showIcons.
setVisible(bVisible)Setter for property visible.
setWidth(sWidth)Setter for property width.
sap.collaboration.components.socialtimeline.Component.setBusinessObjectKey(sKey)Set the current business object for the social timeline to display.
Constructor Detail
new sap.collaboration.components.socialtimeline.Component(sId?, mSettings?)
Constructor for the Social Timeline Component.

Accepts an object literal mSettings that defines initial property values, aggregated and associated objects as well as event handlers.

If the name of a setting is ambiguous (e.g. a property has the same name as an event), then the framework assumes property, aggregation, association, event in that order. To override this automatic resolution, one of the prefixes "aggregation:", "association:" or "event:" can be added to the name of the setting (such a prefixed name must be enclosed in single or double quotes).

The supported settings are:

  • Properties
    • enableSocial : boolean (default: true)
    • alignment : sap.suite.ui.commons.TimelineAlignment (default: sap.suite.ui.commons.TimelineAlignment.Right)
    • axisOrientation : sap.suite.ui.commons.TimelineAxisOrientation (default: sap.suite.ui.commons.TimelineAxisOrientation.Vertical)
    • noDataText : string
    • showIcons : boolean (default: true)
    • visible : boolean (default: true)
    • width : sap.ui.core.CSSSize (default: '100%')
    • customFilter : {object}
  • Events
    • customActionPress : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]
Parameters:
{string}sId? id for the new control, generated automatically if no id is given
{object}mSettings? initial settings for the new control
Deprecated:
Since version 1.34.0. For new integrations and existing implementations running on release 1.32 or later, use the Group Feed component (sap.collaboration.components.feed.Component), Business Object mode(sap.collaboration.FeedType.BusinessObjectGroups). Note that the Group Feed component does not display any updates related to the business object from the back-end system (system updates).
Event Detail
customActionPress(oEventData)
Event fire when a custom action is clicked
Parameters:
{object}oEventData
Method Detail
sap.collaboration.components.socialtimeline.Component.createContent()
The method to create the Content (UI Control Tree) of the Component.
sap.collaboration.components.socialtimeline.Component.deleteTimelineEntry(sId)
Delete a Timeline Entry. This method should be called when a custom action requires a deletion of a Timeline entry and should only be called if an a delete to the backend is performed successfully.
Parameters:
{string}sId the id of the timeline entry to delete
sap.collaboration.components.socialtimeline.Component.exit()
Cleans up the component instance before destruction.
sap.collaboration.components.socialtimeline.Component.extend(sClassName, oClassInfo?, FNMetaImpl?): function
Creates a new subclass of class sap.collaboration.components.socialtimeline.Component 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.UIComponent.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.collaboration.components.socialtimeline.Component.getMetadata(): sap.ui.base.Metadata
Returns a metadata object for class sap.collaboration.components.socialtimeline.Component.
Returns:
{sap.ui.base.Metadata} Metadata object describing this class
sap.collaboration.components.socialtimeline.Component.init()
Initializes the Component instance after creation.
sap.collaboration.components.socialtimeline.Component.onAfterRendering()
Function is called when the rendering of the Component Container is completed.
sap.collaboration.components.socialtimeline.Component.onBeforeRendering()
Function is called when the rendering of the Component Container is started.
sap.collaboration.components.socialtimeline.Component.setBusinessObject(oObject)
Set the current business object for the social timeline to display. Note: The function setBusinessObjectMap must be called once before calling setBusinessObject for the first time.
Parameters:
{object}oObject an object that contains the key and name for the business object
sap.collaboration.components.socialtimeline.Component.setBusinessObjectMap({object)
Set the business object map. It is used to initialize the data needed to retrieve the timeline entries. This function must be called once before calling setBusinessObjectKey for the first time.
Parameters:
{object businessObjectMap required - JSON object containing the following properties:
  • {sap.ui.model.odata.ODataModel} serviceModel required - OData model to retrieve timeline entries
  • {string} servicePath: The relative path to the OData service for the business object (example: "/sap/opu/odata/sap/ODATA_SRV")
  • {string} collection: Entity collection name of the business object
  • {string} applicationContext: The application context (example: "CRM", "SD", etc.)
  • {function} customActionCallback: A callback function to determine which timeline entries should receive the custom action. The function should return an array of text/value objects.
    sap.collaboration.components.socialtimeline.Component.setProperty()
    Set property of component
    sap.collaboration.components.socialtimeline.Component.setSettings(settings)
    Setter for the Component settings.
    Parameters:
    {object}settings A JSON object used to set the component settings, this object should contains the same properties used in the constructor.
    sap.collaboration.components.socialtimeline.Component.updateTimelineEntry(sText, sId)
    Update a Timeline Entry text. This method should be called when a custom action requires a content update of a Timeline entry and should only be called if an an update to the backend is performed successfully.
    Parameters:
    {string}sText the text that will be displayed in the content of the timeline entry
    {string}sId the id of the timeline entry to update
    attachCustomActionPress(oData?, fnFunction, oListener?): sap.collaboration.components.socialtimeline.Component
    Attaches event handler fnFunction to the customActionPress event of this sap.collaboration.components.socialtimeline.Component.

    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.collaboration.components.socialtimeline.Component itself.

    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.collaboration.components.socialtimeline.Component itself
    Returns:
    {sap.collaboration.components.socialtimeline.Component} Reference to this in order to allow method chaining
    detachCustomActionPress(fnFunction, oListener): sap.collaboration.components.socialtimeline.Component
    Detaches event handler fnFunction from the customActionPress event of this sap.collaboration.components.socialtimeline.Component.

    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:
    {sap.collaboration.components.socialtimeline.Component} Reference to this in order to allow method chaining
    fireCustomActionPress(mArguments?): sap.collaboration.components.socialtimeline.Component
    Fires event customActionPress to attached listeners.
    Parameters:
    {Map}mArguments? The arguments to pass along with the event
    Returns:
    {sap.collaboration.components.socialtimeline.Component} Reference to this in order to allow method chaining
    Gets current value of property alignment.

    Default value is Right.

    Returns:
    {sap.suite.ui.commons.TimelineAlignment} Value of property alignment
    Getter for property axisOrientation. Timeline axis orientation.

    Default value is Vertical

    Returns:
    {sap.suite.ui.commons.TimelineAxisOrientation} the value of property axisOrientation
    getCustomFilter(): array
    Getter for property customFilter.

    Default value is []. The customFilter is an array of objects, each object contains text and value. Text is the name of the filter category and value is the filter value.

    Returns:
    {array} the value of property customFilter
    getEnableSocial(): boolean
    Gets current value of property enableSocial.

    Default value is true.

    Returns:
    {boolean} Value of property enableSocial
    getNoDataText(): string
    Getter for property noDataText. This text is displayed when the control has no data.

    Default value is empty/undefined

    Returns:
    {string} the value of property noDataText
    getShowIcons(): boolean
    Getter for property showIcons. Show icon on each Timeline item.

    Default value is true

    Returns:
    {boolean} the value of property showIcons
    getVisible(): boolean
    Getter for property visible. Set Timeline control visibility

    Default value is true

    Returns:
    {boolean} the value of property visible
    getWidth(): sap.ui.core.CSSSize
    Getter for property width. Sets the width of the Timeline.

    Default value is 100%

    Returns:
    {sap.ui.core.CSSSize} the value of property width
    Sets a new value for property alignment.

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

    Default value is Right.

    Parameters:
    {sap.suite.ui.commons.TimelineAlignment}sAlignment New value for property alignment
    Returns:
    {sap.collaboration.components.socialtimeline.Component} Reference to this in order to allow method chaining
    setAxisOrientation(oAxisOrientation): sap.collaboration.components.socialtimeline.Component
    Setter for property axisOrientation.

    Default value is Vertical

    Parameters:
    {sap.suite.ui.commons.TimelineAxisOrientation}oAxisOrientation new value for property axisOrientation
    Returns:
    {sap.collaboration.components.socialtimeline.Component}this to allow method chaining
    Sets a new value for property customFilter.

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

    Parameters:
    {object[]}sCustomFilter New value for property customFilter
    Returns:
    {sap.collaboration.components.socialtimeline.Component} Reference to this in order to allow method chaining
    Sets a new value for property enableSocial.

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

    Default value is true.

    Parameters:
    {boolean}bEnableSocial New value for property enableSocial
    Returns:
    {sap.collaboration.components.socialtimeline.Component} Reference to this in order to allow method chaining
    Setter for property noDataText.

    Default value is empty/undefined

    Parameters:
    {string}sNoDataText new value for property noDataText
    Returns:
    {sap.collaboration.components.socialtimeline.Component}this to allow method chaining
    Setter for property showIcons.

    Default value is true

    Parameters:
    {boolean}bShowIcons new value for property showIcons
    Returns:
    {sap.collaboration.components.socialtimeline.Component}this to allow method chaining
    Setter for property visible.

    Default value is true

    Parameters:
    {boolean}bVisible new value for property visible
    Returns:
    {sap.collaboration.components.socialtimeline.Component}this to allow method chaining
    Setter for property width.

    Default value is 100%

    Parameters:
    {sap.ui.core.CSSSize}sWidth new value for property width
    Returns:
    {sap.collaboration.components.socialtimeline.Component}this to allow method chaining
    sap.collaboration.components.socialtimeline.Component.setBusinessObjectKey(sKey)
    Set the current business object for the social timeline to display. Note: The function setBusinessObjectMap must be called once before calling setBusinessObjectKey for the first time.
    Parameters:
    {string}sKey
    Deprecated:
    since 1.28.5. This method is deprecated, use method setBusinessObject instead.