@royalschedule/maps 2.5.7 → 2.6.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/RS/v2/from/index.d.ts +5 -5
- package/dist/RS/v2/from/schedules.d.ts +2 -2
- package/dist/SS12000/to/index.d.ts +1 -1
- package/dist/core/v1/from/courses.d.ts +4 -4
- package/dist/core/v1/from/events.d.ts +6 -6
- package/dist/core/v1/from/groups.d.ts +2 -2
- package/dist/core/v1/from/overlap-groups.d.ts +1 -1
- package/dist/core/v1/from/schedules.d.ts +13 -13
- package/dist/core/v1/to/courses.d.ts +4 -4
- package/dist/core/v1/to/events.d.ts +6 -6
- package/dist/core/v1/to/groups.d.ts +2 -2
- package/dist/core/v1/to/schedules.d.ts +13 -13
- package/dist/core/v2/from/calendar-exceptions.d.ts +46 -0
- package/dist/core/v2/from/calendar-exceptions.js +31 -0
- package/dist/core/v2/from/calendar-exceptions.js.map +1 -0
- package/dist/core/v2/from/courses.d.ts +4 -4
- package/dist/core/v2/from/events.d.ts +6 -6
- package/dist/core/v2/from/groups.d.ts +2 -2
- package/dist/core/v2/from/overlap-groups.d.ts +1 -1
- package/dist/core/v2/from/schedules.d.ts +14 -13
- package/dist/core/v2/from/schedules.js +9 -2
- package/dist/core/v2/from/schedules.js.map +1 -1
- package/dist/core/v2/to/calendar-exceptions.d.ts +4 -0
- package/dist/core/v2/to/calendar-exceptions.js +44 -0
- package/dist/core/v2/to/calendar-exceptions.js.map +1 -0
- package/dist/core/v2/to/courses.d.ts +4 -4
- package/dist/core/v2/to/events.d.ts +6 -6
- package/dist/core/v2/to/groups.d.ts +2 -2
- package/dist/core/v2/to/schedules.d.ts +14 -13
- package/dist/core/v2/to/schedules.js +6 -2
- package/dist/core/v2/to/schedules.js.map +1 -1
- package/dist/core/v2/types/calendar-exceptions.d.ts +31 -0
- package/dist/core/v2/types/calendar-exceptions.js +6 -0
- package/dist/core/v2/types/calendar-exceptions.js.map +1 -0
- package/dist/core/v2/types/index.d.ts +2 -0
- package/dist/core/v2/types/schedules.d.ts +2 -0
- package/package.json +1 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
export default class {
|
|
2
2
|
static availableDependency: (data: any, settings: import("../types/settings").Settings) => any;
|
|
3
|
-
static courseEvent: (courseEvents: (number | import("../types/course-events").CourseEvent)[], course: import("../types/collections").Collection, teachersList: string[], groupsList: string[], settings: import("../types/settings").Settings, overlapGroup?: number | null) => (import("../../../core/types").Deserialized<Omit<import("../../../core/v2/types/events").Event, "groups" | "
|
|
4
|
-
static collection: (courses: (import("../types/course-events").CourseEvent | import("../types/collections").Collection | (import("../types/course-events").CourseEvent | import("../types/collections").Collection)[])[], teachersList: string[], groupsList: string[], settings: import("../types/settings").Settings, overlapGroup?: number) => (import("../../../core/types").Deserialized<Omit<import("../../../core/v2/types/courses").Course, "groups" | "
|
|
5
|
-
events?: (import("../../../core/types").Deserialized<Omit<import("../../../core/v2/types/events").Event, "groups" | "
|
|
3
|
+
static courseEvent: (courseEvents: (number | import("../types/course-events").CourseEvent)[], course: import("../types/collections").Collection, teachersList: string[], groupsList: string[], settings: import("../types/settings").Settings, overlapGroup?: number | null) => (import("../../../core/types").Deserialized<Omit<import("../../../core/v2/types/events").Event, "groups" | "teachers" | "period">> & import("../../../core/types").Serialized<Pick<import("../../../core/v2/types/events").Event, "groups" | "teachers" | "period">>)[];
|
|
4
|
+
static collection: (courses: (import("../types/course-events").CourseEvent | import("../types/collections").Collection | (import("../types/course-events").CourseEvent | import("../types/collections").Collection)[])[], teachersList: string[], groupsList: string[], settings: import("../types/settings").Settings, overlapGroup?: number) => (import("../../../core/types").Deserialized<Omit<import("../../../core/v2/types/courses").Course, "groups" | "teachers" | "events" | "period" | "overlapGroup">> & import("../../../core/types").Serialized<Pick<import("../../../core/v2/types/courses").Course, "groups" | "teachers" | "period" | "overlapGroup">> & {
|
|
5
|
+
events?: (import("../../../core/types").Deserialized<Omit<import("../../../core/v2/types/events").Event, "groups" | "teachers" | "period">> & import("../../../core/types").Serialized<Pick<import("../../../core/v2/types/events").Event, "groups" | "teachers" | "period">>)[] | undefined;
|
|
6
6
|
})[];
|
|
7
7
|
static day: (days: (number | import("../types/days").Day)[], settings: import("../types/settings").Settings) => import("../../../core/v2/types/days").Day[];
|
|
8
8
|
static dependency: (dependencies: (string | import("../types/dependencies").Dependency)[], settings: import("../types/settings").Settings) => import("../../../core/types").Deserialized<import("../../../core/v2/types/locations").Location>[];
|
|
@@ -16,8 +16,8 @@ export default class {
|
|
|
16
16
|
overlapGroups: any;
|
|
17
17
|
settings: any;
|
|
18
18
|
area?: import("../types/areas").Area | undefined;
|
|
19
|
-
courses?: (import("../../../core/types").Deserialized<Omit<import("../../../core/v2/types/courses").Course, "groups" | "
|
|
20
|
-
events?: (import("../../../core/types").Deserialized<Omit<import("../../../core/v2/types/events").Event, "groups" | "
|
|
19
|
+
courses?: (import("../../../core/types").Deserialized<Omit<import("../../../core/v2/types/courses").Course, "groups" | "teachers" | "events" | "period" | "overlapGroup">> & import("../../../core/types").Serialized<Pick<import("../../../core/v2/types/courses").Course, "groups" | "teachers" | "period" | "overlapGroup">> & {
|
|
20
|
+
events?: (import("../../../core/types").Deserialized<Omit<import("../../../core/v2/types/events").Event, "groups" | "teachers" | "period">> & import("../../../core/types").Serialized<Pick<import("../../../core/v2/types/events").Event, "groups" | "teachers" | "period">>)[] | undefined;
|
|
21
21
|
})[] | undefined;
|
|
22
22
|
groups?: import("../../../core/types").Deserialized<import("../../../core/v2/types/groups").Group>[] | undefined;
|
|
23
23
|
teachers?: import("../../../core/types").Deserialized<import("../../../core/v2/types/teachers").Teacher>[] | undefined;
|
|
@@ -4,8 +4,8 @@ declare const _default_1: (schedule: Schedule) => {
|
|
|
4
4
|
overlapGroups: any;
|
|
5
5
|
settings: any;
|
|
6
6
|
area?: import("../types/areas").Area | undefined;
|
|
7
|
-
courses?: (Deserialized<Omit<import("../../../core/v2/types/courses").Course, "groups" | "
|
|
8
|
-
events?: (Deserialized<Omit<import("../../../core/v2/types/events").Event, "groups" | "
|
|
7
|
+
courses?: (Deserialized<Omit<import("../../../core/v2/types/courses").Course, "groups" | "teachers" | "events" | "period" | "overlapGroup">> & import("../../../core/types").Serialized<Pick<import("../../../core/v2/types/courses").Course, "groups" | "teachers" | "period" | "overlapGroup">> & {
|
|
8
|
+
events?: (Deserialized<Omit<import("../../../core/v2/types/events").Event, "groups" | "teachers" | "period">> & import("../../../core/types").Serialized<Pick<import("../../../core/v2/types/events").Event, "groups" | "teachers" | "period">>)[] | undefined;
|
|
9
9
|
})[] | undefined;
|
|
10
10
|
groups?: Deserialized<import("../../../core/v2/types/groups").Group>[] | undefined;
|
|
11
11
|
teachers?: Deserialized<import("../../../core/v2/types/teachers").Teacher>[] | undefined;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export default class {
|
|
2
|
-
static activities: (activities: (import("../../core/types").Deserialized<import("../../core/v2/types/
|
|
2
|
+
static activities: (activities: (import("../../core/types").Deserialized<import("../../core/v2/types/events").Event> | import("../../core/types").Deserialized<import("../../core/v2/types/courses").Course>)[], belongsTo?: import("../../core/v2/types/divisions").Division | undefined, expand?: ("groups" | "teachers" | "referenceNames" | "syllabus")[] | undefined) => import("../types/activities").Activity[];
|
|
3
3
|
static calendarEvents: (events: import("../../core/types").Deserialized<import("../../core/v2/types/events").Event>[], belongsTo?: import("../../core/v2/types/divisions").Division | undefined, expand?: ("groups" | "teachers" | "referenceNames" | "activity")[] | undefined) => Partial<import("../types/calendar-events").CalendarEvent>[];
|
|
4
4
|
static duties: (teachers: import("../../core/types").Deserialized<import("../../core/v2/types/teachers").Teacher>[], belongsTo?: import("../../core/v2/types/divisions").Division | undefined, expand?: ("person" | "referenceNames")[] | undefined) => import("../types/duties").Duty[];
|
|
5
5
|
static groups: (groups: import("../../core/types").Deserialized<import("../../core/v2/types/groups").Group>[], belongsTo?: import("../../core/v2/types/divisions").Division | undefined, expand?: ("persons" | "referenceNames")[] | undefined) => import("../types/groups").Group[];
|
|
@@ -16,14 +16,14 @@ declare const _default: (courses: ReturnType<typeof transform>) => {
|
|
|
16
16
|
days?: import("../../types").Deserialized<import("../types/days").Day>[] | undefined;
|
|
17
17
|
updatedAt?: string | undefined;
|
|
18
18
|
displayName?: string | undefined;
|
|
19
|
-
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
20
|
-
ids?: string | undefined;
|
|
21
|
-
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
22
|
-
weight?: number | undefined;
|
|
23
19
|
density?: number | undefined;
|
|
20
|
+
weight?: number | undefined;
|
|
21
|
+
ids?: string | undefined;
|
|
24
22
|
subject?: string | undefined;
|
|
23
|
+
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
25
24
|
eventDurationVariance?: number | undefined;
|
|
26
25
|
totalTime?: string | undefined;
|
|
26
|
+
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
27
27
|
centerOfAttraction?: string | null | undefined;
|
|
28
28
|
minutesPerWeek?: number | undefined;
|
|
29
29
|
expectedTotalHours?: number | undefined;
|
|
@@ -21,16 +21,16 @@ declare const _default: (events: ReturnType<typeof transform>) => {
|
|
|
21
21
|
days?: import("../../types").Deserialized<import("../types/days").Day>[] | undefined;
|
|
22
22
|
updatedAt?: string | undefined;
|
|
23
23
|
displayName?: string | undefined;
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
durationVariance?: number | undefined;
|
|
27
|
-
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
24
|
+
density?: number | undefined;
|
|
25
|
+
weight?: number | undefined;
|
|
28
26
|
ids?: string | undefined;
|
|
29
27
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
30
|
-
|
|
31
|
-
density?: number | undefined;
|
|
28
|
+
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
32
29
|
centerOfAttraction?: string | null | undefined;
|
|
30
|
+
parked?: boolean | undefined;
|
|
33
31
|
fixedStart?: boolean | undefined;
|
|
32
|
+
duration?: number | undefined;
|
|
34
33
|
preferredDuration?: number | undefined;
|
|
34
|
+
durationVariance?: number | undefined;
|
|
35
35
|
}[];
|
|
36
36
|
export default _default;
|
|
@@ -4,14 +4,14 @@ declare const _default: (groups: ReturnType<typeof transform>) => {
|
|
|
4
4
|
days?: import("../types/days").Day[] | undefined;
|
|
5
5
|
updatedAt?: string | undefined;
|
|
6
6
|
displayName?: string | undefined;
|
|
7
|
-
|
|
7
|
+
weight?: number | undefined;
|
|
8
8
|
ids?: string | undefined;
|
|
9
9
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
10
|
+
intervals?: import("../types/intervals").Interval[] | undefined;
|
|
10
11
|
maxNumWorkingHours?: number | boolean | undefined;
|
|
11
12
|
maxNumDailyWorkingHours?: number | boolean | number[] | undefined;
|
|
12
13
|
forbidOverlappingEvents?: boolean | undefined;
|
|
13
14
|
disableDayLengthPunishment?: boolean | undefined;
|
|
14
|
-
weight?: number | undefined;
|
|
15
15
|
rank?: number | undefined;
|
|
16
16
|
}[];
|
|
17
17
|
export default _default;
|
|
@@ -29,8 +29,8 @@ declare const _default: (overlapGroups: ReturnType<typeof transform>) => {
|
|
|
29
29
|
_id?: import("mongoose").Types.ObjectId | undefined;
|
|
30
30
|
createdAt?: string | undefined;
|
|
31
31
|
updatedAt?: string | undefined;
|
|
32
|
-
coalesced?: import("../types/common/coalesced").Coalesced<import("../types/courses").Course>[] | undefined;
|
|
33
32
|
ids?: string | undefined;
|
|
33
|
+
coalesced?: import("../types/common/coalesced").Coalesced<import("../types/courses").Course>[] | undefined;
|
|
34
34
|
species?: (import("../types/common/coalesced").Coalesced<import("../types/events").Event> & {
|
|
35
35
|
id?: string | undefined;
|
|
36
36
|
})[] | undefined;
|
|
@@ -47,20 +47,20 @@ export default function (schedule: ReturnType<typeof transform>): {
|
|
|
47
47
|
days?: import("../../types").Deserialized<import("../types/days").Day>[] | undefined;
|
|
48
48
|
updatedAt?: string | undefined;
|
|
49
49
|
displayName?: string | undefined;
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
durationVariance?: number | undefined;
|
|
53
|
-
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
50
|
+
density?: number | undefined;
|
|
51
|
+
weight?: number | undefined;
|
|
54
52
|
ids?: string | undefined;
|
|
55
53
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
56
|
-
|
|
57
|
-
density?: number | undefined;
|
|
54
|
+
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
58
55
|
centerOfAttraction?: string | null | undefined;
|
|
56
|
+
parked?: boolean | undefined;
|
|
59
57
|
fixedStart?: boolean | undefined;
|
|
58
|
+
duration?: number | undefined;
|
|
60
59
|
preferredDuration?: number | undefined;
|
|
60
|
+
durationVariance?: number | undefined;
|
|
61
61
|
}[] | undefined;
|
|
62
62
|
lockedTimes?: import("../types/locked-times").LockedTime[] | undefined;
|
|
63
|
-
overlapGroups?: import("../../types").Serialized<Omit<import("../types/overlap-groups").OverlapGroup, "
|
|
63
|
+
overlapGroups?: import("../../types").Serialized<Omit<import("../types/overlap-groups").OverlapGroup, "lastModifiedBy" | "belongsTo">>[] | undefined;
|
|
64
64
|
courses?: {
|
|
65
65
|
period?: string | undefined;
|
|
66
66
|
locations?: {
|
|
@@ -78,14 +78,14 @@ export default function (schedule: ReturnType<typeof transform>): {
|
|
|
78
78
|
days?: import("../../types").Deserialized<import("../types/days").Day>[] | undefined;
|
|
79
79
|
updatedAt?: string | undefined;
|
|
80
80
|
displayName?: string | undefined;
|
|
81
|
-
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
82
|
-
ids?: string | undefined;
|
|
83
|
-
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
84
|
-
weight?: number | undefined;
|
|
85
81
|
density?: number | undefined;
|
|
82
|
+
weight?: number | undefined;
|
|
83
|
+
ids?: string | undefined;
|
|
86
84
|
subject?: string | undefined;
|
|
85
|
+
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
87
86
|
eventDurationVariance?: number | undefined;
|
|
88
87
|
totalTime?: string | undefined;
|
|
88
|
+
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
89
89
|
centerOfAttraction?: string | null | undefined;
|
|
90
90
|
minutesPerWeek?: number | undefined;
|
|
91
91
|
expectedTotalHours?: number | undefined;
|
|
@@ -95,14 +95,14 @@ export default function (schedule: ReturnType<typeof transform>): {
|
|
|
95
95
|
days?: import("../types/days").Day[] | undefined;
|
|
96
96
|
updatedAt?: string | undefined;
|
|
97
97
|
displayName?: string | undefined;
|
|
98
|
-
|
|
98
|
+
weight?: number | undefined;
|
|
99
99
|
ids?: string | undefined;
|
|
100
100
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
101
|
+
intervals?: import("../types/intervals").Interval[] | undefined;
|
|
101
102
|
maxNumWorkingHours?: number | boolean | undefined;
|
|
102
103
|
maxNumDailyWorkingHours?: number | boolean | number[] | undefined;
|
|
103
104
|
forbidOverlappingEvents?: boolean | undefined;
|
|
104
105
|
disableDayLengthPunishment?: boolean | undefined;
|
|
105
|
-
weight?: number | undefined;
|
|
106
106
|
rank?: number | undefined;
|
|
107
107
|
}[] | undefined;
|
|
108
108
|
teachers?: {
|
|
@@ -17,14 +17,14 @@ declare const _default: (courses: Deserialized<Course>[]) => {
|
|
|
17
17
|
days?: Deserialized<import("../types/days").Day>[] | undefined;
|
|
18
18
|
updatedAt?: string | undefined;
|
|
19
19
|
displayName?: string | undefined;
|
|
20
|
-
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
21
|
-
ids?: string | undefined;
|
|
22
|
-
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
23
|
-
weight?: number | undefined;
|
|
24
20
|
density?: number | undefined;
|
|
21
|
+
weight?: number | undefined;
|
|
22
|
+
ids?: string | undefined;
|
|
25
23
|
subject?: string | undefined;
|
|
24
|
+
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
26
25
|
eventDurationVariance?: number | undefined;
|
|
27
26
|
totalTime?: string | undefined;
|
|
27
|
+
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
28
28
|
centerOfAttraction?: string | null | undefined;
|
|
29
29
|
minutesPerWeek?: number | undefined;
|
|
30
30
|
expectedTotalHours?: number | undefined;
|
|
@@ -22,16 +22,16 @@ declare const _default: (events: Deserialized<Event>[]) => {
|
|
|
22
22
|
days?: Deserialized<import("../types/days").Day>[] | undefined;
|
|
23
23
|
updatedAt?: string | undefined;
|
|
24
24
|
displayName?: string | undefined;
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
durationVariance?: number | undefined;
|
|
28
|
-
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
25
|
+
density?: number | undefined;
|
|
26
|
+
weight?: number | undefined;
|
|
29
27
|
ids?: string | undefined;
|
|
30
28
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
31
|
-
|
|
32
|
-
density?: number | undefined;
|
|
29
|
+
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
33
30
|
centerOfAttraction?: string | null | undefined;
|
|
31
|
+
parked?: boolean | undefined;
|
|
34
32
|
fixedStart?: boolean | undefined;
|
|
33
|
+
duration?: number | undefined;
|
|
35
34
|
preferredDuration?: number | undefined;
|
|
35
|
+
durationVariance?: number | undefined;
|
|
36
36
|
}[];
|
|
37
37
|
export default _default;
|
|
@@ -4,14 +4,14 @@ declare const _default: (groups: Group[]) => {
|
|
|
4
4
|
days?: import("../types/days").Day[] | undefined;
|
|
5
5
|
updatedAt?: string | undefined;
|
|
6
6
|
displayName?: string | undefined;
|
|
7
|
-
|
|
7
|
+
weight?: number | undefined;
|
|
8
8
|
ids?: string | undefined;
|
|
9
9
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
10
|
+
intervals?: import("../types/intervals").Interval[] | undefined;
|
|
10
11
|
maxNumWorkingHours?: number | boolean | undefined;
|
|
11
12
|
maxNumDailyWorkingHours?: number | boolean | number[] | undefined;
|
|
12
13
|
forbidOverlappingEvents?: boolean | undefined;
|
|
13
14
|
disableDayLengthPunishment?: boolean | undefined;
|
|
14
|
-
weight?: number | undefined;
|
|
15
15
|
rank?: number | undefined;
|
|
16
16
|
}[];
|
|
17
17
|
export default _default;
|
|
@@ -27,7 +27,7 @@ import { Types as CoreTypes } from '../types';
|
|
|
27
27
|
import { Serialized, Deserialized } from '../../types';
|
|
28
28
|
export default function (schedule: Deserialized<CoreTypes.division>): {
|
|
29
29
|
settings?: import("../types/division-settings").DivisionSettings | undefined;
|
|
30
|
-
overlapGroups?: Serialized<Omit<import("../types/overlap-groups").OverlapGroup, "
|
|
30
|
+
overlapGroups?: Serialized<Omit<import("../types/overlap-groups").OverlapGroup, "lastModifiedBy" | "belongsTo">>[] | undefined;
|
|
31
31
|
lockedTimes?: import("../types/locked-times").LockedTime[] | undefined;
|
|
32
32
|
events?: {
|
|
33
33
|
period?: string | undefined;
|
|
@@ -51,17 +51,17 @@ export default function (schedule: Deserialized<CoreTypes.division>): {
|
|
|
51
51
|
days?: Deserialized<import("../types/days").Day>[] | undefined;
|
|
52
52
|
updatedAt?: string | undefined;
|
|
53
53
|
displayName?: string | undefined;
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
durationVariance?: number | undefined;
|
|
57
|
-
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
54
|
+
density?: number | undefined;
|
|
55
|
+
weight?: number | undefined;
|
|
58
56
|
ids?: string | undefined;
|
|
59
57
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
60
|
-
|
|
61
|
-
density?: number | undefined;
|
|
58
|
+
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
62
59
|
centerOfAttraction?: string | null | undefined;
|
|
60
|
+
parked?: boolean | undefined;
|
|
63
61
|
fixedStart?: boolean | undefined;
|
|
62
|
+
duration?: number | undefined;
|
|
64
63
|
preferredDuration?: number | undefined;
|
|
64
|
+
durationVariance?: number | undefined;
|
|
65
65
|
}[] | undefined;
|
|
66
66
|
courses?: {
|
|
67
67
|
period?: string | undefined;
|
|
@@ -80,14 +80,14 @@ export default function (schedule: Deserialized<CoreTypes.division>): {
|
|
|
80
80
|
days?: Deserialized<import("../types/days").Day>[] | undefined;
|
|
81
81
|
updatedAt?: string | undefined;
|
|
82
82
|
displayName?: string | undefined;
|
|
83
|
-
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
84
|
-
ids?: string | undefined;
|
|
85
|
-
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
86
|
-
weight?: number | undefined;
|
|
87
83
|
density?: number | undefined;
|
|
84
|
+
weight?: number | undefined;
|
|
85
|
+
ids?: string | undefined;
|
|
88
86
|
subject?: string | undefined;
|
|
87
|
+
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
89
88
|
eventDurationVariance?: number | undefined;
|
|
90
89
|
totalTime?: string | undefined;
|
|
90
|
+
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
91
91
|
centerOfAttraction?: string | null | undefined;
|
|
92
92
|
minutesPerWeek?: number | undefined;
|
|
93
93
|
expectedTotalHours?: number | undefined;
|
|
@@ -125,14 +125,14 @@ export default function (schedule: Deserialized<CoreTypes.division>): {
|
|
|
125
125
|
days?: import("../types/days").Day[] | undefined;
|
|
126
126
|
updatedAt?: string | undefined;
|
|
127
127
|
displayName?: string | undefined;
|
|
128
|
-
|
|
128
|
+
weight?: number | undefined;
|
|
129
129
|
ids?: string | undefined;
|
|
130
130
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
131
|
+
intervals?: import("../types/intervals").Interval[] | undefined;
|
|
131
132
|
maxNumWorkingHours?: number | boolean | undefined;
|
|
132
133
|
maxNumDailyWorkingHours?: number | boolean | number[] | undefined;
|
|
133
134
|
forbidOverlappingEvents?: boolean | undefined;
|
|
134
135
|
disableDayLengthPunishment?: boolean | undefined;
|
|
135
|
-
weight?: number | undefined;
|
|
136
136
|
rank?: number | undefined;
|
|
137
137
|
}[] | undefined;
|
|
138
138
|
teachers?: {
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/// <reference types="mongoose/types/aggregate" />
|
|
2
|
+
/// <reference types="mongoose/types/callback" />
|
|
3
|
+
/// <reference types="mongoose/types/collection" />
|
|
4
|
+
/// <reference types="mongoose/types/connection" />
|
|
5
|
+
/// <reference types="mongoose/types/cursor" />
|
|
6
|
+
/// <reference types="mongoose/types/document" />
|
|
7
|
+
/// <reference types="mongoose/types/error" />
|
|
8
|
+
/// <reference types="mongoose/types/expressions" />
|
|
9
|
+
/// <reference types="mongoose/types/helpers" />
|
|
10
|
+
/// <reference types="mongoose/types/middlewares" />
|
|
11
|
+
/// <reference types="mongoose/types/indexes" />
|
|
12
|
+
/// <reference types="mongoose/types/models" />
|
|
13
|
+
/// <reference types="mongoose/types/mongooseoptions" />
|
|
14
|
+
/// <reference types="mongoose/types/pipelinestage" />
|
|
15
|
+
/// <reference types="mongoose/types/populate" />
|
|
16
|
+
/// <reference types="mongoose/types/query" />
|
|
17
|
+
/// <reference types="mongoose/types/schemaoptions" />
|
|
18
|
+
/// <reference types="mongoose/types/schematypes" />
|
|
19
|
+
/// <reference types="mongoose/types/session" />
|
|
20
|
+
/// <reference types="mongoose/types/types" />
|
|
21
|
+
/// <reference types="mongoose/types/utility" />
|
|
22
|
+
/// <reference types="mongoose/types/validation" />
|
|
23
|
+
/// <reference types="mongoose/types/virtuals" />
|
|
24
|
+
/// <reference types="mongoose" />
|
|
25
|
+
/// <reference types="mongoose/types/inferschematype" />
|
|
26
|
+
import transform from '../to/calendar-exceptions';
|
|
27
|
+
declare const _default: (calendarExceptions: ReturnType<typeof transform>) => {
|
|
28
|
+
_id?: import("mongoose").Types.ObjectId | undefined;
|
|
29
|
+
id?: string | undefined;
|
|
30
|
+
belongsTo?: string | import("mongoose").Types.ObjectId | import("../types/divisions").Division | undefined;
|
|
31
|
+
reason?: string | undefined;
|
|
32
|
+
description?: string | undefined;
|
|
33
|
+
sources?: import("../types/common/coalesced").Coalesced<import("../types/courses").Course | import("../types/events").Event>[] | undefined;
|
|
34
|
+
start?: Date | undefined;
|
|
35
|
+
end?: Date | undefined;
|
|
36
|
+
action?: "add" | "cancel" | "remove" | "reschedule" | "substitute" | undefined;
|
|
37
|
+
exception?: {
|
|
38
|
+
to?: import("../../types").Edge<import("../types/groups").Group | import("../types/persons").Person | import("../types/teachers").Teacher | import("../types/locations").Location | import("../types/courses").Course> | undefined;
|
|
39
|
+
toModel?: "groups" | "courses" | "teachers" | "locations" | "persons" | undefined;
|
|
40
|
+
include?: boolean | undefined;
|
|
41
|
+
start?: Date | undefined;
|
|
42
|
+
end?: Date | undefined;
|
|
43
|
+
} | undefined;
|
|
44
|
+
lastModifiedBy?: unknown;
|
|
45
|
+
}[];
|
|
46
|
+
export default _default;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
8
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
9
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
10
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
11
|
+
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
12
|
+
var _default = calendarExceptions => {
|
|
13
|
+
calendarExceptions = calendarExceptions.filter(_ref => {
|
|
14
|
+
var {
|
|
15
|
+
id
|
|
16
|
+
} = _ref;
|
|
17
|
+
return id != undefined;
|
|
18
|
+
});
|
|
19
|
+
if (calendarExceptions.length != Array.from(new Set(calendarExceptions.map(_ref2 => {
|
|
20
|
+
var {
|
|
21
|
+
id
|
|
22
|
+
} = _ref2;
|
|
23
|
+
return id;
|
|
24
|
+
}))).length) throw new Error('(Core::From::V2::calendarExceptions) calendarExceptions array have two or more calendarExceptions with the same ID');
|
|
25
|
+
return calendarExceptions.map(calendarException => {
|
|
26
|
+
if (!calendarException.id) throw new Error('(Core::From::V2::calendarExceptions) Calendar exceptions id is undefined');
|
|
27
|
+
return _objectSpread({}, calendarException);
|
|
28
|
+
}, []);
|
|
29
|
+
};
|
|
30
|
+
exports.default = _default;
|
|
31
|
+
//# sourceMappingURL=calendar-exceptions.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"calendar-exceptions.js","names":["calendarExceptions","filter","_ref","id","undefined","length","Array","from","Set","map","_ref2","Error","calendarException","_objectSpread","exports","default","_default"],"sources":["../../../../src/core/v2/from/calendar-exceptions.ts"],"sourcesContent":[null],"mappings":";;;;;;;;;;;eAGgBA,kBAAgD,IAAI;EAClEA,kBAAkB,GAAGA,kBAAkB,CAACC,MAAM,CAACC,IAAA;IAAA,IAAC;MAAEC;IAAE,CAAE,GAAAD,IAAA;IAAA,OAAKC,EAAE,IAAIC,SAAS;EAAA,EAAC;EAE3E,IAAIJ,kBAAkB,CAACK,MAAM,IAAIC,KAAK,CAACC,IAAI,CAAC,IAAIC,GAAG,CAA0BR,kBAAkB,CAACS,GAAG,CAACC,KAAA;IAAA,IAAC;MAAEP;IAAE,CAAE,GAAAO,KAAA;IAAA,OAAKP,EAAE;EAAA,EAAC,CAAC,CAAC,CAACE,MAAM,EAC1H,MAAM,IAAIM,KAAK,CAAC,oHAAoH,CAAC;EAEvI,OAAOX,kBAAkB,CAACS,GAAG,CAACG,iBAAiB,IAAG;IAChD,IAAI,CAAEA,iBAAiB,CAACT,EAAE,EACxB,MAAM,IAAIQ,KAAK,CAAC,0EAA0E,CAAC;IAE7F,OAAAE,aAAA,KAAYD,iBAAiB;EAC/B,CAAC,EAAE,EAAE,CAA+B;AACtC,CAAC;AAAAE,OAAA,CAAAC,OAAA,GAAAC,QAAA"}
|
|
@@ -27,14 +27,14 @@ declare const _default: (courses: ReturnType<typeof transform>) => {
|
|
|
27
27
|
comment?: string | undefined;
|
|
28
28
|
updatedAt?: string | undefined;
|
|
29
29
|
displayName?: string | undefined;
|
|
30
|
-
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
31
|
-
ids?: string | undefined;
|
|
32
|
-
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
33
|
-
weight?: number | undefined;
|
|
34
30
|
density?: number | undefined;
|
|
31
|
+
weight?: number | undefined;
|
|
32
|
+
ids?: string | undefined;
|
|
35
33
|
subject?: string | undefined;
|
|
34
|
+
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
36
35
|
eventDurationVariance?: number | undefined;
|
|
37
36
|
totalTime?: string | undefined;
|
|
37
|
+
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
38
38
|
centerOfAttraction?: string | null | undefined;
|
|
39
39
|
minutesPerWeek?: number | undefined;
|
|
40
40
|
expectedTotalHours?: number | undefined;
|
|
@@ -31,16 +31,16 @@ declare const _default: (events: ReturnType<typeof transform>) => {
|
|
|
31
31
|
days?: import("../../types").Deserialized<import("../types/days").Day>[] | undefined;
|
|
32
32
|
updatedAt?: string | undefined;
|
|
33
33
|
displayName?: string | undefined;
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
durationVariance?: number | undefined;
|
|
37
|
-
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
34
|
+
density?: number | undefined;
|
|
35
|
+
weight?: number | undefined;
|
|
38
36
|
ids?: string | undefined;
|
|
39
37
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
40
|
-
|
|
41
|
-
density?: number | undefined;
|
|
38
|
+
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
42
39
|
centerOfAttraction?: string | null | undefined;
|
|
40
|
+
parked?: boolean | undefined;
|
|
43
41
|
fixedStart?: boolean | undefined;
|
|
42
|
+
duration?: number | undefined;
|
|
44
43
|
preferredDuration?: number | undefined;
|
|
44
|
+
durationVariance?: number | undefined;
|
|
45
45
|
}[];
|
|
46
46
|
export default _default;
|
|
@@ -6,14 +6,14 @@ declare const _default: (groups: ReturnType<typeof transform>) => {
|
|
|
6
6
|
days?: import("../../types").Deserialized<import("../types/days").Day>[] | undefined;
|
|
7
7
|
updatedAt?: string | undefined;
|
|
8
8
|
displayName?: string | undefined;
|
|
9
|
-
|
|
9
|
+
weight?: number | undefined;
|
|
10
10
|
ids?: string | undefined;
|
|
11
11
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
12
|
+
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
12
13
|
maxNumWorkingHours?: number | boolean | undefined;
|
|
13
14
|
maxNumDailyWorkingHours?: number | boolean | number[] | undefined;
|
|
14
15
|
forbidOverlappingEvents?: boolean | undefined;
|
|
15
16
|
disableDayLengthPunishment?: boolean | undefined;
|
|
16
|
-
weight?: number | undefined;
|
|
17
17
|
rank?: number | undefined;
|
|
18
18
|
species?: string | undefined;
|
|
19
19
|
}[];
|
|
@@ -29,8 +29,8 @@ declare const _default: (overlapGroups: ReturnType<typeof transform>) => {
|
|
|
29
29
|
_id?: import("mongoose").Types.ObjectId | undefined;
|
|
30
30
|
createdAt?: string | undefined;
|
|
31
31
|
updatedAt?: string | undefined;
|
|
32
|
-
coalesced?: import("../types/common/coalesced").Coalesced<import("../types/courses").Course>[] | undefined;
|
|
33
32
|
ids?: string | undefined;
|
|
33
|
+
coalesced?: import("../types/common/coalesced").Coalesced<import("../types/courses").Course>[] | undefined;
|
|
34
34
|
species?: (import("../types/common/coalesced").Coalesced<import("../types/events").Event> & {
|
|
35
35
|
id?: string | undefined;
|
|
36
36
|
})[] | undefined;
|
|
@@ -57,21 +57,21 @@ export default function (schedule: ReturnType<typeof transform>): {
|
|
|
57
57
|
days?: import("../../types").Deserialized<import("../types/days").Day>[] | undefined;
|
|
58
58
|
updatedAt?: string | undefined;
|
|
59
59
|
displayName?: string | undefined;
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
durationVariance?: number | undefined;
|
|
63
|
-
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
60
|
+
density?: number | undefined;
|
|
61
|
+
weight?: number | undefined;
|
|
64
62
|
ids?: string | undefined;
|
|
65
63
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
66
|
-
|
|
67
|
-
density?: number | undefined;
|
|
64
|
+
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
68
65
|
centerOfAttraction?: string | null | undefined;
|
|
66
|
+
parked?: boolean | undefined;
|
|
69
67
|
fixedStart?: boolean | undefined;
|
|
68
|
+
duration?: number | undefined;
|
|
70
69
|
preferredDuration?: number | undefined;
|
|
70
|
+
durationVariance?: number | undefined;
|
|
71
71
|
}[];
|
|
72
72
|
lockedTimes: import("../types/locked-times").LockedTime[];
|
|
73
73
|
rootIntervals: import("../types/root-intervals").RootInterval[];
|
|
74
|
-
overlapGroups: import("../../types").Serialized<Omit<import("../types/overlap-groups").OverlapGroup, "
|
|
74
|
+
overlapGroups: import("../../types").Serialized<Omit<import("../types/overlap-groups").OverlapGroup, "lastModifiedBy" | "belongsTo">>[];
|
|
75
75
|
courses: {
|
|
76
76
|
period?: string | undefined;
|
|
77
77
|
locations?: {
|
|
@@ -100,14 +100,14 @@ export default function (schedule: ReturnType<typeof transform>): {
|
|
|
100
100
|
comment?: string | undefined;
|
|
101
101
|
updatedAt?: string | undefined;
|
|
102
102
|
displayName?: string | undefined;
|
|
103
|
-
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
104
|
-
ids?: string | undefined;
|
|
105
|
-
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
106
|
-
weight?: number | undefined;
|
|
107
103
|
density?: number | undefined;
|
|
104
|
+
weight?: number | undefined;
|
|
105
|
+
ids?: string | undefined;
|
|
108
106
|
subject?: string | undefined;
|
|
107
|
+
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
109
108
|
eventDurationVariance?: number | undefined;
|
|
110
109
|
totalTime?: string | undefined;
|
|
110
|
+
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
111
111
|
centerOfAttraction?: string | null | undefined;
|
|
112
112
|
minutesPerWeek?: number | undefined;
|
|
113
113
|
expectedTotalHours?: number | undefined;
|
|
@@ -148,14 +148,14 @@ export default function (schedule: ReturnType<typeof transform>): {
|
|
|
148
148
|
days?: import("../../types").Deserialized<import("../types/days").Day>[] | undefined;
|
|
149
149
|
updatedAt?: string | undefined;
|
|
150
150
|
displayName?: string | undefined;
|
|
151
|
-
|
|
151
|
+
weight?: number | undefined;
|
|
152
152
|
ids?: string | undefined;
|
|
153
153
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
154
|
+
intervals?: import("../../types").Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
154
155
|
maxNumWorkingHours?: number | boolean | undefined;
|
|
155
156
|
maxNumDailyWorkingHours?: number | boolean | number[] | undefined;
|
|
156
157
|
forbidOverlappingEvents?: boolean | undefined;
|
|
157
158
|
disableDayLengthPunishment?: boolean | undefined;
|
|
158
|
-
weight?: number | undefined;
|
|
159
159
|
rank?: number | undefined;
|
|
160
160
|
species?: string | undefined;
|
|
161
161
|
}[];
|
|
@@ -205,4 +205,5 @@ export default function (schedule: ReturnType<typeof transform>): {
|
|
|
205
205
|
}[];
|
|
206
206
|
periods: import("../types/periods").Period[];
|
|
207
207
|
settings: import("../types/division-settings").DivisionSettings;
|
|
208
|
+
calendarExceptions: import("../types/calendar-exceptions").CalendarException[];
|
|
208
209
|
};
|
|
@@ -4,6 +4,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = _default;
|
|
7
|
+
var _calendarExceptions2 = _interopRequireDefault(require("./calendar-exceptions"));
|
|
7
8
|
var _periods2 = _interopRequireDefault(require("./periods"));
|
|
8
9
|
var _locations2 = _interopRequireDefault(require("./locations"));
|
|
9
10
|
var _teachers2 = _interopRequireDefault(require("./teachers"));
|
|
@@ -32,7 +33,8 @@ function _default(schedule) {
|
|
|
32
33
|
events,
|
|
33
34
|
overlapGroups,
|
|
34
35
|
rootIntervals,
|
|
35
|
-
lockedTimes
|
|
36
|
+
lockedTimes,
|
|
37
|
+
calendarExceptions
|
|
36
38
|
} = schedule;
|
|
37
39
|
if (periods) {
|
|
38
40
|
periods = (0, _periods2.default)(periods);
|
|
@@ -64,7 +66,12 @@ function _default(schedule) {
|
|
|
64
66
|
if (rootIntervals) {
|
|
65
67
|
rootIntervals = (0, _rootIntervals2.default)(rootIntervals);
|
|
66
68
|
}
|
|
67
|
-
|
|
69
|
+
if (calendarExceptions) {
|
|
70
|
+
calendarExceptions = (0, _calendarExceptions2.default)(calendarExceptions);
|
|
71
|
+
}
|
|
72
|
+
return _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({}, calendarExceptions && {
|
|
73
|
+
calendarExceptions
|
|
74
|
+
}), settings && {
|
|
68
75
|
settings
|
|
69
76
|
}), periods && {
|
|
70
77
|
periods
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schedules.js","names":["
|
|
1
|
+
{"version":3,"file":"schedules.js","names":["_calendarExceptions2","_interopRequireDefault","require","_periods2","_locations2","_teachers2","_groups2","_persons2","_courses2","_overlapGroups2","_lockedTimes2","_rootIntervals2","_events2","obj","__esModule","default","ownKeys","e","r","t","Object","keys","getOwnPropertySymbols","o","filter","getOwnPropertyDescriptor","enumerable","push","apply","_objectSpread","arguments","length","forEach","_defineProperty","getOwnPropertyDescriptors","defineProperties","defineProperty","key","value","_toPropertyKey","configurable","writable","arg","_toPrimitive","String","input","hint","prim","Symbol","toPrimitive","undefined","res","call","TypeError","Number","_default","schedule","periods","groups","courses","teachers","persons","locations","settings","events","overlapGroups","rootIntervals","lockedTimes","calendarExceptions","_periods","_groups","_teachers","_persons","_locations","_courses","_events","_overlapGroups","_lockedTimes","_rootIntervals","_calendarExceptions"],"sources":["../../../../src/core/v2/from/schedules.ts"],"sourcesContent":[null],"mappings":";;;;;;AAAA,IAAAA,oBAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,SAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAAAE,WAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,UAAA,GAAAJ,sBAAA,CAAAC,OAAA;AACA,IAAAI,QAAA,GAAAL,sBAAA,CAAAC,OAAA;AACA,IAAAK,SAAA,GAAAN,sBAAA,CAAAC,OAAA;AACA,IAAAM,SAAA,GAAAP,sBAAA,CAAAC,OA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A;EAAa,CAAE,GACvCC,WAAW,IAAW;IAAEA;EAAW,CAAE,GACrCH,MAAM,IAAgB;IAAEA;EAAM,CAAE;AAEvC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var _lodash = _interopRequireDefault(require("lodash"));
|
|
8
|
+
var _excluded = ["sources"];
|
|
9
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
10
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
11
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
12
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
13
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
14
|
+
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
15
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
16
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
17
|
+
var _default = calendarExceptions => {
|
|
18
|
+
return calendarExceptions.reduce((acc, _ref) => {
|
|
19
|
+
var {
|
|
20
|
+
sources
|
|
21
|
+
} = _ref,
|
|
22
|
+
lockedTime = _objectWithoutProperties(_ref, _excluded);
|
|
23
|
+
if (!(sources !== null && sources !== void 0 && sources.length)) return acc;
|
|
24
|
+
return acc.concat(_objectSpread(_objectSpread({}, _lodash.default.omit(lockedTime, ['_id', 'belongsTo', 'lastModifiedBy', 'createdAt', 'updatedAt'])), sources && {
|
|
25
|
+
sources: sources === null || sources === void 0 ? void 0 : sources.filter(x => _lodash.default.isObject(x === null || x === void 0 ? void 0 : x.to)).map(_ref2 => {
|
|
26
|
+
var {
|
|
27
|
+
to: {
|
|
28
|
+
id
|
|
29
|
+
},
|
|
30
|
+
toModel
|
|
31
|
+
} = _ref2;
|
|
32
|
+
return {
|
|
33
|
+
to: id.toString(),
|
|
34
|
+
toModel
|
|
35
|
+
};
|
|
36
|
+
})
|
|
37
|
+
}));
|
|
38
|
+
}, []).filter(x => {
|
|
39
|
+
var _x$sources;
|
|
40
|
+
return (_x$sources = x.sources) === null || _x$sources === void 0 ? void 0 : _x$sources.length;
|
|
41
|
+
});
|
|
42
|
+
};
|
|
43
|
+
exports.default = _default;
|
|
44
|
+
//# sourceMappingURL=calendar-exceptions.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"calendar-exceptions.js","names":["_lodash","_interopRequireDefault","require","_excluded","obj","__esModule","default","ownKeys","e","r","t","Object","keys","getOwnPropertySymbols","o","filter","getOwnPropertyDescriptor","enumerable","push","apply","_objectSpread","arguments","length","forEach","_defineProperty","getOwnPropertyDescriptors","defineProperties","defineProperty","key","value","_toPropertyKey","configurable","writable","arg","_toPrimitive","String","input","hint","prim","Symbol","toPrimitive","undefined","res","call","TypeError","Number","_objectWithoutProperties","source","excluded","target","_objectWithoutPropertiesLoose","i","sourceSymbolKeys","indexOf","prototype","propertyIsEnumerable","sourceKeys","_default","calendarExceptions","reduce","acc","_ref","sources","lockedTime","concat","_","omit","x","isObject","to","map","_ref2","id","toModel","toString","_x$sources","exports"],"sources":["../../../../src/core/v2/to/calendar-exceptions.ts"],"sourcesContent":[null],"mappings":";;;;;;AAAA,IAAAA,OAAA,GAAAC,sBAAA,CAAAC,OAAA;AAAyD,IAAAC,SAAA;AAAA,SAAAF,uBAAAG,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,KAAAE,OAAA,EAAAF,GAAA;AAAA,SAAAG,QAAAC,CAAA,EAAAC,CAAA,QAAAC,CAAA,GAAAC,MAAA,CAAAC,IAAA,CAAAJ,CAAA,OAAAG,MAAA,CAAAE,qBAAA,QAAAC,CAAA,GAAAH,MAAA,CAAAE,qBAAA,CAAAL,CAAA,GAAAC,CAAA,KAAAK,CAAA,GAAAA,CAAA,CAAAC,MAAA,WAAAN,CAAA,WAAAE,MAAA,CAAAK,wBAAA,CAAAR,CAAA,EAAAC,CAAA,EAAAQ,UAAA,OAAAP,CAAA,CAAAQ,IAAA,CAAAC,KAAA,CAAAT,CAAA,EAAAI,CAAA,YAAAJ,CAAA;AAAA,SAAAU,cAAAZ,CAAA,aAAAC,CAAA,MAAAA,CAAA,GAAAY,SAAA,CAAAC,MAAA,EAAAb,CAAA,UAAAC,CA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B,OAAOsC,GAAG;IAEZ,OAAOA,GAAG,CAACI,MAAM,CAAA5C,aAAA,CAAAA,aAAA,KACZ6C,eAAC,CAACC,IAAI,CAACH,UAAU,EAAE,CAAC,KAAK,EAAE,WAAW,EAAE,gBAAgB,EAAE,WAAW,EAAE,WAAW,CAAC,CAAC,GACpFD,OAAO,IAAI;MAAEA,OAAO,EAAEA,OAAO,aAAPA,OAAO,uBAAPA,OAAO,CAAE/C,MAAM,CAACoD,CAAC,IAAIF,eAAC,CAACG,QAAQ,CAACD,CAAC,aAADA,CAAC,uBAADA,CAAC,CAAEE,EAAE,CAAC,CAAC,CAACC,GAAG,CAACC,KAAA;QAAA,IAAC;UAAEF,EAAE,EAAE;YAAEG;UAAE,CAAE;UAAEC;QAAO,CAAE,GAAAF,KAAA;QAAA,OAAM;UAAEF,EAAE,EAAEG,EAAG,CAACE,QAAQ,EAAE;UAAED;QAAO,CAAE;MAAA,CAAC;IAAC,CAAE,CACvI,CAAC;EACJ,CAAC,EAAE,EAAE,CAAC,CAAC1D,MAAM,CAACoD,CAAC;IAAA,IAAAQ,UAAA;IAAA,QAAAA,UAAA,GAAIR,CAAC,CAACL,OAAO,cAAAa,UAAA,uBAATA,UAAA,CAAWrD,MAAM;EAAA,EAAiF;AACvH,CAAC;AAAAsD,OAAA,CAAAtE,OAAA,GAAAmD,QAAA"}
|
|
@@ -28,14 +28,14 @@ declare const _default: (courses: Deserialized<Course>[]) => {
|
|
|
28
28
|
comment?: string | undefined;
|
|
29
29
|
updatedAt?: string | undefined;
|
|
30
30
|
displayName?: string | undefined;
|
|
31
|
-
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
32
|
-
ids?: string | undefined;
|
|
33
|
-
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
34
|
-
weight?: number | undefined;
|
|
35
31
|
density?: number | undefined;
|
|
32
|
+
weight?: number | undefined;
|
|
33
|
+
ids?: string | undefined;
|
|
36
34
|
subject?: string | undefined;
|
|
35
|
+
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
37
36
|
eventDurationVariance?: number | undefined;
|
|
38
37
|
totalTime?: string | undefined;
|
|
38
|
+
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
39
39
|
centerOfAttraction?: string | null | undefined;
|
|
40
40
|
minutesPerWeek?: number | undefined;
|
|
41
41
|
expectedTotalHours?: number | undefined;
|
|
@@ -32,16 +32,16 @@ declare const _default: (events: Deserialized<Event>[]) => {
|
|
|
32
32
|
days?: Deserialized<import("../types/days").Day>[] | undefined;
|
|
33
33
|
updatedAt?: string | undefined;
|
|
34
34
|
displayName?: string | undefined;
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
durationVariance?: number | undefined;
|
|
38
|
-
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
35
|
+
density?: number | undefined;
|
|
36
|
+
weight?: number | undefined;
|
|
39
37
|
ids?: string | undefined;
|
|
40
38
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
41
|
-
|
|
42
|
-
density?: number | undefined;
|
|
39
|
+
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
43
40
|
centerOfAttraction?: string | null | undefined;
|
|
41
|
+
parked?: boolean | undefined;
|
|
44
42
|
fixedStart?: boolean | undefined;
|
|
43
|
+
duration?: number | undefined;
|
|
45
44
|
preferredDuration?: number | undefined;
|
|
45
|
+
durationVariance?: number | undefined;
|
|
46
46
|
}[];
|
|
47
47
|
export default _default;
|
|
@@ -7,14 +7,14 @@ declare const _default: (groups: Deserialized<Group>[]) => {
|
|
|
7
7
|
days?: Deserialized<import("../types/days").Day>[] | undefined;
|
|
8
8
|
updatedAt?: string | undefined;
|
|
9
9
|
displayName?: string | undefined;
|
|
10
|
-
|
|
10
|
+
weight?: number | undefined;
|
|
11
11
|
ids?: string | undefined;
|
|
12
12
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
13
|
+
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
13
14
|
maxNumWorkingHours?: number | boolean | undefined;
|
|
14
15
|
maxNumDailyWorkingHours?: number | boolean | number[] | undefined;
|
|
15
16
|
forbidOverlappingEvents?: boolean | undefined;
|
|
16
17
|
disableDayLengthPunishment?: boolean | undefined;
|
|
17
|
-
weight?: number | undefined;
|
|
18
18
|
rank?: number | undefined;
|
|
19
19
|
species?: string | undefined;
|
|
20
20
|
}[];
|
|
@@ -28,7 +28,7 @@ import { Serialized, Deserialized } from '../../types';
|
|
|
28
28
|
export default function (schedule: Deserialized<CoreTypes.schedule>): {
|
|
29
29
|
settings: import("../types/division-settings").DivisionSettings;
|
|
30
30
|
rootIntervals: import("../types/root-intervals").RootInterval[];
|
|
31
|
-
overlapGroups: Serialized<Omit<import("../types/overlap-groups").OverlapGroup, "
|
|
31
|
+
overlapGroups: Serialized<Omit<import("../types/overlap-groups").OverlapGroup, "lastModifiedBy" | "belongsTo">>[];
|
|
32
32
|
lockedTimes: import("../types/locked-times").LockedTime[];
|
|
33
33
|
events: {
|
|
34
34
|
period?: string | undefined;
|
|
@@ -62,17 +62,17 @@ export default function (schedule: Deserialized<CoreTypes.schedule>): {
|
|
|
62
62
|
days?: Deserialized<import("../types/days").Day>[] | undefined;
|
|
63
63
|
updatedAt?: string | undefined;
|
|
64
64
|
displayName?: string | undefined;
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
durationVariance?: number | undefined;
|
|
68
|
-
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
65
|
+
density?: number | undefined;
|
|
66
|
+
weight?: number | undefined;
|
|
69
67
|
ids?: string | undefined;
|
|
70
68
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
71
|
-
|
|
72
|
-
density?: number | undefined;
|
|
69
|
+
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
73
70
|
centerOfAttraction?: string | null | undefined;
|
|
71
|
+
parked?: boolean | undefined;
|
|
74
72
|
fixedStart?: boolean | undefined;
|
|
73
|
+
duration?: number | undefined;
|
|
75
74
|
preferredDuration?: number | undefined;
|
|
75
|
+
durationVariance?: number | undefined;
|
|
76
76
|
}[];
|
|
77
77
|
courses: {
|
|
78
78
|
period?: string | undefined;
|
|
@@ -102,14 +102,14 @@ export default function (schedule: Deserialized<CoreTypes.schedule>): {
|
|
|
102
102
|
comment?: string | undefined;
|
|
103
103
|
updatedAt?: string | undefined;
|
|
104
104
|
displayName?: string | undefined;
|
|
105
|
-
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
106
|
-
ids?: string | undefined;
|
|
107
|
-
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
108
|
-
weight?: number | undefined;
|
|
109
105
|
density?: number | undefined;
|
|
106
|
+
weight?: number | undefined;
|
|
107
|
+
ids?: string | undefined;
|
|
110
108
|
subject?: string | undefined;
|
|
109
|
+
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
111
110
|
eventDurationVariance?: number | undefined;
|
|
112
111
|
totalTime?: string | undefined;
|
|
112
|
+
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
113
113
|
centerOfAttraction?: string | null | undefined;
|
|
114
114
|
minutesPerWeek?: number | undefined;
|
|
115
115
|
expectedTotalHours?: number | undefined;
|
|
@@ -150,14 +150,14 @@ export default function (schedule: Deserialized<CoreTypes.schedule>): {
|
|
|
150
150
|
days?: Deserialized<import("../types/days").Day>[] | undefined;
|
|
151
151
|
updatedAt?: string | undefined;
|
|
152
152
|
displayName?: string | undefined;
|
|
153
|
-
|
|
153
|
+
weight?: number | undefined;
|
|
154
154
|
ids?: string | undefined;
|
|
155
155
|
minBreakLength?: import("../types/break-lengths").BreakLength | undefined;
|
|
156
|
+
intervals?: Deserialized<import("../types/intervals").Interval>[] | undefined;
|
|
156
157
|
maxNumWorkingHours?: number | boolean | undefined;
|
|
157
158
|
maxNumDailyWorkingHours?: number | boolean | number[] | undefined;
|
|
158
159
|
forbidOverlappingEvents?: boolean | undefined;
|
|
159
160
|
disableDayLengthPunishment?: boolean | undefined;
|
|
160
|
-
weight?: number | undefined;
|
|
161
161
|
rank?: number | undefined;
|
|
162
162
|
species?: string | undefined;
|
|
163
163
|
}[];
|
|
@@ -206,6 +206,7 @@ export default function (schedule: Deserialized<CoreTypes.schedule>): {
|
|
|
206
206
|
}[] | undefined;
|
|
207
207
|
}[];
|
|
208
208
|
periods: import("../types/periods").Period[];
|
|
209
|
+
calendarExceptions: import("../types/calendar-exceptions").CalendarException[];
|
|
209
210
|
division: Pick<import("../types/divisions").Division, "end" | "start" | "displayName">;
|
|
210
211
|
meta: {
|
|
211
212
|
structure: "RS/core-2.0.0";
|
|
@@ -4,6 +4,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.default = _default;
|
|
7
|
+
var _calendarExceptions2 = _interopRequireDefault(require("./calendar-exceptions"));
|
|
7
8
|
var _periods2 = _interopRequireDefault(require("./periods"));
|
|
8
9
|
var _locations2 = _interopRequireDefault(require("./locations"));
|
|
9
10
|
var _teachers2 = _interopRequireDefault(require("./teachers"));
|
|
@@ -35,14 +36,17 @@ function _default(schedule) {
|
|
|
35
36
|
persons,
|
|
36
37
|
lockedTimes,
|
|
37
38
|
rootIntervals,
|
|
38
|
-
overlapGroups
|
|
39
|
+
overlapGroups,
|
|
40
|
+
calendarExceptions
|
|
39
41
|
} = schedule;
|
|
40
|
-
return _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({
|
|
42
|
+
return _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({
|
|
41
43
|
meta: {
|
|
42
44
|
structure: 'RS/core-2.0.0'
|
|
43
45
|
}
|
|
44
46
|
}, division && {
|
|
45
47
|
division: (0, _division2.default)(division)
|
|
48
|
+
}), calendarExceptions && {
|
|
49
|
+
calendarExceptions: (0, _calendarExceptions2.default)(calendarExceptions)
|
|
46
50
|
}), periods && {
|
|
47
51
|
periods: (0, _periods2.default)(periods)
|
|
48
52
|
}), locations && {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schedules.js","names":["
|
|
1
|
+
{"version":3,"file":"schedules.js","names":["_calendarExceptions2","_interopRequireDefault","require","_periods2","_locations2","_teachers2","_groups2","_persons2","_courses2","_events2","_lockedTimes2","_overlapGroups2","_rootIntervals2","_settings2","_division2","obj","__esModule","default","ownKeys","e","r","t","Object","keys","getOwnPropertySymbols","o","filter","getOwnPropertyDescriptor","enumerable","push","apply","_objectSpread","arguments","length","forEach","_defineProperty","getOwnPropertyDescriptors","defineProperties","defineProperty","key","value","_toPropertyKey","configurable","writable","arg","_toPrimitive","String","input","hint","prim","Symbol","toPrimitive","undefined","res","call","TypeError","Number","_default","schedule","divisions","division","periods","groups","courses","teachers","locations","settings","events","persons","lockedTimes","rootIntervals","overlapGroups","calendarExceptions","meta","structure","_division","_calendarExceptions","_periods","_locations","_teachers","_groups","_persons","_courses","_events","_lockedTimes","_overlapGroups","_rootIntervals","_settings"],"sources":["../../../../src/core/v2/to/schedules.ts"],"sourcesContent":[null],"mappings":";;;;;;AAEA,IAAAA,oBAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,SAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAAAE,WAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,UAAA,GAAAJ,sBAAA,CAAAC,OAAA;AACA,IAAAI,QAAA,GAAAL,sBAAA,CAAAC,OAAA;AACA,IAAAK,SAAA,GAAAN,sBAAA,CAAAC,OAAA;AACA,IAAAM,SAAA,GAAAP,sBAAA,CAAAC,OAAA;AACA,IAAAO,QAAA,GAAAR,sBAAA,CAAAC,OAAA;AACA,IAAAQ,aAAA,GAAAT,sB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
+
import { Edge } from '../../types';
|
|
4
|
+
import { Division } from './divisions';
|
|
5
|
+
import { Event } from './events';
|
|
6
|
+
import { Group } from './groups';
|
|
7
|
+
import { Teacher } from './teachers';
|
|
8
|
+
import { Person } from './persons';
|
|
9
|
+
import { Location } from './locations';
|
|
10
|
+
import { Course } from './courses';
|
|
11
|
+
export interface CalendarExceptionBare {
|
|
12
|
+
belongsTo?: Edge<Division>;
|
|
13
|
+
reason?: string;
|
|
14
|
+
description?: string;
|
|
15
|
+
sources?: Coalesced<Event | Course>[];
|
|
16
|
+
start?: Date;
|
|
17
|
+
end?: Date;
|
|
18
|
+
action?: 'cancel' | 'remove' | 'reschedule' | 'add' | 'substitute';
|
|
19
|
+
exception?: {
|
|
20
|
+
to?: Edge<Group | Course | Teacher | Location | Person>;
|
|
21
|
+
toModel?: 'groups' | 'courses' | 'teachers' | 'locations' | 'persons';
|
|
22
|
+
include?: boolean;
|
|
23
|
+
start?: Date;
|
|
24
|
+
end?: Date;
|
|
25
|
+
};
|
|
26
|
+
lastModifiedBy?: unknown;
|
|
27
|
+
}
|
|
28
|
+
export interface CalendarException extends CalendarExceptionBare {
|
|
29
|
+
_id?: Types.ObjectId;
|
|
30
|
+
id?: string;
|
|
31
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"calendar-exceptions.js","names":[],"sources":["../../../../src/core/v2/types/calendar-exceptions.ts"],"sourcesContent":[null],"mappings":""}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { Area } from './areas';
|
|
2
2
|
import { AvailableLocation } from './available-locations';
|
|
3
3
|
import { BreakLength } from './break-lengths';
|
|
4
|
+
import { CalendarException } from './calendar-exceptions';
|
|
4
5
|
import { Event } from './events';
|
|
5
6
|
import { Course } from './courses';
|
|
6
7
|
import { Day } from './days';
|
|
@@ -22,6 +23,7 @@ export declare namespace Types {
|
|
|
22
23
|
type availableLocation = AvailableLocation;
|
|
23
24
|
type event = Event;
|
|
24
25
|
type breakLength = BreakLength;
|
|
26
|
+
type calendarException = CalendarException;
|
|
25
27
|
type course = Course;
|
|
26
28
|
type day = Day;
|
|
27
29
|
type location = Location;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Edge } from '../../types';
|
|
2
2
|
import { Area } from './areas';
|
|
3
|
+
import { CalendarException } from './calendar-exceptions';
|
|
3
4
|
import { Event } from './events';
|
|
4
5
|
import { Course } from './courses';
|
|
5
6
|
import { DivisionSettings } from './division-settings';
|
|
@@ -14,6 +15,7 @@ import { RootInterval } from './root-intervals';
|
|
|
14
15
|
import { Teacher } from './teachers';
|
|
15
16
|
export type Schedule = {
|
|
16
17
|
divisions: Edge<Division>;
|
|
18
|
+
calendarExceptions: Edge<CalendarException[]>;
|
|
17
19
|
settings: Edge<DivisionSettings>;
|
|
18
20
|
groups: Edge<Group[]>;
|
|
19
21
|
teachers: Edge<Teacher[]>;
|