serialize

序列化当前加载在scheduler中的所有事件

void serialize();

Example

console.log(scheduler.serialize());
 
 
//(5) [{…}, {…}, {…}, {…}, {…}]
//> 0: {id: 1, start_date: '2022-05-17 09:00', end_date: '2022-05-17 12:00', 
//  text: 'Event'}
//> 1: {id: 2, start_date: '2022-05-18 10:00', end_date: '2022-05-18 16:00', 
//  text: 'Event'}
//> 2: {id: 3, start_date: '2022-05-20 10:00', end_date: '2022-05-20 14:00', 
//  text: 'Event'}
//> 3: {id: 4, start_date: '2022-05-21 16:00', end_date: '2022-05-21 17:00', 
//  text: 'Event'}
//> 4: {id: 5, start_date: '2022-05-22 09:00', end_date: '2022-05-22 17:00', 
//  text: 'Event'}

Details

此方法返回一个数组,包含当前加载到Scheduler中的所有事件。

结果数组中不包含由循环事件扩展创建的任何临时记录。

返回对象中以_$开头的属性会被省略,所有Date类型的属性会使用format_date模板转换为字符串。

See also
Change log

added in v6.0

返回顶部