@memberjunction/ng-timeline 1.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/component/dummy-data.d.ts +5 -0
- package/dist/lib/component/dummy-data.js +815 -0
- package/dist/lib/component/timeline.component.d.ts +86 -0
- package/dist/lib/component/timeline.component.js +160 -0
- package/dist/lib/module.d.ts +14 -0
- package/dist/lib/module.js +51 -0
- package/dist/public-api.d.ts +2 -0
- package/dist/public-api.js +5 -0
- package/package.json +41 -0
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { SchedulerEvent } from '@progress/kendo-angular-scheduler';
|
|
2
|
+
export declare const displayDate: Date;
|
|
3
|
+
export declare const sampleData: SchedulerEvent[];
|
|
4
|
+
export declare const sampleDataWithResources: SchedulerEvent[];
|
|
5
|
+
export declare const sampleDataWithCustomSchema: any[];
|
|
@@ -0,0 +1,815 @@
|
|
|
1
|
+
const baseData = [
|
|
2
|
+
{
|
|
3
|
+
"TaskID": 4,
|
|
4
|
+
"OwnerID": 2,
|
|
5
|
+
"Title": "Bowling tournament",
|
|
6
|
+
"Description": "",
|
|
7
|
+
"StartTimezone": null,
|
|
8
|
+
"Start": "2013-06-09T21:00:00.000Z",
|
|
9
|
+
"End": "2013-06-10T00:00:00.000Z",
|
|
10
|
+
"EndTimezone": null,
|
|
11
|
+
"RecurrenceRule": null,
|
|
12
|
+
"RecurrenceID": null,
|
|
13
|
+
"RecurrenceException": null,
|
|
14
|
+
"IsAllDay": false
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
"TaskID": 5,
|
|
18
|
+
"OwnerID": 2,
|
|
19
|
+
"Title": "Take the dog to the vet",
|
|
20
|
+
"Description": "",
|
|
21
|
+
"StartTimezone": null,
|
|
22
|
+
"Start": "2013-06-10T07:00:00.000Z",
|
|
23
|
+
"End": "2013-06-10T08:00:00.000Z",
|
|
24
|
+
"EndTimezone": null,
|
|
25
|
+
"RecurrenceRule": null,
|
|
26
|
+
"RecurrenceID": null,
|
|
27
|
+
"RecurrenceException": null,
|
|
28
|
+
"IsAllDay": false
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
"TaskID": 6,
|
|
32
|
+
"OwnerID": 2,
|
|
33
|
+
"Title": "Call Charlie about the project",
|
|
34
|
+
"Description": "",
|
|
35
|
+
"StartTimezone": null,
|
|
36
|
+
"Start": "2013-06-11T11:30:00.000Z",
|
|
37
|
+
"End": "2013-06-11T13:00:00.000Z",
|
|
38
|
+
"EndTimezone": null,
|
|
39
|
+
"RecurrenceRule": null,
|
|
40
|
+
"RecurrenceID": null,
|
|
41
|
+
"RecurrenceException": null,
|
|
42
|
+
"IsAllDay": false
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
"TaskID": 7,
|
|
46
|
+
"OwnerID": 3,
|
|
47
|
+
"Title": "Meeting with Alex",
|
|
48
|
+
"Description": "",
|
|
49
|
+
"StartTimezone": null,
|
|
50
|
+
"Start": "2013-06-12T11:00:00.000Z",
|
|
51
|
+
"End": "2013-06-12T12:00:00.000Z",
|
|
52
|
+
"EndTimezone": null,
|
|
53
|
+
"RecurrenceRule": null,
|
|
54
|
+
"RecurrenceID": null,
|
|
55
|
+
"RecurrenceException": null,
|
|
56
|
+
"IsAllDay": false
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"TaskID": 9,
|
|
60
|
+
"OwnerID": 2,
|
|
61
|
+
"Title": "Alex's Birthday",
|
|
62
|
+
"Description": "",
|
|
63
|
+
"StartTimezone": null,
|
|
64
|
+
"Start": "2013-06-14T02:00:00.000Z",
|
|
65
|
+
"End": "2013-06-14T02:00:00.000Z",
|
|
66
|
+
"EndTimezone": null,
|
|
67
|
+
"RecurrenceRule": null,
|
|
68
|
+
"RecurrenceID": null,
|
|
69
|
+
"RecurrenceException": null,
|
|
70
|
+
"IsAllDay": true
|
|
71
|
+
},
|
|
72
|
+
{
|
|
73
|
+
"TaskID": 12,
|
|
74
|
+
"OwnerID": 2,
|
|
75
|
+
"Title": "Car Service",
|
|
76
|
+
"Description": "Might come to work later!",
|
|
77
|
+
"StartTimezone": null,
|
|
78
|
+
"Start": "2013-06-24T08:30:00.000Z",
|
|
79
|
+
"End": "2013-06-24T09:30:00.000Z",
|
|
80
|
+
"EndTimezone": null,
|
|
81
|
+
"RecurrenceRule": null,
|
|
82
|
+
"RecurrenceID": null,
|
|
83
|
+
"RecurrenceException": null,
|
|
84
|
+
"IsAllDay": false
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
"TaskID": 14,
|
|
88
|
+
"OwnerID": 3,
|
|
89
|
+
"RoomID": 2,
|
|
90
|
+
"Title": "Replace the printer on the 1st floor",
|
|
91
|
+
"Description": "",
|
|
92
|
+
"StartTimezone": null,
|
|
93
|
+
"Start": "2013-06-24T10:00:00.000Z",
|
|
94
|
+
"End": "2013-06-24T11:00:00.000Z",
|
|
95
|
+
"EndTimezone": null,
|
|
96
|
+
"RecurrenceRule": null,
|
|
97
|
+
"RecurrenceID": null,
|
|
98
|
+
"RecurrenceException": null,
|
|
99
|
+
"IsAllDay": false
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
"TaskID": 15,
|
|
103
|
+
"OwnerID": 1,
|
|
104
|
+
"Title": "Attending HR Conference",
|
|
105
|
+
"Description": "",
|
|
106
|
+
"StartTimezone": null,
|
|
107
|
+
"Start": "2013-06-25T00:00:00.000Z",
|
|
108
|
+
"End": "2013-06-26T00:00:00.000Z",
|
|
109
|
+
"EndTimezone": null,
|
|
110
|
+
"RecurrenceRule": null,
|
|
111
|
+
"RecurrenceID": null,
|
|
112
|
+
"RecurrenceException": null,
|
|
113
|
+
"IsAllDay": true
|
|
114
|
+
},
|
|
115
|
+
{
|
|
116
|
+
"TaskID": 16,
|
|
117
|
+
"OwnerID": 1,
|
|
118
|
+
"Title": "Business Lunch with Gregory Watkins",
|
|
119
|
+
"Description": "",
|
|
120
|
+
"StartTimezone": null,
|
|
121
|
+
"Start": "2013-06-25T12:00:00.000Z",
|
|
122
|
+
"End": "2013-06-25T13:00:00.000Z",
|
|
123
|
+
"EndTimezone": null,
|
|
124
|
+
"RecurrenceRule": null,
|
|
125
|
+
"RecurrenceID": null,
|
|
126
|
+
"RecurrenceException": null,
|
|
127
|
+
"IsAllDay": false
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
"TaskID": 17,
|
|
131
|
+
"OwnerID": 1,
|
|
132
|
+
"Title": "Breakfast with CFO and COO",
|
|
133
|
+
"Description": "",
|
|
134
|
+
"StartTimezone": null,
|
|
135
|
+
"Start": "2013-06-27T08:30:00.000Z",
|
|
136
|
+
"End": "2013-06-27T09:30:00.000Z",
|
|
137
|
+
"EndTimezone": null,
|
|
138
|
+
"RecurrenceRule": null,
|
|
139
|
+
"RecurrenceID": null,
|
|
140
|
+
"RecurrenceException": null,
|
|
141
|
+
"IsAllDay": false
|
|
142
|
+
},
|
|
143
|
+
{
|
|
144
|
+
"TaskID": 18,
|
|
145
|
+
"OwnerID": 1,
|
|
146
|
+
"Title": "Job Interview - Mathew Stevens",
|
|
147
|
+
"Description": "Junior Researcher",
|
|
148
|
+
"StartTimezone": null,
|
|
149
|
+
"Start": "2013-06-27T10:00:00.000Z",
|
|
150
|
+
"End": "2013-06-27T11:00:00.000Z",
|
|
151
|
+
"EndTimezone": null,
|
|
152
|
+
"RecurrenceRule": null,
|
|
153
|
+
"RecurrenceID": null,
|
|
154
|
+
"RecurrenceException": null,
|
|
155
|
+
"IsAllDay": false
|
|
156
|
+
},
|
|
157
|
+
{
|
|
158
|
+
"TaskID": 19,
|
|
159
|
+
"OwnerID": 1,
|
|
160
|
+
"Title": "Review CVs with Tim",
|
|
161
|
+
"Description": "",
|
|
162
|
+
"StartTimezone": null,
|
|
163
|
+
"Start": "2013-06-27T11:00:00.000Z",
|
|
164
|
+
"End": "2013-06-27T11:30:00.000Z",
|
|
165
|
+
"EndTimezone": null,
|
|
166
|
+
"RecurrenceRule": null,
|
|
167
|
+
"RecurrenceID": null,
|
|
168
|
+
"RecurrenceException": null,
|
|
169
|
+
"IsAllDay": false
|
|
170
|
+
},
|
|
171
|
+
{
|
|
172
|
+
"TaskID": 20,
|
|
173
|
+
"OwnerID": 1,
|
|
174
|
+
"Title": "Lunch with Monica",
|
|
175
|
+
"Description": "Discuss the Employee handbook",
|
|
176
|
+
"StartTimezone": null,
|
|
177
|
+
"Start": "2013-06-27T12:00:00.000Z",
|
|
178
|
+
"End": "2013-06-27T13:30:00.000Z",
|
|
179
|
+
"EndTimezone": null,
|
|
180
|
+
"RecurrenceRule": null,
|
|
181
|
+
"RecurrenceID": null,
|
|
182
|
+
"RecurrenceException": null,
|
|
183
|
+
"IsAllDay": false
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
"TaskID": 21,
|
|
187
|
+
"OwnerID": 1,
|
|
188
|
+
"Title": "Job Interview - John Stewart",
|
|
189
|
+
"Description": "Accountant",
|
|
190
|
+
"StartTimezone": null,
|
|
191
|
+
"Start": "2013-06-27T14:00:00.000Z",
|
|
192
|
+
"End": "2013-06-27T15:00:00.000Z",
|
|
193
|
+
"EndTimezone": null,
|
|
194
|
+
"RecurrenceRule": null,
|
|
195
|
+
"RecurrenceID": null,
|
|
196
|
+
"RecurrenceException": null,
|
|
197
|
+
"IsAllDay": false
|
|
198
|
+
},
|
|
199
|
+
{
|
|
200
|
+
"TaskID": 22,
|
|
201
|
+
"OwnerID": 1,
|
|
202
|
+
"Title": "Job Interview - Mary Smith",
|
|
203
|
+
"Description": "Accountant",
|
|
204
|
+
"StartTimezone": null,
|
|
205
|
+
"Start": "2013-06-27T15:30:00.000Z",
|
|
206
|
+
"End": "2013-06-27T16:30:00.000Z",
|
|
207
|
+
"EndTimezone": null,
|
|
208
|
+
"RecurrenceRule": null,
|
|
209
|
+
"RecurrenceID": null,
|
|
210
|
+
"RecurrenceException": null,
|
|
211
|
+
"IsAllDay": false
|
|
212
|
+
},
|
|
213
|
+
{
|
|
214
|
+
"TaskID": 24,
|
|
215
|
+
"OwnerID": 3,
|
|
216
|
+
"Title": "Register new Access Cards",
|
|
217
|
+
"Description": "",
|
|
218
|
+
"StartTimezone": null,
|
|
219
|
+
"Start": "2013-06-24T12:00:00.000Z",
|
|
220
|
+
"End": "2013-06-24T12:30:00.000Z",
|
|
221
|
+
"EndTimezone": null,
|
|
222
|
+
"RecurrenceRule": null,
|
|
223
|
+
"RecurrenceID": null,
|
|
224
|
+
"RecurrenceException": null,
|
|
225
|
+
"IsAllDay": false
|
|
226
|
+
},
|
|
227
|
+
{
|
|
228
|
+
"TaskID": 25,
|
|
229
|
+
"OwnerID": 1,
|
|
230
|
+
"Title": "HR Lecture",
|
|
231
|
+
"Description": "",
|
|
232
|
+
"StartTimezone": null,
|
|
233
|
+
"Start": "2013-06-04T19:00:00.000Z",
|
|
234
|
+
"End": "2013-06-04T21:00:00.000Z",
|
|
235
|
+
"EndTimezone": null,
|
|
236
|
+
"RecurrenceRule": "FREQ=WEEKLY;BYDAY=TU,TH",
|
|
237
|
+
"RecurrenceID": null,
|
|
238
|
+
"RecurrenceException": null,
|
|
239
|
+
"IsAllDay": false
|
|
240
|
+
},
|
|
241
|
+
{
|
|
242
|
+
"TaskID": 26,
|
|
243
|
+
"OwnerID": 1,
|
|
244
|
+
"Title": "Dentist",
|
|
245
|
+
"Description": "",
|
|
246
|
+
"StartTimezone": null,
|
|
247
|
+
"Start": "2013-06-28T08:00:00.000Z",
|
|
248
|
+
"End": "2013-06-28T09:00:00.000Z",
|
|
249
|
+
"EndTimezone": null,
|
|
250
|
+
"RecurrenceRule": null,
|
|
251
|
+
"RecurrenceID": null,
|
|
252
|
+
"RecurrenceException": null,
|
|
253
|
+
"IsAllDay": false
|
|
254
|
+
},
|
|
255
|
+
{
|
|
256
|
+
"TaskID": 27,
|
|
257
|
+
"OwnerID": 1,
|
|
258
|
+
"Title": "Job Interview - Laura Bailey",
|
|
259
|
+
"Description": "Helpdesk",
|
|
260
|
+
"StartTimezone": null,
|
|
261
|
+
"Start": "2013-06-28T09:30:00.000Z",
|
|
262
|
+
"End": "2013-06-28T10:30:00.000Z",
|
|
263
|
+
"EndTimezone": null,
|
|
264
|
+
"RecurrenceRule": null,
|
|
265
|
+
"RecurrenceID": null,
|
|
266
|
+
"RecurrenceException": null,
|
|
267
|
+
"IsAllDay": false
|
|
268
|
+
},
|
|
269
|
+
{
|
|
270
|
+
"TaskID": 28,
|
|
271
|
+
"OwnerID": 1,
|
|
272
|
+
"Title": "Job Interview - Jenny Baxter",
|
|
273
|
+
"Description": "Helpdesk",
|
|
274
|
+
"StartTimezone": null,
|
|
275
|
+
"Start": "2013-06-28T11:00:00.000Z",
|
|
276
|
+
"End": "2013-06-28T12:00:00.000Z",
|
|
277
|
+
"EndTimezone": null,
|
|
278
|
+
"RecurrenceRule": null,
|
|
279
|
+
"RecurrenceID": null,
|
|
280
|
+
"RecurrenceException": null,
|
|
281
|
+
"IsAllDay": false
|
|
282
|
+
},
|
|
283
|
+
{
|
|
284
|
+
"TaskID": 31,
|
|
285
|
+
"OwnerID": 1,
|
|
286
|
+
"Title": "Team building prep tasks",
|
|
287
|
+
"Description": "",
|
|
288
|
+
"StartTimezone": null,
|
|
289
|
+
"Start": "2013-06-28T14:00:00.000Z",
|
|
290
|
+
"End": "2013-06-28T17:00:00.000Z",
|
|
291
|
+
"EndTimezone": null,
|
|
292
|
+
"RecurrenceRule": null,
|
|
293
|
+
"RecurrenceID": null,
|
|
294
|
+
"RecurrenceException": null,
|
|
295
|
+
"IsAllDay": false
|
|
296
|
+
},
|
|
297
|
+
{
|
|
298
|
+
"TaskID": 32,
|
|
299
|
+
"OwnerID": 1,
|
|
300
|
+
"Title": "Job Interview - Bernard Atkins",
|
|
301
|
+
"Description": "Helpdesk",
|
|
302
|
+
"StartTimezone": null,
|
|
303
|
+
"Start": "2013-06-24T13:30:00.000Z",
|
|
304
|
+
"End": "2013-06-24T14:30:00.000Z",
|
|
305
|
+
"EndTimezone": null,
|
|
306
|
+
"RecurrenceRule": null,
|
|
307
|
+
"RecurrenceID": null,
|
|
308
|
+
"RecurrenceException": null,
|
|
309
|
+
"IsAllDay": false
|
|
310
|
+
},
|
|
311
|
+
{
|
|
312
|
+
"TaskID": 34,
|
|
313
|
+
"OwnerID": 1,
|
|
314
|
+
"Title": "Review Job Applications",
|
|
315
|
+
"Description": "",
|
|
316
|
+
"StartTimezone": null,
|
|
317
|
+
"Start": "2013-06-24T15:00:00.000Z",
|
|
318
|
+
"End": "2013-06-24T17:30:00.000Z",
|
|
319
|
+
"EndTimezone": null,
|
|
320
|
+
"RecurrenceRule": null,
|
|
321
|
+
"RecurrenceID": null,
|
|
322
|
+
"RecurrenceException": null,
|
|
323
|
+
"IsAllDay": false
|
|
324
|
+
},
|
|
325
|
+
{
|
|
326
|
+
"TaskID": 35,
|
|
327
|
+
"OwnerID": 1,
|
|
328
|
+
"Title": "Grand Canyon tour",
|
|
329
|
+
"Description": "",
|
|
330
|
+
"StartTimezone": null,
|
|
331
|
+
"Start": "2013-06-23T00:00:00.000Z",
|
|
332
|
+
"End": "2013-06-23T00:00:00.000Z",
|
|
333
|
+
"EndTimezone": null,
|
|
334
|
+
"RecurrenceRule": null,
|
|
335
|
+
"RecurrenceID": null,
|
|
336
|
+
"RecurrenceException": null,
|
|
337
|
+
"IsAllDay": true
|
|
338
|
+
},
|
|
339
|
+
{
|
|
340
|
+
"TaskID": 40,
|
|
341
|
+
"OwnerID": 3,
|
|
342
|
+
"Title": "Install new laptops in conference rooms",
|
|
343
|
+
"Description": "",
|
|
344
|
+
"StartTimezone": null,
|
|
345
|
+
"Start": "2013-06-24T13:30:00.000Z",
|
|
346
|
+
"End": "2013-06-24T18:00:00.000Z",
|
|
347
|
+
"EndTimezone": null,
|
|
348
|
+
"RecurrenceRule": null,
|
|
349
|
+
"RecurrenceID": null,
|
|
350
|
+
"RecurrenceException": null,
|
|
351
|
+
"IsAllDay": false
|
|
352
|
+
},
|
|
353
|
+
{
|
|
354
|
+
"TaskID": 66,
|
|
355
|
+
"OwnerID": 3,
|
|
356
|
+
"Title": "Bob's Birthday",
|
|
357
|
+
"Description": "",
|
|
358
|
+
"StartTimezone": null,
|
|
359
|
+
"Start": "2013-06-29T08:00:00.000Z",
|
|
360
|
+
"End": "2013-06-29T06:00:00.000Z",
|
|
361
|
+
"EndTimezone": null,
|
|
362
|
+
"RecurrenceRule": null,
|
|
363
|
+
"RecurrenceID": null,
|
|
364
|
+
"RecurrenceException": null,
|
|
365
|
+
"IsAllDay": true
|
|
366
|
+
},
|
|
367
|
+
{
|
|
368
|
+
"TaskID": 68,
|
|
369
|
+
"OwnerID": 1,
|
|
370
|
+
"RoomID": 2,
|
|
371
|
+
"Title": "Breakfast with Tom",
|
|
372
|
+
"Description": "",
|
|
373
|
+
"StartTimezone": null,
|
|
374
|
+
"Start": "2013-06-24T08:30:00.000Z",
|
|
375
|
+
"End": "2013-06-24T09:00:00.000Z",
|
|
376
|
+
"EndTimezone": null,
|
|
377
|
+
"RecurrenceRule": null,
|
|
378
|
+
"RecurrenceID": null,
|
|
379
|
+
"RecurrenceException": null,
|
|
380
|
+
"IsAllDay": false
|
|
381
|
+
},
|
|
382
|
+
{
|
|
383
|
+
"TaskID": 69,
|
|
384
|
+
"OwnerID": 2,
|
|
385
|
+
"Title": "Team planning meeting",
|
|
386
|
+
"Description": "",
|
|
387
|
+
"StartTimezone": null,
|
|
388
|
+
"Start": "2013-06-24T10:00:00.000Z",
|
|
389
|
+
"End": "2013-06-24T12:00:00.000Z",
|
|
390
|
+
"EndTimezone": null,
|
|
391
|
+
"RecurrenceRule": null,
|
|
392
|
+
"RecurrenceID": null,
|
|
393
|
+
"RecurrenceException": null,
|
|
394
|
+
"IsAllDay": false
|
|
395
|
+
},
|
|
396
|
+
{
|
|
397
|
+
"TaskID": 70,
|
|
398
|
+
"OwnerID": 2,
|
|
399
|
+
"Title": "Support Phone Call",
|
|
400
|
+
"Description": "",
|
|
401
|
+
"StartTimezone": null,
|
|
402
|
+
"Start": "2013-06-24T16:00:00.000Z",
|
|
403
|
+
"End": "2013-06-24T16:30:00.000Z",
|
|
404
|
+
"EndTimezone": null,
|
|
405
|
+
"RecurrenceRule": null,
|
|
406
|
+
"RecurrenceID": null,
|
|
407
|
+
"RecurrenceException": null,
|
|
408
|
+
"IsAllDay": false
|
|
409
|
+
},
|
|
410
|
+
{
|
|
411
|
+
"TaskID": 71,
|
|
412
|
+
"OwnerID": 2,
|
|
413
|
+
"Title": "Business breakfast with Caroline",
|
|
414
|
+
"Description": "",
|
|
415
|
+
"StartTimezone": null,
|
|
416
|
+
"Start": "2013-06-25T09:00:00.000Z",
|
|
417
|
+
"End": "2013-06-25T10:00:00.000Z",
|
|
418
|
+
"EndTimezone": null,
|
|
419
|
+
"RecurrenceRule": null,
|
|
420
|
+
"RecurrenceID": null,
|
|
421
|
+
"RecurrenceException": null,
|
|
422
|
+
"IsAllDay": false
|
|
423
|
+
},
|
|
424
|
+
{
|
|
425
|
+
"TaskID": 72,
|
|
426
|
+
"OwnerID": 2,
|
|
427
|
+
"Title": "Discuss preojects' deadlines",
|
|
428
|
+
"Description": "",
|
|
429
|
+
"StartTimezone": null,
|
|
430
|
+
"Start": "2013-06-25T11:00:00.000Z",
|
|
431
|
+
"End": "2013-06-25T11:30:00.000Z",
|
|
432
|
+
"EndTimezone": null,
|
|
433
|
+
"RecurrenceRule": null,
|
|
434
|
+
"RecurrenceID": null,
|
|
435
|
+
"RecurrenceException": null,
|
|
436
|
+
"IsAllDay": false
|
|
437
|
+
},
|
|
438
|
+
{
|
|
439
|
+
"TaskID": 73,
|
|
440
|
+
"OwnerID": 2,
|
|
441
|
+
"Title": "Support Meeting",
|
|
442
|
+
"Description": "",
|
|
443
|
+
"StartTimezone": null,
|
|
444
|
+
"Start": "2013-06-25T15:00:00.000Z",
|
|
445
|
+
"End": "2013-06-25T16:00:00.000Z",
|
|
446
|
+
"EndTimezone": null,
|
|
447
|
+
"RecurrenceRule": null,
|
|
448
|
+
"RecurrenceID": null,
|
|
449
|
+
"RecurrenceException": null,
|
|
450
|
+
"IsAllDay": false
|
|
451
|
+
},
|
|
452
|
+
{
|
|
453
|
+
"TaskID": 74,
|
|
454
|
+
"OwnerID": 2,
|
|
455
|
+
"Title": "Dine with Mathew",
|
|
456
|
+
"Description": "",
|
|
457
|
+
"StartTimezone": null,
|
|
458
|
+
"Start": "2013-06-25T18:30:00.000Z",
|
|
459
|
+
"End": "2013-06-25T20:00:00.000Z",
|
|
460
|
+
"EndTimezone": null,
|
|
461
|
+
"RecurrenceRule": null,
|
|
462
|
+
"RecurrenceID": null,
|
|
463
|
+
"RecurrenceException": null,
|
|
464
|
+
"IsAllDay": false
|
|
465
|
+
},
|
|
466
|
+
{
|
|
467
|
+
"TaskID": 79,
|
|
468
|
+
"OwnerID": 2,
|
|
469
|
+
"Title": "Banking",
|
|
470
|
+
"Description": "",
|
|
471
|
+
"StartTimezone": null,
|
|
472
|
+
"Start": "2013-06-26T09:00:00.000Z",
|
|
473
|
+
"End": "2013-06-26T10:00:00.000Z",
|
|
474
|
+
"EndTimezone": null,
|
|
475
|
+
"RecurrenceRule": null,
|
|
476
|
+
"RecurrenceID": null,
|
|
477
|
+
"RecurrenceException": null,
|
|
478
|
+
"IsAllDay": false
|
|
479
|
+
},
|
|
480
|
+
{
|
|
481
|
+
"TaskID": 80,
|
|
482
|
+
"OwnerID": 3,
|
|
483
|
+
"Title": "Software updates",
|
|
484
|
+
"Description": "",
|
|
485
|
+
"StartTimezone": null,
|
|
486
|
+
"Start": "2013-06-25T10:00:00.000Z",
|
|
487
|
+
"End": "2013-06-25T12:00:00.000Z",
|
|
488
|
+
"EndTimezone": null,
|
|
489
|
+
"RecurrenceRule": null,
|
|
490
|
+
"RecurrenceID": null,
|
|
491
|
+
"RecurrenceException": null,
|
|
492
|
+
"IsAllDay": false
|
|
493
|
+
},
|
|
494
|
+
{
|
|
495
|
+
"TaskID": 81,
|
|
496
|
+
"OwnerID": 3,
|
|
497
|
+
"Title": "UPS maintenance",
|
|
498
|
+
"Description": "",
|
|
499
|
+
"StartTimezone": null,
|
|
500
|
+
"Start": "2013-06-25T16:30:00.000Z",
|
|
501
|
+
"End": "2013-06-25T18:00:00.000Z",
|
|
502
|
+
"EndTimezone": null,
|
|
503
|
+
"RecurrenceRule": null,
|
|
504
|
+
"RecurrenceID": null,
|
|
505
|
+
"RecurrenceException": null,
|
|
506
|
+
"IsAllDay": false
|
|
507
|
+
},
|
|
508
|
+
{
|
|
509
|
+
"TaskID": 82,
|
|
510
|
+
"OwnerID": 2,
|
|
511
|
+
"Title": "Support Call",
|
|
512
|
+
"Description": "",
|
|
513
|
+
"StartTimezone": null,
|
|
514
|
+
"Start": "2013-06-26T11:30:00.000Z",
|
|
515
|
+
"End": "2013-06-26T12:00:00.000Z",
|
|
516
|
+
"EndTimezone": null,
|
|
517
|
+
"RecurrenceRule": null,
|
|
518
|
+
"RecurrenceID": null,
|
|
519
|
+
"RecurrenceException": null,
|
|
520
|
+
"IsAllDay": false
|
|
521
|
+
},
|
|
522
|
+
{
|
|
523
|
+
"TaskID": 83,
|
|
524
|
+
"OwnerID": 3,
|
|
525
|
+
"Title": "Phone Sync with NY office ",
|
|
526
|
+
"Description": "",
|
|
527
|
+
"StartTimezone": null,
|
|
528
|
+
"Start": "2013-06-26T13:30:00.000Z",
|
|
529
|
+
"End": "2013-06-26T14:30:00.000Z",
|
|
530
|
+
"EndTimezone": null,
|
|
531
|
+
"RecurrenceRule": null,
|
|
532
|
+
"RecurrenceID": null,
|
|
533
|
+
"RecurrenceException": null,
|
|
534
|
+
"IsAllDay": false
|
|
535
|
+
},
|
|
536
|
+
{
|
|
537
|
+
"TaskID": 84,
|
|
538
|
+
"OwnerID": 3,
|
|
539
|
+
"Title": "Phone Sync with Boston Office",
|
|
540
|
+
"Description": "",
|
|
541
|
+
"StartTimezone": null,
|
|
542
|
+
"Start": "2013-06-26T15:00:00.000Z",
|
|
543
|
+
"End": "2013-06-26T16:00:00.000Z",
|
|
544
|
+
"EndTimezone": null,
|
|
545
|
+
"RecurrenceRule": null,
|
|
546
|
+
"RecurrenceID": null,
|
|
547
|
+
"RecurrenceException": null,
|
|
548
|
+
"IsAllDay": false
|
|
549
|
+
},
|
|
550
|
+
{
|
|
551
|
+
"TaskID": 85,
|
|
552
|
+
"OwnerID": 3,
|
|
553
|
+
"Title": "Server maintenance",
|
|
554
|
+
"Description": "",
|
|
555
|
+
"StartTimezone": null,
|
|
556
|
+
"Start": "2013-06-26T18:30:00.000Z",
|
|
557
|
+
"End": "2013-06-26T21:30:00.000Z",
|
|
558
|
+
"EndTimezone": null,
|
|
559
|
+
"RecurrenceRule": null,
|
|
560
|
+
"RecurrenceID": null,
|
|
561
|
+
"RecurrenceException": null,
|
|
562
|
+
"IsAllDay": false
|
|
563
|
+
},
|
|
564
|
+
{
|
|
565
|
+
"TaskID": 86,
|
|
566
|
+
"OwnerID": 2,
|
|
567
|
+
"Title": "Status meeting",
|
|
568
|
+
"Description": "",
|
|
569
|
+
"StartTimezone": null,
|
|
570
|
+
"Start": "2013-06-28T13:30:00.000Z",
|
|
571
|
+
"End": "2013-06-28T15:30:00.000Z",
|
|
572
|
+
"EndTimezone": null,
|
|
573
|
+
"RecurrenceRule": null,
|
|
574
|
+
"RecurrenceID": null,
|
|
575
|
+
"RecurrenceException": null,
|
|
576
|
+
"IsAllDay": false
|
|
577
|
+
},
|
|
578
|
+
{
|
|
579
|
+
"TaskID": 87,
|
|
580
|
+
"OwnerID": 3,
|
|
581
|
+
"Title": "Helpdesk status meeting",
|
|
582
|
+
"Description": "",
|
|
583
|
+
"StartTimezone": null,
|
|
584
|
+
"Start": "2013-06-27T10:30:00.000Z",
|
|
585
|
+
"End": "2013-06-27T11:30:00.000Z",
|
|
586
|
+
"EndTimezone": null,
|
|
587
|
+
"RecurrenceRule": null,
|
|
588
|
+
"RecurrenceID": null,
|
|
589
|
+
"RecurrenceException": null,
|
|
590
|
+
"IsAllDay": false
|
|
591
|
+
},
|
|
592
|
+
{
|
|
593
|
+
"TaskID": 88,
|
|
594
|
+
"OwnerID": 2,
|
|
595
|
+
"Title": "Business Lunch",
|
|
596
|
+
"Description": "",
|
|
597
|
+
"StartTimezone": null,
|
|
598
|
+
"Start": "2013-06-27T12:00:00.000Z",
|
|
599
|
+
"End": "2013-06-27T13:00:00.000Z",
|
|
600
|
+
"EndTimezone": null,
|
|
601
|
+
"RecurrenceRule": null,
|
|
602
|
+
"RecurrenceID": null,
|
|
603
|
+
"RecurrenceException": null,
|
|
604
|
+
"IsAllDay": false
|
|
605
|
+
},
|
|
606
|
+
{
|
|
607
|
+
"TaskID": 89,
|
|
608
|
+
"OwnerID": 3,
|
|
609
|
+
"Title": "Employee database update",
|
|
610
|
+
"Description": "",
|
|
611
|
+
"StartTimezone": null,
|
|
612
|
+
"Start": "2013-06-27T14:00:00.000Z",
|
|
613
|
+
"End": "2013-06-27T15:30:00.000Z",
|
|
614
|
+
"EndTimezone": null,
|
|
615
|
+
"RecurrenceRule": null,
|
|
616
|
+
"RecurrenceID": null,
|
|
617
|
+
"RecurrenceException": null,
|
|
618
|
+
"IsAllDay": false
|
|
619
|
+
},
|
|
620
|
+
{
|
|
621
|
+
"TaskID": 90,
|
|
622
|
+
"OwnerID": 3,
|
|
623
|
+
"Title": "Website upload",
|
|
624
|
+
"Description": "",
|
|
625
|
+
"StartTimezone": null,
|
|
626
|
+
"Start": "2013-06-27T07:30:00.000Z",
|
|
627
|
+
"End": "2013-06-27T08:30:00.000Z",
|
|
628
|
+
"EndTimezone": null,
|
|
629
|
+
"RecurrenceRule": null,
|
|
630
|
+
"RecurrenceID": null,
|
|
631
|
+
"RecurrenceException": null,
|
|
632
|
+
"IsAllDay": false
|
|
633
|
+
},
|
|
634
|
+
{
|
|
635
|
+
"TaskID": 91,
|
|
636
|
+
"OwnerID": 2,
|
|
637
|
+
"Title": "Meeting with marketing guys",
|
|
638
|
+
"Description": "",
|
|
639
|
+
"StartTimezone": null,
|
|
640
|
+
"Start": "2013-06-27T17:00:00.000Z",
|
|
641
|
+
"End": "2013-06-27T18:30:00.000Z",
|
|
642
|
+
"EndTimezone": null,
|
|
643
|
+
"RecurrenceRule": null,
|
|
644
|
+
"RecurrenceID": null,
|
|
645
|
+
"RecurrenceException": null,
|
|
646
|
+
"IsAllDay": false
|
|
647
|
+
},
|
|
648
|
+
{
|
|
649
|
+
"TaskID": 92,
|
|
650
|
+
"OwnerID": 3,
|
|
651
|
+
"Title": "Meeting with Internet provider",
|
|
652
|
+
"Description": "",
|
|
653
|
+
"StartTimezone": null,
|
|
654
|
+
"Start": "2013-06-28T10:30:00.000Z",
|
|
655
|
+
"End": "2013-06-28T11:30:00.000Z",
|
|
656
|
+
"EndTimezone": null,
|
|
657
|
+
"RecurrenceRule": null,
|
|
658
|
+
"RecurrenceID": null,
|
|
659
|
+
"RecurrenceException": null,
|
|
660
|
+
"IsAllDay": false
|
|
661
|
+
},
|
|
662
|
+
{
|
|
663
|
+
"TaskID": 93,
|
|
664
|
+
"OwnerID": 3,
|
|
665
|
+
"Title": "Bob's Birthday Party",
|
|
666
|
+
"Description": "",
|
|
667
|
+
"StartTimezone": null,
|
|
668
|
+
"Start": "2013-06-29T20:00:00.000Z",
|
|
669
|
+
"End": "2013-06-29T23:30:00.000Z",
|
|
670
|
+
"EndTimezone": null,
|
|
671
|
+
"RecurrenceRule": null,
|
|
672
|
+
"RecurrenceID": null,
|
|
673
|
+
"RecurrenceException": null,
|
|
674
|
+
"IsAllDay": false
|
|
675
|
+
},
|
|
676
|
+
{
|
|
677
|
+
"TaskID": 95,
|
|
678
|
+
"OwnerID": 2,
|
|
679
|
+
"Title": "Dance Practice",
|
|
680
|
+
"Description": "",
|
|
681
|
+
"StartTimezone": null,
|
|
682
|
+
"Start": "2013-06-03T18:30:00.000Z",
|
|
683
|
+
"End": "2013-06-03T20:00:00.000Z",
|
|
684
|
+
"EndTimezone": null,
|
|
685
|
+
"RecurrenceRule": "FREQ=WEEKLY;BYDAY=MO,WE",
|
|
686
|
+
"RecurrenceID": null,
|
|
687
|
+
"RecurrenceException": null,
|
|
688
|
+
"IsAllDay": false
|
|
689
|
+
},
|
|
690
|
+
{
|
|
691
|
+
"TaskID": 114,
|
|
692
|
+
"OwnerID": 3,
|
|
693
|
+
"Title": "Software updates",
|
|
694
|
+
"Description": "",
|
|
695
|
+
"StartTimezone": null,
|
|
696
|
+
"Start": "2013-06-04T09:00:00.000Z",
|
|
697
|
+
"End": "2013-06-04T12:00:00.000Z",
|
|
698
|
+
"EndTimezone": null,
|
|
699
|
+
"RecurrenceRule": "",
|
|
700
|
+
"RecurrenceID": null,
|
|
701
|
+
"RecurrenceException": null,
|
|
702
|
+
"IsAllDay": false
|
|
703
|
+
},
|
|
704
|
+
{
|
|
705
|
+
"TaskID": 115,
|
|
706
|
+
"OwnerID": 1,
|
|
707
|
+
"Title": "Breakfast at Starbucks",
|
|
708
|
+
"Description": "",
|
|
709
|
+
"StartTimezone": null,
|
|
710
|
+
"Start": "2013-06-04T08:00:00.000Z",
|
|
711
|
+
"End": "2013-06-04T09:30:00.000Z",
|
|
712
|
+
"EndTimezone": null,
|
|
713
|
+
"RecurrenceRule": "",
|
|
714
|
+
"RecurrenceID": null,
|
|
715
|
+
"RecurrenceException": null,
|
|
716
|
+
"IsAllDay": false
|
|
717
|
+
},
|
|
718
|
+
{
|
|
719
|
+
"TaskID": 116,
|
|
720
|
+
"OwnerID": 2,
|
|
721
|
+
"Title": "Performance review",
|
|
722
|
+
"Description": "",
|
|
723
|
+
"StartTimezone": null,
|
|
724
|
+
"Start": "2013-06-04T14:00:00.000Z",
|
|
725
|
+
"End": "2013-06-04T17:00:00.000Z",
|
|
726
|
+
"EndTimezone": null,
|
|
727
|
+
"RecurrenceRule": "",
|
|
728
|
+
"RecurrenceID": null,
|
|
729
|
+
"RecurrenceException": null,
|
|
730
|
+
"IsAllDay": false
|
|
731
|
+
},
|
|
732
|
+
{
|
|
733
|
+
"TaskID": 118,
|
|
734
|
+
"OwnerID": 1,
|
|
735
|
+
"Title": "HR seminar preparation",
|
|
736
|
+
"Description": "",
|
|
737
|
+
"StartTimezone": null,
|
|
738
|
+
"Start": "2013-06-05T10:00:00.000Z",
|
|
739
|
+
"End": "2013-06-05T12:00:00.000Z",
|
|
740
|
+
"EndTimezone": null,
|
|
741
|
+
"RecurrenceRule": "",
|
|
742
|
+
"RecurrenceID": null,
|
|
743
|
+
"RecurrenceException": null,
|
|
744
|
+
"IsAllDay": false
|
|
745
|
+
},
|
|
746
|
+
{
|
|
747
|
+
"TaskID": 119,
|
|
748
|
+
"OwnerID": 3,
|
|
749
|
+
"Title": "Helpdesk weekly meeting",
|
|
750
|
+
"Description": "",
|
|
751
|
+
"StartTimezone": null,
|
|
752
|
+
"Start": "2013-06-05T15:00:00.000Z",
|
|
753
|
+
"End": "2013-06-05T16:00:00.000Z",
|
|
754
|
+
"EndTimezone": null,
|
|
755
|
+
"RecurrenceRule": "FREQ=WEEKLY;BYDAY=WE",
|
|
756
|
+
"RecurrenceID": null,
|
|
757
|
+
"RecurrenceException": null,
|
|
758
|
+
"IsAllDay": false
|
|
759
|
+
},
|
|
760
|
+
{
|
|
761
|
+
"TaskID": 120,
|
|
762
|
+
"OwnerID": 3,
|
|
763
|
+
"Title": "Website upload",
|
|
764
|
+
"Description": "",
|
|
765
|
+
"StartTimezone": null,
|
|
766
|
+
"Start": "2013-06-07T07:00:00.000Z",
|
|
767
|
+
"End": "2013-06-07T08:30:00.000Z",
|
|
768
|
+
"EndTimezone": null,
|
|
769
|
+
"RecurrenceRule": "",
|
|
770
|
+
"RecurrenceID": null,
|
|
771
|
+
"RecurrenceException": null,
|
|
772
|
+
"IsAllDay": false
|
|
773
|
+
}
|
|
774
|
+
];
|
|
775
|
+
const currentYear = new Date().getFullYear();
|
|
776
|
+
const parseAdjust = (eventDate) => {
|
|
777
|
+
const date = new Date(eventDate);
|
|
778
|
+
date.setFullYear(currentYear);
|
|
779
|
+
return date;
|
|
780
|
+
};
|
|
781
|
+
const randomInt = (min, max) => {
|
|
782
|
+
return Math.floor(Math.random() * (max - min + 1)) + min;
|
|
783
|
+
};
|
|
784
|
+
export const displayDate = new Date(2024, 3, 15);
|
|
785
|
+
export const sampleData = baseData.map(dataItem => ({
|
|
786
|
+
id: dataItem.TaskID,
|
|
787
|
+
start: parseAdjust(dataItem.Start),
|
|
788
|
+
startTimezone: dataItem.startTimezone,
|
|
789
|
+
end: parseAdjust(dataItem.End),
|
|
790
|
+
endTimezone: dataItem.endTimezone,
|
|
791
|
+
isAllDay: dataItem.IsAllDay,
|
|
792
|
+
title: dataItem.Title,
|
|
793
|
+
description: dataItem.Description,
|
|
794
|
+
recurrenceRule: dataItem.RecurrenceRule,
|
|
795
|
+
recurrenceId: dataItem.RecurrenceID,
|
|
796
|
+
recurrenceException: dataItem.RecurrenceException,
|
|
797
|
+
roomId: dataItem.RoomID,
|
|
798
|
+
ownerID: dataItem.OwnerID
|
|
799
|
+
}));
|
|
800
|
+
export const sampleDataWithResources = baseData.map(dataItem => ({
|
|
801
|
+
id: dataItem.TaskID,
|
|
802
|
+
start: parseAdjust(dataItem.Start),
|
|
803
|
+
startTimezone: dataItem.startTimezone,
|
|
804
|
+
end: parseAdjust(dataItem.End),
|
|
805
|
+
endTimezone: dataItem.endTimezone,
|
|
806
|
+
isAllDay: dataItem.IsAllDay,
|
|
807
|
+
title: dataItem.Title,
|
|
808
|
+
description: dataItem.Description,
|
|
809
|
+
recurrenceRule: dataItem.RecurrenceRule,
|
|
810
|
+
recurrenceId: dataItem.RecurrenceID,
|
|
811
|
+
recurrenceException: dataItem.RecurrenceException,
|
|
812
|
+
roomId: randomInt(1, 2),
|
|
813
|
+
attendees: [randomInt(1, 3)]
|
|
814
|
+
}));
|
|
815
|
+
export const sampleDataWithCustomSchema = baseData.map(dataItem => (Object.assign(Object.assign({}, dataItem), { Start: parseAdjust(dataItem.Start), End: parseAdjust(dataItem.End) })));
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
import { AfterViewInit } from '@angular/core';
|
|
2
|
+
import { BaseEntity, RunViewParams } from '@memberjunction/core';
|
|
3
|
+
import { SchedulerEvent } from '@progress/kendo-angular-scheduler';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
/**
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
export declare class TimelineGroup {
|
|
9
|
+
/**
|
|
10
|
+
* Entity name for the type of records to be displayed in this group
|
|
11
|
+
*/
|
|
12
|
+
EntityName: string;
|
|
13
|
+
/**
|
|
14
|
+
* The actual data you want displayed in this group. This is an array of BaseEntity objects that will be displayed in the timeline. You can populate this array from a view or any other source.
|
|
15
|
+
*/
|
|
16
|
+
EntityObjects: BaseEntity[];
|
|
17
|
+
/**
|
|
18
|
+
* The name of the field in the entity that contains the title of the record that will be displayed in the timeline
|
|
19
|
+
*/
|
|
20
|
+
TitleFieldName: string;
|
|
21
|
+
/**
|
|
22
|
+
* The name of the field in the entity that contains the date that will be used for the ordering in the timeline
|
|
23
|
+
*/
|
|
24
|
+
DateFieldName: string;
|
|
25
|
+
/**
|
|
26
|
+
* Use standard or custom icons, if custom is specified, the DisplayIcon property must be set
|
|
27
|
+
*/
|
|
28
|
+
DisplayIconMode: 'standard' | 'custom';
|
|
29
|
+
/**
|
|
30
|
+
* Only used if DisplayIconMode is set to custom, the CSS class name to use from Font Awesome (or any other library that has styles pre-loaded), for the span that will be shown
|
|
31
|
+
*/
|
|
32
|
+
DisplayIcon?: string;
|
|
33
|
+
/**
|
|
34
|
+
* Color mode for items in this group, defaults to auto-selected in which case the color will be determined by the system automatically based on the # of groups
|
|
35
|
+
*/
|
|
36
|
+
DisplayColorMode: 'auto' | 'manual';
|
|
37
|
+
/**
|
|
38
|
+
* Only used if DisplayColorMode is set to manual, the color to use for the items in this group. Any valid color string that can be set into the element style via CSS is valid here.
|
|
39
|
+
*/
|
|
40
|
+
DisplayColor?: string;
|
|
41
|
+
/**
|
|
42
|
+
* When set to field, the SummaryFieldName will be used to display detailed information about the record in the timeline. If set to custom, you need to provide
|
|
43
|
+
* a function for the SummaryFunction property. If set to none, no summary will be displayed.
|
|
44
|
+
*/
|
|
45
|
+
SummaryMode: 'field' | 'custom' | 'none';
|
|
46
|
+
/**
|
|
47
|
+
* When SummaryMode is set to 'custom', this function will be used to generate the summary for the record. The function should take a single parameter, the BaseEntity object and will return a string.
|
|
48
|
+
* The string returned can be plain text or HTML and will be displayed in the timeline.
|
|
49
|
+
*/
|
|
50
|
+
SummaryFunction?: ((record: BaseEntity) => string) | undefined;
|
|
51
|
+
/**
|
|
52
|
+
* Creates a new instance of the TimelineGroup class using the information from the RunViewParams provided.
|
|
53
|
+
* After receiving back the new object, you can set other properties of the new instance as appropriate.
|
|
54
|
+
* @param params
|
|
55
|
+
* @returns
|
|
56
|
+
*/
|
|
57
|
+
static FromView(params: RunViewParams): Promise<TimelineGroup>;
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* Displays data on a timeline UI so that information can see a chronolgoical display of the provided data.
|
|
61
|
+
*/
|
|
62
|
+
export declare class TimelineComponent implements AfterViewInit {
|
|
63
|
+
private _groups;
|
|
64
|
+
/**
|
|
65
|
+
* Provide an array of one or more TimelineGroup objects to display the data in the timeline. Each group will be displayed in a different color and icon.
|
|
66
|
+
*/
|
|
67
|
+
get Groups(): TimelineGroup[];
|
|
68
|
+
set Groups(value: TimelineGroup[]);
|
|
69
|
+
private _deferLoadCount;
|
|
70
|
+
private _allowLoad;
|
|
71
|
+
/**
|
|
72
|
+
* Set this property to false to prevent the timeline from loading the data. This is useful when you want to load the data yourself and then set this property to true to display the data.
|
|
73
|
+
*/
|
|
74
|
+
get AllowLoad(): boolean;
|
|
75
|
+
set AllowLoad(value: boolean);
|
|
76
|
+
selectedDate: Date;
|
|
77
|
+
events: SchedulerEvent[];
|
|
78
|
+
ngAfterViewInit(): void;
|
|
79
|
+
/**
|
|
80
|
+
* This method refreshes the timeline with the data from the provided parameters.
|
|
81
|
+
*/
|
|
82
|
+
Refresh(): void;
|
|
83
|
+
protected LoadSingleGroup(group: TimelineGroup): void;
|
|
84
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<TimelineComponent, never>;
|
|
85
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<TimelineComponent, "mj-timeline", never, { "Groups": { "alias": "Groups"; "required": false; }; "AllowLoad": { "alias": "AllowLoad"; "required": false; }; }, {}, never, never, false, never>;
|
|
86
|
+
}
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
2
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
3
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
4
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
5
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
6
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
7
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
import { Component, Input } from '@angular/core';
|
|
11
|
+
import { RunView } from '@memberjunction/core';
|
|
12
|
+
import * as i0 from "@angular/core";
|
|
13
|
+
import * as i1 from "@memberjunction/ng-container-directives";
|
|
14
|
+
import * as i2 from "@progress/kendo-angular-scheduler";
|
|
15
|
+
function TimelineComponent_ng_template_2_Template(rf, ctx) { if (rf & 1) {
|
|
16
|
+
i0.ɵɵelementStart(0, "span", 3);
|
|
17
|
+
i0.ɵɵtext(1);
|
|
18
|
+
i0.ɵɵelementEnd();
|
|
19
|
+
} if (rf & 2) {
|
|
20
|
+
const event_r1 = ctx.event;
|
|
21
|
+
i0.ɵɵadvance();
|
|
22
|
+
i0.ɵɵtextInterpolate(event_r1.title);
|
|
23
|
+
} }
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
*/
|
|
27
|
+
export class TimelineGroup {
|
|
28
|
+
constructor() {
|
|
29
|
+
/**
|
|
30
|
+
* The actual data you want displayed in this group. This is an array of BaseEntity objects that will be displayed in the timeline. You can populate this array from a view or any other source.
|
|
31
|
+
*/
|
|
32
|
+
this.EntityObjects = [];
|
|
33
|
+
/**
|
|
34
|
+
* Use standard or custom icons, if custom is specified, the DisplayIcon property must be set
|
|
35
|
+
*/
|
|
36
|
+
this.DisplayIconMode = 'standard';
|
|
37
|
+
/**
|
|
38
|
+
* Color mode for items in this group, defaults to auto-selected in which case the color will be determined by the system automatically based on the # of groups
|
|
39
|
+
*/
|
|
40
|
+
this.DisplayColorMode = 'auto';
|
|
41
|
+
/**
|
|
42
|
+
* When set to field, the SummaryFieldName will be used to display detailed information about the record in the timeline. If set to custom, you need to provide
|
|
43
|
+
* a function for the SummaryFunction property. If set to none, no summary will be displayed.
|
|
44
|
+
*/
|
|
45
|
+
this.SummaryMode = 'field';
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Creates a new instance of the TimelineGroup class using the information from the RunViewParams provided.
|
|
49
|
+
* After receiving back the new object, you can set other properties of the new instance as appropriate.
|
|
50
|
+
* @param params
|
|
51
|
+
* @returns
|
|
52
|
+
*/
|
|
53
|
+
static FromView(params) {
|
|
54
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
55
|
+
const group = new TimelineGroup();
|
|
56
|
+
const rv = new RunView();
|
|
57
|
+
params.ResultType = 'entity_object'; // this might be already set but we want to make sure of it
|
|
58
|
+
const result = yield rv.RunView(params);
|
|
59
|
+
if (result && result.Success) {
|
|
60
|
+
group.EntityName = yield RunView.GetEntityNameFromRunViewParams(params);
|
|
61
|
+
group.EntityObjects = result.Results;
|
|
62
|
+
}
|
|
63
|
+
return group;
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
/**
|
|
68
|
+
* Displays data on a timeline UI so that information can see a chronolgoical display of the provided data.
|
|
69
|
+
*/
|
|
70
|
+
export class TimelineComponent {
|
|
71
|
+
constructor() {
|
|
72
|
+
this._groups = [];
|
|
73
|
+
this._deferLoadCount = 0;
|
|
74
|
+
this._allowLoad = true;
|
|
75
|
+
this.selectedDate = new Date();
|
|
76
|
+
this.events = [];
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Provide an array of one or more TimelineGroup objects to display the data in the timeline. Each group will be displayed in a different color and icon.
|
|
80
|
+
*/
|
|
81
|
+
get Groups() {
|
|
82
|
+
return this._groups;
|
|
83
|
+
}
|
|
84
|
+
set Groups(value) {
|
|
85
|
+
this._groups = value;
|
|
86
|
+
if (this.AllowLoad)
|
|
87
|
+
this.Refresh();
|
|
88
|
+
}
|
|
89
|
+
/**
|
|
90
|
+
* Set this property to false to prevent the timeline from loading the data. This is useful when you want to load the data yourself and then set this property to true to display the data.
|
|
91
|
+
*/
|
|
92
|
+
get AllowLoad() {
|
|
93
|
+
return this._allowLoad;
|
|
94
|
+
}
|
|
95
|
+
set AllowLoad(value) {
|
|
96
|
+
this._allowLoad = value;
|
|
97
|
+
if (value === true && this._deferLoadCount === 0) {
|
|
98
|
+
this._deferLoadCount++; // only do this one time
|
|
99
|
+
this.Refresh();
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
ngAfterViewInit() {
|
|
103
|
+
if (this.AllowLoad)
|
|
104
|
+
this.Refresh();
|
|
105
|
+
}
|
|
106
|
+
/**
|
|
107
|
+
* This method refreshes the timeline with the data from the provided parameters.
|
|
108
|
+
*/
|
|
109
|
+
Refresh() {
|
|
110
|
+
if (this.Groups && this.Groups.length > 0) {
|
|
111
|
+
this.Groups.forEach(g => this.LoadSingleGroup(g));
|
|
112
|
+
// now get the highest date from the events array and set that into the selectedDate
|
|
113
|
+
if (this.events.length > 0) {
|
|
114
|
+
this.selectedDate = this.events.reduce((a, b) => a.start > b.start ? a : b).start;
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
LoadSingleGroup(group) {
|
|
119
|
+
this.events = group.EntityObjects.map(e => {
|
|
120
|
+
let date = new Date(e.Get(group.DateFieldName));
|
|
121
|
+
let title = e.Get(group.TitleFieldName);
|
|
122
|
+
let summary = "";
|
|
123
|
+
if (group.SummaryMode == 'field') {
|
|
124
|
+
summary = e.Get(group.TitleFieldName);
|
|
125
|
+
}
|
|
126
|
+
else if (group.SummaryMode == 'custom' && group.SummaryFunction) {
|
|
127
|
+
summary = group.SummaryFunction(e);
|
|
128
|
+
}
|
|
129
|
+
return {
|
|
130
|
+
id: e.Get("ID"),
|
|
131
|
+
title: title,
|
|
132
|
+
start: date,
|
|
133
|
+
end: date,
|
|
134
|
+
isAllDay: true,
|
|
135
|
+
description: summary,
|
|
136
|
+
color: group.DisplayColor,
|
|
137
|
+
icon: group.DisplayIcon,
|
|
138
|
+
};
|
|
139
|
+
});
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
TimelineComponent.ɵfac = function TimelineComponent_Factory(t) { return new (t || TimelineComponent)(); };
|
|
143
|
+
TimelineComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: TimelineComponent, selectors: [["mj-timeline"]], inputs: { Groups: "Groups", AllowLoad: "AllowLoad" }, decls: 4, vars: 2, consts: [["mjFillContainer", "", 1, "wrapper"], [3, "events", "selectedDate"], ["kendoSchedulerAllDayEventTemplate", ""], [2, "color", "yellow"]], template: function TimelineComponent_Template(rf, ctx) { if (rf & 1) {
|
|
144
|
+
i0.ɵɵelementStart(0, "div", 0)(1, "kendo-scheduler", 1);
|
|
145
|
+
i0.ɵɵtemplate(2, TimelineComponent_ng_template_2_Template, 2, 1, "ng-template", 2);
|
|
146
|
+
i0.ɵɵelement(3, "kendo-scheduler-week-view");
|
|
147
|
+
i0.ɵɵelementEnd()();
|
|
148
|
+
} if (rf & 2) {
|
|
149
|
+
i0.ɵɵadvance();
|
|
150
|
+
i0.ɵɵproperty("events", ctx.events)("selectedDate", ctx.selectedDate);
|
|
151
|
+
} }, dependencies: [i1.FillContainer, i2.WeekViewComponent, i2.SchedulerComponent, i2.ShortcutsDirective, i2.AllDayEventTemplateDirective] });
|
|
152
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TimelineComponent, [{
|
|
153
|
+
type: Component,
|
|
154
|
+
args: [{ selector: 'mj-timeline', template: "<div mjFillContainer class=\"wrapper\"> \n <kendo-scheduler\n [events]=\"events\"\n [selectedDate]=\"selectedDate\"\n >\n <ng-template kendoSchedulerAllDayEventTemplate let-event=\"event\">\n <span style=\"color:yellow;\">{{ event.title }}</span>\n </ng-template>\n <kendo-scheduler-week-view> </kendo-scheduler-week-view>\n </kendo-scheduler>\n</div> " }]
|
|
155
|
+
}], null, { Groups: [{
|
|
156
|
+
type: Input
|
|
157
|
+
}], AllowLoad: [{
|
|
158
|
+
type: Input
|
|
159
|
+
}] }); })();
|
|
160
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(TimelineComponent, { className: "TimelineComponent", filePath: "src/lib/component/timeline.component.ts", lineNumber: 85 }); })();
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import * as i1 from "./component/timeline.component";
|
|
3
|
+
import * as i2 from "@angular/common";
|
|
4
|
+
import * as i3 from "@memberjunction/ng-container-directives";
|
|
5
|
+
import * as i4 from "@progress/kendo-angular-buttons";
|
|
6
|
+
import * as i5 from "@memberjunction/ng-entity-form-dialog";
|
|
7
|
+
import * as i6 from "@progress/kendo-angular-indicators";
|
|
8
|
+
import * as i7 from "@progress/kendo-angular-layout";
|
|
9
|
+
import * as i8 from "@progress/kendo-angular-scheduler";
|
|
10
|
+
export declare class TimelineModule {
|
|
11
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<TimelineModule, never>;
|
|
12
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<TimelineModule, [typeof i1.TimelineComponent], [typeof i2.CommonModule, typeof i3.ContainerDirectivesModule, typeof i4.ButtonsModule, typeof i5.EntityFormDialogModule, typeof i6.IndicatorsModule, typeof i7.LayoutModule, typeof i8.SchedulerModule], [typeof i1.TimelineComponent]>;
|
|
13
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<TimelineModule>;
|
|
14
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { NgModule } from '@angular/core';
|
|
2
|
+
import { CommonModule } from '@angular/common';
|
|
3
|
+
// Kendo UI Angular imports
|
|
4
|
+
import { ButtonsModule } from '@progress/kendo-angular-buttons';
|
|
5
|
+
import { IndicatorsModule } from '@progress/kendo-angular-indicators';
|
|
6
|
+
import { LayoutModule } from '@progress/kendo-angular-layout';
|
|
7
|
+
import { SchedulerModule } from '@progress/kendo-angular-scheduler';
|
|
8
|
+
// MJ
|
|
9
|
+
import { ContainerDirectivesModule } from '@memberjunction/ng-container-directives';
|
|
10
|
+
import { EntityFormDialogModule } from '@memberjunction/ng-entity-form-dialog';
|
|
11
|
+
// LOCAL
|
|
12
|
+
import { TimelineComponent } from './component/timeline.component';
|
|
13
|
+
import * as i0 from "@angular/core";
|
|
14
|
+
export class TimelineModule {
|
|
15
|
+
}
|
|
16
|
+
TimelineModule.ɵfac = function TimelineModule_Factory(t) { return new (t || TimelineModule)(); };
|
|
17
|
+
TimelineModule.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: TimelineModule });
|
|
18
|
+
TimelineModule.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [CommonModule,
|
|
19
|
+
ContainerDirectivesModule,
|
|
20
|
+
ButtonsModule,
|
|
21
|
+
EntityFormDialogModule,
|
|
22
|
+
IndicatorsModule,
|
|
23
|
+
LayoutModule,
|
|
24
|
+
SchedulerModule] });
|
|
25
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TimelineModule, [{
|
|
26
|
+
type: NgModule,
|
|
27
|
+
args: [{
|
|
28
|
+
declarations: [
|
|
29
|
+
TimelineComponent
|
|
30
|
+
],
|
|
31
|
+
imports: [
|
|
32
|
+
CommonModule,
|
|
33
|
+
ContainerDirectivesModule,
|
|
34
|
+
ButtonsModule,
|
|
35
|
+
EntityFormDialogModule,
|
|
36
|
+
IndicatorsModule,
|
|
37
|
+
LayoutModule,
|
|
38
|
+
SchedulerModule
|
|
39
|
+
],
|
|
40
|
+
exports: [
|
|
41
|
+
TimelineComponent
|
|
42
|
+
]
|
|
43
|
+
}]
|
|
44
|
+
}], null, null); })();
|
|
45
|
+
(function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(TimelineModule, { declarations: [TimelineComponent], imports: [CommonModule,
|
|
46
|
+
ContainerDirectivesModule,
|
|
47
|
+
ButtonsModule,
|
|
48
|
+
EntityFormDialogModule,
|
|
49
|
+
IndicatorsModule,
|
|
50
|
+
LayoutModule,
|
|
51
|
+
SchedulerModule], exports: [TimelineComponent] }); })();
|
package/package.json
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@memberjunction/ng-timeline",
|
|
3
|
+
"version": "1.4.1",
|
|
4
|
+
"description": "MemberJunction: Timeline Display UI component",
|
|
5
|
+
"main": "./dist/public-api.js",
|
|
6
|
+
"typings": "./dist/public-api.d.ts",
|
|
7
|
+
"files": [
|
|
8
|
+
"/dist"
|
|
9
|
+
],
|
|
10
|
+
"scripts": {
|
|
11
|
+
"test": "echo \"Error: no test specified\" && exit 1",
|
|
12
|
+
"build": "ngc"
|
|
13
|
+
},
|
|
14
|
+
"keywords": [],
|
|
15
|
+
"author": "",
|
|
16
|
+
"license": "ISC",
|
|
17
|
+
"devDependencies": {
|
|
18
|
+
"@angular/compiler": "~17.2.2",
|
|
19
|
+
"@angular/compiler-cli": "~17.2.2"
|
|
20
|
+
},
|
|
21
|
+
"peerDependencies": {
|
|
22
|
+
"@angular/common": "~17.2.2",
|
|
23
|
+
"@angular/core": "~17.2.2",
|
|
24
|
+
"@angular/forms": "~17.2.2",
|
|
25
|
+
"@angular/router": "~17.2.2"
|
|
26
|
+
},
|
|
27
|
+
"dependencies": {
|
|
28
|
+
"@memberjunction/core-entities": "~1.4.1",
|
|
29
|
+
"@memberjunction/global": "~1.4.1",
|
|
30
|
+
"@memberjunction/core": "~1.4.1",
|
|
31
|
+
"@memberjunction/ng-container-directives": "~1.4.1",
|
|
32
|
+
"@memberjunction/ng-entity-form-dialog": "~1.4.1",
|
|
33
|
+
"@memberjunction/ng-shared": "~1.4.1",
|
|
34
|
+
"@progress/kendo-angular-buttons": "~15.1.0",
|
|
35
|
+
"@progress/kendo-angular-layout": "~15.1.0",
|
|
36
|
+
"@progress/kendo-angular-indicators": "~15.1.0",
|
|
37
|
+
"@progress/kendo-angular-scheduler": "~15.1.0",
|
|
38
|
+
"tslib": "^2.3.0"
|
|
39
|
+
},
|
|
40
|
+
"sideEffects": false
|
|
41
|
+
}
|