serialize

serializes all events loaded into the 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

The method will return an array containing all events loaded into the Scheduler.

The result array won't include temporary records generated by the Recurring Events extension.

Properties that starts with _ or $ won't be included into the result objects, all Date properties will be converted to string using the format_date template.

See also
Change log

added in v6.0

Back to top