@digital8/security-registers-backend-ts-sdk 0.0.378 → 0.0.380
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/README.md +2 -2
- package/dist/models/IncidentImageResource.d.ts +1 -1
- package/dist/models/IncidentImageResource.js +3 -1
- package/dist/models/RegisterGroupedByRosterResource.d.ts +1 -1
- package/dist/models/RegisterGroupedByRosterResource.js +4 -3
- package/dist/models/RegisterListResource.d.ts +4 -4
- package/dist/models/RegisterListResource.js +4 -7
- package/dist/models/RegisterResource.d.ts +4 -4
- package/dist/models/RegisterResource.js +13 -9
- package/dist/models/RosterListResource.d.ts +1 -1
- package/dist/models/RosterListResource.js +3 -4
- package/dist/models/RosterLiteResource.d.ts +1 -1
- package/dist/models/RosterLiteResource.js +4 -3
- package/dist/models/SecurityCompanyResource.d.ts +1 -1
- package/dist/models/SecurityCompanyResource.js +3 -1
- package/package.json +1 -1
- package/src/models/IncidentImageResource.ts +3 -2
- package/src/models/RegisterGroupedByRosterResource.ts +4 -3
- package/src/models/RegisterListResource.ts +7 -9
- package/src/models/RegisterResource.ts +12 -10
- package/src/models/RosterListResource.ts +3 -4
- package/src/models/RosterLiteResource.ts +4 -3
- package/src/models/SecurityCompanyResource.ts +3 -2
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
## @digital8/security-registers-backend-ts-sdk@0.0.
|
|
1
|
+
## @digital8/security-registers-backend-ts-sdk@0.0.380
|
|
2
2
|
|
|
3
3
|
This generator creates TypeScript/JavaScript client that utilizes [Fetch API](https://fetch.spec.whatwg.org/). The generated Node module can be used in the following environments:
|
|
4
4
|
|
|
@@ -36,7 +36,7 @@ navigate to the folder of your consuming project and run one of the following co
|
|
|
36
36
|
_published:_
|
|
37
37
|
|
|
38
38
|
```
|
|
39
|
-
npm install @digital8/security-registers-backend-ts-sdk@0.0.
|
|
39
|
+
npm install @digital8/security-registers-backend-ts-sdk@0.0.380 --save
|
|
40
40
|
```
|
|
41
41
|
|
|
42
42
|
_unPublished (not recommended):_
|
|
@@ -26,6 +26,8 @@ function instanceOfIncidentImageResource(value) {
|
|
|
26
26
|
return false;
|
|
27
27
|
if (!('mimeType' in value) || value['mimeType'] === undefined)
|
|
28
28
|
return false;
|
|
29
|
+
if (!('altText' in value) || value['altText'] === undefined)
|
|
30
|
+
return false;
|
|
29
31
|
if (!('assetId' in value) || value['assetId'] === undefined)
|
|
30
32
|
return false;
|
|
31
33
|
if (!('url' in value) || value['url'] === undefined)
|
|
@@ -42,7 +44,7 @@ function IncidentImageResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
42
44
|
return {
|
|
43
45
|
'fileId': json['file_id'],
|
|
44
46
|
'mimeType': json['mime_type'],
|
|
45
|
-
'altText': json['alt_text']
|
|
47
|
+
'altText': json['alt_text'],
|
|
46
48
|
'assetId': json['asset_id'],
|
|
47
49
|
'url': json['url'],
|
|
48
50
|
};
|
|
@@ -32,6 +32,8 @@ function instanceOfRegisterGroupedByRosterResource(value) {
|
|
|
32
32
|
return false;
|
|
33
33
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined)
|
|
34
34
|
return false;
|
|
35
|
+
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined)
|
|
36
|
+
return false;
|
|
35
37
|
if (!('registers' in value) || value['registers'] === undefined)
|
|
36
38
|
return false;
|
|
37
39
|
return true;
|
|
@@ -49,7 +51,7 @@ function RegisterGroupedByRosterResourceFromJSONTyped(json, ignoreDiscriminator)
|
|
|
49
51
|
'timezone': json['timezone'],
|
|
50
52
|
'state': json['state'],
|
|
51
53
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
52
|
-
'finishDateTime':
|
|
54
|
+
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
53
55
|
'registers': (json['registers'] == null ? null : json['registers'].map(RegisterListResource_1.RegisterListResourceFromJSON)),
|
|
54
56
|
};
|
|
55
57
|
}
|
|
@@ -57,7 +59,6 @@ function RegisterGroupedByRosterResourceToJSON(json) {
|
|
|
57
59
|
return RegisterGroupedByRosterResourceToJSONTyped(json, false);
|
|
58
60
|
}
|
|
59
61
|
function RegisterGroupedByRosterResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
60
|
-
var _a;
|
|
61
62
|
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
62
63
|
if (value == null) {
|
|
63
64
|
return value;
|
|
@@ -68,7 +69,7 @@ function RegisterGroupedByRosterResourceToJSONTyped(value, ignoreDiscriminator)
|
|
|
68
69
|
'timezone': value['timezone'],
|
|
69
70
|
'state': value['state'],
|
|
70
71
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
71
|
-
'finishDateTime':
|
|
72
|
+
'finishDateTime': ((value['finishDateTime']).toISOString()),
|
|
72
73
|
'registers': (value['registers'] == null ? null : value['registers'].map(RegisterListResource_1.RegisterListResourceToJSON)),
|
|
73
74
|
};
|
|
74
75
|
}
|
|
@@ -46,13 +46,13 @@ export interface RegisterListResource {
|
|
|
46
46
|
* @type {Date}
|
|
47
47
|
* @memberof RegisterListResource
|
|
48
48
|
*/
|
|
49
|
-
finishDateTime
|
|
49
|
+
finishDateTime?: Date | null;
|
|
50
50
|
/**
|
|
51
51
|
*
|
|
52
|
-
* @type {
|
|
52
|
+
* @type {object}
|
|
53
53
|
* @memberof RegisterListResource
|
|
54
54
|
*/
|
|
55
|
-
shiftLength:
|
|
55
|
+
shiftLength: object;
|
|
56
56
|
/**
|
|
57
57
|
*
|
|
58
58
|
* @type {number}
|
|
@@ -148,7 +148,7 @@ export interface RegisterListResource {
|
|
|
148
148
|
* @type {number}
|
|
149
149
|
* @memberof RegisterListResource
|
|
150
150
|
*/
|
|
151
|
-
signOffLat
|
|
151
|
+
signOffLat?: number | null;
|
|
152
152
|
/**
|
|
153
153
|
*
|
|
154
154
|
* @type {number}
|
|
@@ -30,8 +30,6 @@ function instanceOfRegisterListResource(value) {
|
|
|
30
30
|
return false;
|
|
31
31
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined)
|
|
32
32
|
return false;
|
|
33
|
-
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined)
|
|
34
|
-
return false;
|
|
35
33
|
if (!('shiftLength' in value) || value['shiftLength'] === undefined)
|
|
36
34
|
return false;
|
|
37
35
|
if (!('signOffStatus' in value) || value['signOffStatus'] === undefined)
|
|
@@ -62,8 +60,6 @@ function instanceOfRegisterListResource(value) {
|
|
|
62
60
|
return false;
|
|
63
61
|
if (!('signOnLong' in value) || value['signOnLong'] === undefined)
|
|
64
62
|
return false;
|
|
65
|
-
if (!('signOffLat' in value) || value['signOffLat'] === undefined)
|
|
66
|
-
return false;
|
|
67
63
|
if (!('hasIncidents' in value) || value['hasIncidents'] === undefined)
|
|
68
64
|
return false;
|
|
69
65
|
return true;
|
|
@@ -80,7 +76,7 @@ function RegisterListResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
80
76
|
'user': (0, UserLiteResource_1.UserLiteResourceFromJSON)(json['user']),
|
|
81
77
|
'venue': (0, VenueLiteResource_1.VenueLiteResourceFromJSON)(json['venue']),
|
|
82
78
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
83
|
-
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
79
|
+
'finishDateTime': json['finishDateTime'] == null ? undefined : (new Date(json['finishDateTime'])),
|
|
84
80
|
'shiftLength': json['shiftLength'],
|
|
85
81
|
'signOffStatus': json['signOffStatus'],
|
|
86
82
|
'badgeNumber': json['badgeNumber'] == null ? undefined : json['badgeNumber'],
|
|
@@ -97,7 +93,7 @@ function RegisterListResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
97
93
|
'firstAid': json['firstAid'],
|
|
98
94
|
'signOnLat': json['signOnLat'],
|
|
99
95
|
'signOnLong': json['signOnLong'],
|
|
100
|
-
'signOffLat': json['signOffLat'],
|
|
96
|
+
'signOffLat': json['signOffLat'] == null ? undefined : json['signOffLat'],
|
|
101
97
|
'signOffLong': json['signOffLong'] == null ? undefined : json['signOffLong'],
|
|
102
98
|
'hasIncidents': json['hasIncidents'],
|
|
103
99
|
};
|
|
@@ -106,6 +102,7 @@ function RegisterListResourceToJSON(json) {
|
|
|
106
102
|
return RegisterListResourceToJSONTyped(json, false);
|
|
107
103
|
}
|
|
108
104
|
function RegisterListResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
105
|
+
var _a;
|
|
109
106
|
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
110
107
|
if (value == null) {
|
|
111
108
|
return value;
|
|
@@ -115,7 +112,7 @@ function RegisterListResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
|
115
112
|
'user': (0, UserLiteResource_1.UserLiteResourceToJSON)(value['user']),
|
|
116
113
|
'venue': (0, VenueLiteResource_1.VenueLiteResourceToJSON)(value['venue']),
|
|
117
114
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
118
|
-
'finishDateTime': ((value['finishDateTime']).toISOString()),
|
|
115
|
+
'finishDateTime': value['finishDateTime'] === null ? null : ((_a = value['finishDateTime']) === null || _a === void 0 ? void 0 : _a.toISOString()),
|
|
119
116
|
'shiftLength': value['shiftLength'],
|
|
120
117
|
'signOffStatus': value['signOffStatus'],
|
|
121
118
|
'badgeNumber': value['badgeNumber'],
|
|
@@ -46,7 +46,7 @@ export interface RegisterResource {
|
|
|
46
46
|
* @type {Date}
|
|
47
47
|
* @memberof RegisterResource
|
|
48
48
|
*/
|
|
49
|
-
finishDateTime
|
|
49
|
+
finishDateTime: Date;
|
|
50
50
|
/**
|
|
51
51
|
*
|
|
52
52
|
* @type {number}
|
|
@@ -106,13 +106,13 @@ export interface RegisterResource {
|
|
|
106
106
|
* @type {number}
|
|
107
107
|
* @memberof RegisterResource
|
|
108
108
|
*/
|
|
109
|
-
signOffLat
|
|
109
|
+
signOffLat?: number | null;
|
|
110
110
|
/**
|
|
111
111
|
*
|
|
112
112
|
* @type {number}
|
|
113
113
|
* @memberof RegisterResource
|
|
114
114
|
*/
|
|
115
|
-
signOffLong
|
|
115
|
+
signOffLong: number;
|
|
116
116
|
/**
|
|
117
117
|
*
|
|
118
118
|
* @type {string}
|
|
@@ -142,7 +142,7 @@ export interface RegisterResource {
|
|
|
142
142
|
* @type {string}
|
|
143
143
|
* @memberof RegisterResource
|
|
144
144
|
*/
|
|
145
|
-
badgeNumber
|
|
145
|
+
badgeNumber: string;
|
|
146
146
|
/**
|
|
147
147
|
*
|
|
148
148
|
* @type {Date}
|
|
@@ -30,6 +30,8 @@ function instanceOfRegisterResource(value) {
|
|
|
30
30
|
return false;
|
|
31
31
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined)
|
|
32
32
|
return false;
|
|
33
|
+
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined)
|
|
34
|
+
return false;
|
|
33
35
|
if (!('signOffStatus' in value) || value['signOffStatus'] === undefined)
|
|
34
36
|
return false;
|
|
35
37
|
if (!('signOnSignature' in value) || value['signOnSignature'] === undefined)
|
|
@@ -48,7 +50,7 @@ function instanceOfRegisterResource(value) {
|
|
|
48
50
|
return false;
|
|
49
51
|
if (!('signOnLong' in value) || value['signOnLong'] === undefined)
|
|
50
52
|
return false;
|
|
51
|
-
if (!('
|
|
53
|
+
if (!('signOffLong' in value) || value['signOffLong'] === undefined)
|
|
52
54
|
return false;
|
|
53
55
|
if (!('licenceNumber' in value) || value['licenceNumber'] === undefined)
|
|
54
56
|
return false;
|
|
@@ -58,6 +60,8 @@ function instanceOfRegisterResource(value) {
|
|
|
58
60
|
return false;
|
|
59
61
|
if (!('licenceLastName' in value) || value['licenceLastName'] === undefined)
|
|
60
62
|
return false;
|
|
63
|
+
if (!('badgeNumber' in value) || value['badgeNumber'] === undefined)
|
|
64
|
+
return false;
|
|
61
65
|
if (!('rampReadAt' in value) || value['rampReadAt'] === undefined)
|
|
62
66
|
return false;
|
|
63
67
|
return true;
|
|
@@ -74,7 +78,7 @@ function RegisterResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
74
78
|
'venue': (0, VenueLiteResource_1.VenueLiteResourceFromJSON)(json['venue']),
|
|
75
79
|
'user': (0, UserLiteResource_1.UserLiteResourceFromJSON)(json['user']),
|
|
76
80
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
77
|
-
'finishDateTime':
|
|
81
|
+
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
78
82
|
'signOffStatus': json['signOffStatus'],
|
|
79
83
|
'signOnSignature': json['signOnSignature'],
|
|
80
84
|
'signOffSignature': json['signOffSignature'],
|
|
@@ -84,13 +88,13 @@ function RegisterResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
84
88
|
'firstAidImage': json['firstAidImage'],
|
|
85
89
|
'signOnLat': json['signOnLat'],
|
|
86
90
|
'signOnLong': json['signOnLong'],
|
|
87
|
-
'signOffLat': json['signOffLat'],
|
|
88
|
-
'signOffLong': json['signOffLong']
|
|
91
|
+
'signOffLat': json['signOffLat'] == null ? undefined : json['signOffLat'],
|
|
92
|
+
'signOffLong': json['signOffLong'],
|
|
89
93
|
'licenceNumber': json['licenceNumber'],
|
|
90
94
|
'licenceExpiry': json['licenceExpiry'],
|
|
91
95
|
'licenceFirstName': json['licenceFirstName'],
|
|
92
96
|
'licenceLastName': json['licenceLastName'],
|
|
93
|
-
'badgeNumber': json['badgeNumber']
|
|
97
|
+
'badgeNumber': json['badgeNumber'],
|
|
94
98
|
'rampReadAt': (new Date(json['rampReadAt'])),
|
|
95
99
|
'createdAt': json['createdAt'] == null ? undefined : (new Date(json['createdAt'])),
|
|
96
100
|
'updatedAt': json['updatedAt'] == null ? undefined : (new Date(json['updatedAt'])),
|
|
@@ -100,7 +104,7 @@ function RegisterResourceToJSON(json) {
|
|
|
100
104
|
return RegisterResourceToJSONTyped(json, false);
|
|
101
105
|
}
|
|
102
106
|
function RegisterResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
103
|
-
var _a, _b
|
|
107
|
+
var _a, _b;
|
|
104
108
|
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
105
109
|
if (value == null) {
|
|
106
110
|
return value;
|
|
@@ -110,7 +114,7 @@ function RegisterResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
|
110
114
|
'venue': (0, VenueLiteResource_1.VenueLiteResourceToJSON)(value['venue']),
|
|
111
115
|
'user': (0, UserLiteResource_1.UserLiteResourceToJSON)(value['user']),
|
|
112
116
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
113
|
-
'finishDateTime':
|
|
117
|
+
'finishDateTime': ((value['finishDateTime']).toISOString()),
|
|
114
118
|
'signOffStatus': value['signOffStatus'],
|
|
115
119
|
'signOnSignature': value['signOnSignature'],
|
|
116
120
|
'signOffSignature': value['signOffSignature'],
|
|
@@ -128,7 +132,7 @@ function RegisterResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
|
128
132
|
'licenceLastName': value['licenceLastName'],
|
|
129
133
|
'badgeNumber': value['badgeNumber'],
|
|
130
134
|
'rampReadAt': ((value['rampReadAt']).toISOString()),
|
|
131
|
-
'createdAt': value['createdAt'] === null ? null : ((
|
|
132
|
-
'updatedAt': value['updatedAt'] === null ? null : ((
|
|
135
|
+
'createdAt': value['createdAt'] === null ? null : ((_a = value['createdAt']) === null || _a === void 0 ? void 0 : _a.toISOString()),
|
|
136
|
+
'updatedAt': value['updatedAt'] === null ? null : ((_b = value['updatedAt']) === null || _b === void 0 ? void 0 : _b.toISOString()),
|
|
133
137
|
};
|
|
134
138
|
}
|
|
@@ -30,8 +30,6 @@ function instanceOfRosterListResource(value) {
|
|
|
30
30
|
return false;
|
|
31
31
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined)
|
|
32
32
|
return false;
|
|
33
|
-
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined)
|
|
34
|
-
return false;
|
|
35
33
|
if (!('isCompliant' in value) || value['isCompliant'] === undefined)
|
|
36
34
|
return false;
|
|
37
35
|
if (!('isComplete' in value) || value['isComplete'] === undefined)
|
|
@@ -54,7 +52,7 @@ function RosterListResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
54
52
|
'venue': (0, VenueLiteResource_1.VenueLiteResourceFromJSON)(json['venue']),
|
|
55
53
|
'securityCompany': (0, SecurityCompanyLiteResource_1.SecurityCompanyLiteResourceFromJSON)(json['securityCompany']),
|
|
56
54
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
57
|
-
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
55
|
+
'finishDateTime': json['finishDateTime'] == null ? undefined : (new Date(json['finishDateTime'])),
|
|
58
56
|
'isCompliant': json['isCompliant'],
|
|
59
57
|
'isComplete': json['isComplete'],
|
|
60
58
|
'signOffStatus': json['signOffStatus'],
|
|
@@ -65,6 +63,7 @@ function RosterListResourceToJSON(json) {
|
|
|
65
63
|
return RosterListResourceToJSONTyped(json, false);
|
|
66
64
|
}
|
|
67
65
|
function RosterListResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
66
|
+
var _a;
|
|
68
67
|
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
69
68
|
if (value == null) {
|
|
70
69
|
return value;
|
|
@@ -74,7 +73,7 @@ function RosterListResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
|
74
73
|
'venue': (0, VenueLiteResource_1.VenueLiteResourceToJSON)(value['venue']),
|
|
75
74
|
'securityCompany': (0, SecurityCompanyLiteResource_1.SecurityCompanyLiteResourceToJSON)(value['securityCompany']),
|
|
76
75
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
77
|
-
'finishDateTime': ((value['finishDateTime']).toISOString()),
|
|
76
|
+
'finishDateTime': value['finishDateTime'] === null ? null : ((_a = value['finishDateTime']) === null || _a === void 0 ? void 0 : _a.toISOString()),
|
|
78
77
|
'isCompliant': value['isCompliant'],
|
|
79
78
|
'isComplete': value['isComplete'],
|
|
80
79
|
'signOffStatus': value['signOffStatus'],
|
|
@@ -24,6 +24,8 @@ exports.RosterLiteResourceToJSONTyped = RosterLiteResourceToJSONTyped;
|
|
|
24
24
|
function instanceOfRosterLiteResource(value) {
|
|
25
25
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined)
|
|
26
26
|
return false;
|
|
27
|
+
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined)
|
|
28
|
+
return false;
|
|
27
29
|
return true;
|
|
28
30
|
}
|
|
29
31
|
function RosterLiteResourceFromJSON(json) {
|
|
@@ -36,14 +38,13 @@ function RosterLiteResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
36
38
|
return {
|
|
37
39
|
'id': json['id'] == null ? undefined : json['id'],
|
|
38
40
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
39
|
-
'finishDateTime':
|
|
41
|
+
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
40
42
|
};
|
|
41
43
|
}
|
|
42
44
|
function RosterLiteResourceToJSON(json) {
|
|
43
45
|
return RosterLiteResourceToJSONTyped(json, false);
|
|
44
46
|
}
|
|
45
47
|
function RosterLiteResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
46
|
-
var _a;
|
|
47
48
|
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
48
49
|
if (value == null) {
|
|
49
50
|
return value;
|
|
@@ -51,6 +52,6 @@ function RosterLiteResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
|
51
52
|
return {
|
|
52
53
|
'id': value['id'],
|
|
53
54
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
54
|
-
'finishDateTime':
|
|
55
|
+
'finishDateTime': ((value['finishDateTime']).toISOString()),
|
|
55
56
|
};
|
|
56
57
|
}
|
|
@@ -25,6 +25,8 @@ var AddressResource_1 = require("./AddressResource");
|
|
|
25
25
|
function instanceOfSecurityCompanyResource(value) {
|
|
26
26
|
if (!('name' in value) || value['name'] === undefined)
|
|
27
27
|
return false;
|
|
28
|
+
if (!('email' in value) || value['email'] === undefined)
|
|
29
|
+
return false;
|
|
28
30
|
if (!('isEnabled' in value) || value['isEnabled'] === undefined)
|
|
29
31
|
return false;
|
|
30
32
|
if (!('address' in value) || value['address'] === undefined)
|
|
@@ -43,7 +45,7 @@ function SecurityCompanyResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
43
45
|
return {
|
|
44
46
|
'id': json['id'] == null ? undefined : json['id'],
|
|
45
47
|
'name': json['name'],
|
|
46
|
-
'email': json['email']
|
|
48
|
+
'email': json['email'],
|
|
47
49
|
'isEnabled': json['isEnabled'],
|
|
48
50
|
'address': (0, AddressResource_1.AddressResourceFromJSON)(json['address']),
|
|
49
51
|
'licenceNumber': json['licenceNumber'],
|
package/package.json
CHANGED
|
@@ -36,7 +36,7 @@ export interface IncidentImageResource {
|
|
|
36
36
|
* @type {string}
|
|
37
37
|
* @memberof IncidentImageResource
|
|
38
38
|
*/
|
|
39
|
-
altText
|
|
39
|
+
altText: string;
|
|
40
40
|
/**
|
|
41
41
|
*
|
|
42
42
|
* @type {number}
|
|
@@ -57,6 +57,7 @@ export interface IncidentImageResource {
|
|
|
57
57
|
export function instanceOfIncidentImageResource(value: object): value is IncidentImageResource {
|
|
58
58
|
if (!('fileId' in value) || value['fileId'] === undefined) return false;
|
|
59
59
|
if (!('mimeType' in value) || value['mimeType'] === undefined) return false;
|
|
60
|
+
if (!('altText' in value) || value['altText'] === undefined) return false;
|
|
60
61
|
if (!('assetId' in value) || value['assetId'] === undefined) return false;
|
|
61
62
|
if (!('url' in value) || value['url'] === undefined) return false;
|
|
62
63
|
return true;
|
|
@@ -74,7 +75,7 @@ export function IncidentImageResourceFromJSONTyped(json: any, ignoreDiscriminato
|
|
|
74
75
|
|
|
75
76
|
'fileId': json['file_id'],
|
|
76
77
|
'mimeType': json['mime_type'],
|
|
77
|
-
'altText': json['alt_text']
|
|
78
|
+
'altText': json['alt_text'],
|
|
78
79
|
'assetId': json['asset_id'],
|
|
79
80
|
'url': json['url'],
|
|
80
81
|
};
|
|
@@ -69,7 +69,7 @@ export interface RegisterGroupedByRosterResource {
|
|
|
69
69
|
* @type {Date}
|
|
70
70
|
* @memberof RegisterGroupedByRosterResource
|
|
71
71
|
*/
|
|
72
|
-
finishDateTime
|
|
72
|
+
finishDateTime: Date;
|
|
73
73
|
/**
|
|
74
74
|
*
|
|
75
75
|
* @type {Array<RegisterListResource>}
|
|
@@ -86,6 +86,7 @@ export function instanceOfRegisterGroupedByRosterResource(value: object): value
|
|
|
86
86
|
if (!('timezone' in value) || value['timezone'] === undefined) return false;
|
|
87
87
|
if (!('state' in value) || value['state'] === undefined) return false;
|
|
88
88
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined) return false;
|
|
89
|
+
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined) return false;
|
|
89
90
|
if (!('registers' in value) || value['registers'] === undefined) return false;
|
|
90
91
|
return true;
|
|
91
92
|
}
|
|
@@ -105,7 +106,7 @@ export function RegisterGroupedByRosterResourceFromJSONTyped(json: any, ignoreDi
|
|
|
105
106
|
'timezone': json['timezone'],
|
|
106
107
|
'state': json['state'],
|
|
107
108
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
108
|
-
'finishDateTime':
|
|
109
|
+
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
109
110
|
'registers': (json['registers'] == null ? null : (json['registers'] as Array<any>).map(RegisterListResourceFromJSON)),
|
|
110
111
|
};
|
|
111
112
|
}
|
|
@@ -126,7 +127,7 @@ export function RegisterGroupedByRosterResourceToJSONTyped(value?: RegisterGroup
|
|
|
126
127
|
'timezone': value['timezone'],
|
|
127
128
|
'state': value['state'],
|
|
128
129
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
129
|
-
'finishDateTime':
|
|
130
|
+
'finishDateTime': ((value['finishDateTime']).toISOString()),
|
|
130
131
|
'registers': (value['registers'] == null ? null : (value['registers'] as Array<any>).map(RegisterListResourceToJSON)),
|
|
131
132
|
};
|
|
132
133
|
}
|
|
@@ -63,13 +63,13 @@ export interface RegisterListResource {
|
|
|
63
63
|
* @type {Date}
|
|
64
64
|
* @memberof RegisterListResource
|
|
65
65
|
*/
|
|
66
|
-
finishDateTime
|
|
66
|
+
finishDateTime?: Date | null;
|
|
67
67
|
/**
|
|
68
68
|
*
|
|
69
|
-
* @type {
|
|
69
|
+
* @type {object}
|
|
70
70
|
* @memberof RegisterListResource
|
|
71
71
|
*/
|
|
72
|
-
shiftLength:
|
|
72
|
+
shiftLength: object;
|
|
73
73
|
/**
|
|
74
74
|
*
|
|
75
75
|
* @type {number}
|
|
@@ -165,7 +165,7 @@ export interface RegisterListResource {
|
|
|
165
165
|
* @type {number}
|
|
166
166
|
* @memberof RegisterListResource
|
|
167
167
|
*/
|
|
168
|
-
signOffLat
|
|
168
|
+
signOffLat?: number | null;
|
|
169
169
|
/**
|
|
170
170
|
*
|
|
171
171
|
* @type {number}
|
|
@@ -187,7 +187,6 @@ export function instanceOfRegisterListResource(value: object): value is Register
|
|
|
187
187
|
if (!('user' in value) || value['user'] === undefined) return false;
|
|
188
188
|
if (!('venue' in value) || value['venue'] === undefined) return false;
|
|
189
189
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined) return false;
|
|
190
|
-
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined) return false;
|
|
191
190
|
if (!('shiftLength' in value) || value['shiftLength'] === undefined) return false;
|
|
192
191
|
if (!('signOffStatus' in value) || value['signOffStatus'] === undefined) return false;
|
|
193
192
|
if (!('rampReadAt' in value) || value['rampReadAt'] === undefined) return false;
|
|
@@ -203,7 +202,6 @@ export function instanceOfRegisterListResource(value: object): value is Register
|
|
|
203
202
|
if (!('firstAid' in value) || value['firstAid'] === undefined) return false;
|
|
204
203
|
if (!('signOnLat' in value) || value['signOnLat'] === undefined) return false;
|
|
205
204
|
if (!('signOnLong' in value) || value['signOnLong'] === undefined) return false;
|
|
206
|
-
if (!('signOffLat' in value) || value['signOffLat'] === undefined) return false;
|
|
207
205
|
if (!('hasIncidents' in value) || value['hasIncidents'] === undefined) return false;
|
|
208
206
|
return true;
|
|
209
207
|
}
|
|
@@ -222,7 +220,7 @@ export function RegisterListResourceFromJSONTyped(json: any, ignoreDiscriminator
|
|
|
222
220
|
'user': UserLiteResourceFromJSON(json['user']),
|
|
223
221
|
'venue': VenueLiteResourceFromJSON(json['venue']),
|
|
224
222
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
225
|
-
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
223
|
+
'finishDateTime': json['finishDateTime'] == null ? undefined : (new Date(json['finishDateTime'])),
|
|
226
224
|
'shiftLength': json['shiftLength'],
|
|
227
225
|
'signOffStatus': json['signOffStatus'],
|
|
228
226
|
'badgeNumber': json['badgeNumber'] == null ? undefined : json['badgeNumber'],
|
|
@@ -239,7 +237,7 @@ export function RegisterListResourceFromJSONTyped(json: any, ignoreDiscriminator
|
|
|
239
237
|
'firstAid': json['firstAid'],
|
|
240
238
|
'signOnLat': json['signOnLat'],
|
|
241
239
|
'signOnLong': json['signOnLong'],
|
|
242
|
-
'signOffLat': json['signOffLat'],
|
|
240
|
+
'signOffLat': json['signOffLat'] == null ? undefined : json['signOffLat'],
|
|
243
241
|
'signOffLong': json['signOffLong'] == null ? undefined : json['signOffLong'],
|
|
244
242
|
'hasIncidents': json['hasIncidents'],
|
|
245
243
|
};
|
|
@@ -260,7 +258,7 @@ export function RegisterListResourceToJSONTyped(value?: RegisterListResource | n
|
|
|
260
258
|
'user': UserLiteResourceToJSON(value['user']),
|
|
261
259
|
'venue': VenueLiteResourceToJSON(value['venue']),
|
|
262
260
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
263
|
-
'finishDateTime': ((value['finishDateTime'])
|
|
261
|
+
'finishDateTime': value['finishDateTime'] === null ? null : ((value['finishDateTime'] as any)?.toISOString()),
|
|
264
262
|
'shiftLength': value['shiftLength'],
|
|
265
263
|
'signOffStatus': value['signOffStatus'],
|
|
266
264
|
'badgeNumber': value['badgeNumber'],
|
|
@@ -63,7 +63,7 @@ export interface RegisterResource {
|
|
|
63
63
|
* @type {Date}
|
|
64
64
|
* @memberof RegisterResource
|
|
65
65
|
*/
|
|
66
|
-
finishDateTime
|
|
66
|
+
finishDateTime: Date;
|
|
67
67
|
/**
|
|
68
68
|
*
|
|
69
69
|
* @type {number}
|
|
@@ -123,13 +123,13 @@ export interface RegisterResource {
|
|
|
123
123
|
* @type {number}
|
|
124
124
|
* @memberof RegisterResource
|
|
125
125
|
*/
|
|
126
|
-
signOffLat
|
|
126
|
+
signOffLat?: number | null;
|
|
127
127
|
/**
|
|
128
128
|
*
|
|
129
129
|
* @type {number}
|
|
130
130
|
* @memberof RegisterResource
|
|
131
131
|
*/
|
|
132
|
-
signOffLong
|
|
132
|
+
signOffLong: number;
|
|
133
133
|
/**
|
|
134
134
|
*
|
|
135
135
|
* @type {string}
|
|
@@ -159,7 +159,7 @@ export interface RegisterResource {
|
|
|
159
159
|
* @type {string}
|
|
160
160
|
* @memberof RegisterResource
|
|
161
161
|
*/
|
|
162
|
-
badgeNumber
|
|
162
|
+
badgeNumber: string;
|
|
163
163
|
/**
|
|
164
164
|
*
|
|
165
165
|
* @type {Date}
|
|
@@ -187,6 +187,7 @@ export function instanceOfRegisterResource(value: object): value is RegisterReso
|
|
|
187
187
|
if (!('venue' in value) || value['venue'] === undefined) return false;
|
|
188
188
|
if (!('user' in value) || value['user'] === undefined) return false;
|
|
189
189
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined) return false;
|
|
190
|
+
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined) return false;
|
|
190
191
|
if (!('signOffStatus' in value) || value['signOffStatus'] === undefined) return false;
|
|
191
192
|
if (!('signOnSignature' in value) || value['signOnSignature'] === undefined) return false;
|
|
192
193
|
if (!('signOffSignature' in value) || value['signOffSignature'] === undefined) return false;
|
|
@@ -196,11 +197,12 @@ export function instanceOfRegisterResource(value: object): value is RegisterReso
|
|
|
196
197
|
if (!('firstAidImage' in value) || value['firstAidImage'] === undefined) return false;
|
|
197
198
|
if (!('signOnLat' in value) || value['signOnLat'] === undefined) return false;
|
|
198
199
|
if (!('signOnLong' in value) || value['signOnLong'] === undefined) return false;
|
|
199
|
-
if (!('
|
|
200
|
+
if (!('signOffLong' in value) || value['signOffLong'] === undefined) return false;
|
|
200
201
|
if (!('licenceNumber' in value) || value['licenceNumber'] === undefined) return false;
|
|
201
202
|
if (!('licenceExpiry' in value) || value['licenceExpiry'] === undefined) return false;
|
|
202
203
|
if (!('licenceFirstName' in value) || value['licenceFirstName'] === undefined) return false;
|
|
203
204
|
if (!('licenceLastName' in value) || value['licenceLastName'] === undefined) return false;
|
|
205
|
+
if (!('badgeNumber' in value) || value['badgeNumber'] === undefined) return false;
|
|
204
206
|
if (!('rampReadAt' in value) || value['rampReadAt'] === undefined) return false;
|
|
205
207
|
return true;
|
|
206
208
|
}
|
|
@@ -219,7 +221,7 @@ export function RegisterResourceFromJSONTyped(json: any, ignoreDiscriminator: bo
|
|
|
219
221
|
'venue': VenueLiteResourceFromJSON(json['venue']),
|
|
220
222
|
'user': UserLiteResourceFromJSON(json['user']),
|
|
221
223
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
222
|
-
'finishDateTime':
|
|
224
|
+
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
223
225
|
'signOffStatus': json['signOffStatus'],
|
|
224
226
|
'signOnSignature': json['signOnSignature'],
|
|
225
227
|
'signOffSignature': json['signOffSignature'],
|
|
@@ -229,13 +231,13 @@ export function RegisterResourceFromJSONTyped(json: any, ignoreDiscriminator: bo
|
|
|
229
231
|
'firstAidImage': json['firstAidImage'],
|
|
230
232
|
'signOnLat': json['signOnLat'],
|
|
231
233
|
'signOnLong': json['signOnLong'],
|
|
232
|
-
'signOffLat': json['signOffLat'],
|
|
233
|
-
'signOffLong': json['signOffLong']
|
|
234
|
+
'signOffLat': json['signOffLat'] == null ? undefined : json['signOffLat'],
|
|
235
|
+
'signOffLong': json['signOffLong'],
|
|
234
236
|
'licenceNumber': json['licenceNumber'],
|
|
235
237
|
'licenceExpiry': json['licenceExpiry'],
|
|
236
238
|
'licenceFirstName': json['licenceFirstName'],
|
|
237
239
|
'licenceLastName': json['licenceLastName'],
|
|
238
|
-
'badgeNumber': json['badgeNumber']
|
|
240
|
+
'badgeNumber': json['badgeNumber'],
|
|
239
241
|
'rampReadAt': (new Date(json['rampReadAt'])),
|
|
240
242
|
'createdAt': json['createdAt'] == null ? undefined : (new Date(json['createdAt'])),
|
|
241
243
|
'updatedAt': json['updatedAt'] == null ? undefined : (new Date(json['updatedAt'])),
|
|
@@ -257,7 +259,7 @@ export function RegisterResourceToJSONTyped(value?: RegisterResource | null, ign
|
|
|
257
259
|
'venue': VenueLiteResourceToJSON(value['venue']),
|
|
258
260
|
'user': UserLiteResourceToJSON(value['user']),
|
|
259
261
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
260
|
-
'finishDateTime':
|
|
262
|
+
'finishDateTime': ((value['finishDateTime']).toISOString()),
|
|
261
263
|
'signOffStatus': value['signOffStatus'],
|
|
262
264
|
'signOnSignature': value['signOnSignature'],
|
|
263
265
|
'signOffSignature': value['signOffSignature'],
|
|
@@ -63,7 +63,7 @@ export interface RosterListResource {
|
|
|
63
63
|
* @type {Date}
|
|
64
64
|
* @memberof RosterListResource
|
|
65
65
|
*/
|
|
66
|
-
finishDateTime
|
|
66
|
+
finishDateTime?: Date | null;
|
|
67
67
|
/**
|
|
68
68
|
*
|
|
69
69
|
* @type {boolean}
|
|
@@ -97,7 +97,6 @@ export function instanceOfRosterListResource(value: object): value is RosterList
|
|
|
97
97
|
if (!('venue' in value) || value['venue'] === undefined) return false;
|
|
98
98
|
if (!('securityCompany' in value) || value['securityCompany'] === undefined) return false;
|
|
99
99
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined) return false;
|
|
100
|
-
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined) return false;
|
|
101
100
|
if (!('isCompliant' in value) || value['isCompliant'] === undefined) return false;
|
|
102
101
|
if (!('isComplete' in value) || value['isComplete'] === undefined) return false;
|
|
103
102
|
if (!('signOffStatus' in value) || value['signOffStatus'] === undefined) return false;
|
|
@@ -119,7 +118,7 @@ export function RosterListResourceFromJSONTyped(json: any, ignoreDiscriminator:
|
|
|
119
118
|
'venue': VenueLiteResourceFromJSON(json['venue']),
|
|
120
119
|
'securityCompany': SecurityCompanyLiteResourceFromJSON(json['securityCompany']),
|
|
121
120
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
122
|
-
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
121
|
+
'finishDateTime': json['finishDateTime'] == null ? undefined : (new Date(json['finishDateTime'])),
|
|
123
122
|
'isCompliant': json['isCompliant'],
|
|
124
123
|
'isComplete': json['isComplete'],
|
|
125
124
|
'signOffStatus': json['signOffStatus'],
|
|
@@ -142,7 +141,7 @@ export function RosterListResourceToJSONTyped(value?: RosterListResource | null,
|
|
|
142
141
|
'venue': VenueLiteResourceToJSON(value['venue']),
|
|
143
142
|
'securityCompany': SecurityCompanyLiteResourceToJSON(value['securityCompany']),
|
|
144
143
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
145
|
-
'finishDateTime': ((value['finishDateTime'])
|
|
144
|
+
'finishDateTime': value['finishDateTime'] === null ? null : ((value['finishDateTime'] as any)?.toISOString()),
|
|
146
145
|
'isCompliant': value['isCompliant'],
|
|
147
146
|
'isComplete': value['isComplete'],
|
|
148
147
|
'signOffStatus': value['signOffStatus'],
|
|
@@ -36,7 +36,7 @@ export interface RosterLiteResource {
|
|
|
36
36
|
* @type {Date}
|
|
37
37
|
* @memberof RosterLiteResource
|
|
38
38
|
*/
|
|
39
|
-
finishDateTime
|
|
39
|
+
finishDateTime: Date;
|
|
40
40
|
}
|
|
41
41
|
|
|
42
42
|
/**
|
|
@@ -44,6 +44,7 @@ export interface RosterLiteResource {
|
|
|
44
44
|
*/
|
|
45
45
|
export function instanceOfRosterLiteResource(value: object): value is RosterLiteResource {
|
|
46
46
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined) return false;
|
|
47
|
+
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined) return false;
|
|
47
48
|
return true;
|
|
48
49
|
}
|
|
49
50
|
|
|
@@ -59,7 +60,7 @@ export function RosterLiteResourceFromJSONTyped(json: any, ignoreDiscriminator:
|
|
|
59
60
|
|
|
60
61
|
'id': json['id'] == null ? undefined : json['id'],
|
|
61
62
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
62
|
-
'finishDateTime':
|
|
63
|
+
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
63
64
|
};
|
|
64
65
|
}
|
|
65
66
|
|
|
@@ -76,7 +77,7 @@ export function RosterLiteResourceToJSONTyped(value?: RosterLiteResource | null,
|
|
|
76
77
|
|
|
77
78
|
'id': value['id'],
|
|
78
79
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
79
|
-
'finishDateTime':
|
|
80
|
+
'finishDateTime': ((value['finishDateTime']).toISOString()),
|
|
80
81
|
};
|
|
81
82
|
}
|
|
82
83
|
|
|
@@ -44,7 +44,7 @@ export interface SecurityCompanyResource {
|
|
|
44
44
|
* @type {string}
|
|
45
45
|
* @memberof SecurityCompanyResource
|
|
46
46
|
*/
|
|
47
|
-
email
|
|
47
|
+
email: string;
|
|
48
48
|
/**
|
|
49
49
|
*
|
|
50
50
|
* @type {boolean}
|
|
@@ -82,6 +82,7 @@ export interface SecurityCompanyResource {
|
|
|
82
82
|
*/
|
|
83
83
|
export function instanceOfSecurityCompanyResource(value: object): value is SecurityCompanyResource {
|
|
84
84
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
85
|
+
if (!('email' in value) || value['email'] === undefined) return false;
|
|
85
86
|
if (!('isEnabled' in value) || value['isEnabled'] === undefined) return false;
|
|
86
87
|
if (!('address' in value) || value['address'] === undefined) return false;
|
|
87
88
|
if (!('licenceNumber' in value) || value['licenceNumber'] === undefined) return false;
|
|
@@ -100,7 +101,7 @@ export function SecurityCompanyResourceFromJSONTyped(json: any, ignoreDiscrimina
|
|
|
100
101
|
|
|
101
102
|
'id': json['id'] == null ? undefined : json['id'],
|
|
102
103
|
'name': json['name'],
|
|
103
|
-
'email': json['email']
|
|
104
|
+
'email': json['email'],
|
|
104
105
|
'isEnabled': json['isEnabled'],
|
|
105
106
|
'address': AddressResourceFromJSON(json['address']),
|
|
106
107
|
'licenceNumber': json['licenceNumber'],
|