TIMELINE_date
信息
此功能仅在 PRO 版本中可用。
Description
定义视图头部显示的日期
TIMELINE_date: (date1: Date, date2: Date) => string;
Parameters
date1- (required) Date - 事件的开始日期date2- (required) Date - 事件的结束日期
Returns
text- (string) - 用于在scheduler中渲染的html文本
Example
scheduler.templates.timeline_date = function(date1, date2){
if (date1.getDay()==date2.getDay() && date2-date1<(24*60*60*1000))
return scheduler.templates.day_date(date1);
return scheduler.templates.week_date(date1, date2);
};
Applicable views: Timeline view
Details
注释
该模板需要启用timeline插件。
如果未定义timeline_date模板,头部日期将默认为week_date模板所使用的格式。
Related Guides
Need help?
Got a question about the documentation? Reach out to our technical support team for help and guidance. For custom component solutions, visit the Services page.