ScheduleTableExporter
This class transforms scheduler component into two arrays: rows and columns. Columns array contains objects with meta information about column: field name, column name, width and type of the rendered value, rows array contains arrays of cell values.
const exporter = new ScheduleTableExporter({ target : scheduler });
exporter.export()
// Output
{
columns : [
{ field : 'name', value : 'First name', type : 'string', width : 100 },
{ field : 'name', value : 'Task', type : 'string', width : 100, eventColumn : true },
{ field : 'startDate', value : 'Starts', type : 'date', width : 100, eventColumn : true },
{ field : 'endDate', value : 'Ends', type : 'date', width : 100, eventColumn : true }
],
rows : [
['Michael', 'Hand out dundies', Date, Date],
['Michael', 'Buy condo', Date, Date],
['Jim', 'Close sale to library', Date, Date]
]
}
How data is exported
Data is exported as in the base class with minor addition: every event is exported on a separate row, like demonstrated above.
In case there are unassigned events, by default they will be exported as well
// output
{
rows : [
['Michael', 'Hand out dundies', Date, Date],
['Michael', 'Buy condo', Date, Date],
['Jim', 'Close sale to library', Date, Date],
['', 'No resource assigned'],
['', 'Halloween prep', Date, Date],
['', 'New year prep', Date, Date]
]
}
No results
Configs
Configs are options you supply in a configuration object when creating an instance of this class-
Set to
trueto include events that do not intersect the span of the current time axis. -
Set to
falseto not include unassigned events in the export.trueby default.
Properties
Properties are getters/setters or publicly accessible variables on this class-
Identifies an object as an instance of ScheduleTableExporter class, or subclass thereof.
-
Identifies an object as an instance of ScheduleTableExporter class, or subclass thereof.