on 04-13-2018 9:52 AM
Hello!
I have a Timeline control (sap.suite.ui.commons.Timeline). When I first attached the data model (data requested to server-side) to the timeline, it still appeared the timeline items. However, the problem is when user add an item or do something that makes affect to timeline, then all items will disappear although it's refreshed.
This issue occurred when I used fiori launchpad for my app's entry point.
Please help me, thank you so much!
your code....
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Jun,
Here's my view detail
<mvc:View
controllerName="main.controller.Timeline"
xmlns="sap.suite.ui.commons"
xmlns:core="sap.ui.core"
xmlns:mvc="sap.ui.core.mvc"
xmlns:m="sap.m"
height="100%">
<m:OverflowToolbar id="idToolbar">
<m:content>
<m:Label text="Text Height"></m:Label>
<m:Select id="idGenderSelector" change="textHeightChanged">
<core:Item key="None" text="None"/>
<core:Item key="3" text="3 Lines"/>
<core:Item key="7" text="7 Lines"/>
<core:Item key="150px" text="150 px"/>
</m:Select>
<m:Label text="Group By Type"></m:Label>
<m:Select change="groupByChanged">
<core:Item key="None" text="None"/>
<core:Item key="Year" text="Year"/>
<core:Item key="Month" text="Month"/>
<core:Item key="Week" text="Week"/>
<core:Item key="Day" text="Day"/>
</m:Select>
<m:Label text="Axis orientation"></m:Label>
<m:Select change="orientationChanged">
<core:Item key="Vertical" text="Vertical"/>
<core:Item key="Horizontal" text="Horizontal"/>
</m:Select>
<m:Label text="Alignment"></m:Label>
<m:Select id="idAlignment" change="alignmentChanged">
<core:Item key="DoubleSided" text="Double sided"/>
<core:Item id="idAlignmentFirst" key="Left" text="Left"/>
<core:Item id="idAlignmentSecond" key="Right" text="Right"/>
</m:Select>
<m:CheckBox select="enableScrollSelected" text="enable scrollbar" selected="true"/>
</m:content>
</m:OverflowToolbar>
<Timeline
id="idTimeline"
enableDoubleSided="true"
enableBusyIndicator="true"
groupBy="title"
growingThreshhold="0"
filterTitle="Title"
sortOldestFirst="true"
lazyLoading="true"
select="onTimeLineItemSelected"
content="{/status}">
<content>
<TimelineItem
id="idTemplateItem"
dateTime="{postDate}"
title="{title}"
userNameClickable="true"
status="Success"
text="{content}"
userName="{appUser>/id}"
filterValue="{title}">
</TimelineItem>
</content>
</Timeline>
</mvc:View>
The issue above's solved after I'd removed line 'growingThreshhold="0"'. However, in my controller, I have:
this._timeline = this.getView().byId("idTimeline");
var sKey = oEvent.getParameter("selectedItem").getProperty("key");
this._timeline.setGroupByType(sKey);
When I activated this, an error occurred: "this._timeline.setGroupByType is not a function"
User | Count |
---|---|
89 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.