@digital8/security-registers-backend-ts-sdk 0.0.247 → 0.0.248
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/AddressResource.d.ts +1 -1
- package/dist/models/AddressResource.js +1 -3
- package/dist/models/RegisterGroupedByRosterResource.d.ts +1 -1
- package/dist/models/RegisterGroupedByRosterResource.js +4 -3
- package/dist/models/RegisterListResource.d.ts +5 -5
- package/dist/models/RegisterListResource.js +9 -6
- package/dist/models/RegisterResource.d.ts +2 -2
- package/dist/models/RegisterResource.js +8 -8
- package/dist/models/RosterLiteResource.d.ts +1 -1
- package/dist/models/RosterLiteResource.js +4 -3
- package/dist/models/RosterWithRegistersResource.d.ts +1 -1
- package/dist/models/RosterWithRegistersResource.js +3 -4
- package/dist/models/SecurityCompanyResource.d.ts +1 -1
- package/dist/models/SecurityCompanyResource.js +3 -1
- package/package.json +1 -1
- package/src/models/AddressResource.ts +2 -3
- package/src/models/RegisterGroupedByRosterResource.ts +4 -3
- package/src/models/RegisterListResource.ts +11 -10
- package/src/models/RegisterResource.ts +6 -6
- package/src/models/RosterLiteResource.ts +4 -3
- package/src/models/RosterWithRegistersResource.ts +3 -4
- 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.248
|
|
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.248 --save
|
|
40
40
|
```
|
|
41
41
|
|
|
42
42
|
_unPublished (not recommended):_
|
|
@@ -24,8 +24,6 @@ exports.AddressResourceToJSONTyped = AddressResourceToJSONTyped;
|
|
|
24
24
|
function instanceOfAddressResource(value) {
|
|
25
25
|
if (!('addressLine1' in value) || value['addressLine1'] === undefined)
|
|
26
26
|
return false;
|
|
27
|
-
if (!('addressLine2' in value) || value['addressLine2'] === undefined)
|
|
28
|
-
return false;
|
|
29
27
|
if (!('suburb' in value) || value['suburb'] === undefined)
|
|
30
28
|
return false;
|
|
31
29
|
if (!('city' in value) || value['city'] === undefined)
|
|
@@ -50,7 +48,7 @@ function AddressResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
50
48
|
return {
|
|
51
49
|
'id': json['id'] == null ? undefined : json['id'],
|
|
52
50
|
'addressLine1': json['addressLine1'],
|
|
53
|
-
'addressLine2': json['addressLine2'],
|
|
51
|
+
'addressLine2': json['addressLine2'] == null ? undefined : json['addressLine2'],
|
|
54
52
|
'suburb': json['suburb'],
|
|
55
53
|
'city': json['city'],
|
|
56
54
|
'state': json['state'],
|
|
@@ -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
|
}
|
|
@@ -47,13 +47,13 @@ export interface RegisterListResource {
|
|
|
47
47
|
* @type {Date}
|
|
48
48
|
* @memberof RegisterListResource
|
|
49
49
|
*/
|
|
50
|
-
finishDateTime
|
|
50
|
+
finishDateTime?: Date | null;
|
|
51
51
|
/**
|
|
52
52
|
*
|
|
53
|
-
* @type {
|
|
53
|
+
* @type {object}
|
|
54
54
|
* @memberof RegisterListResource
|
|
55
55
|
*/
|
|
56
|
-
shiftLength:
|
|
56
|
+
shiftLength: object;
|
|
57
57
|
/**
|
|
58
58
|
*
|
|
59
59
|
* @type {number}
|
|
@@ -143,13 +143,13 @@ export interface RegisterListResource {
|
|
|
143
143
|
* @type {number}
|
|
144
144
|
* @memberof RegisterListResource
|
|
145
145
|
*/
|
|
146
|
-
signOffLat
|
|
146
|
+
signOffLat: number;
|
|
147
147
|
/**
|
|
148
148
|
*
|
|
149
149
|
* @type {number}
|
|
150
150
|
* @memberof RegisterListResource
|
|
151
151
|
*/
|
|
152
|
-
signOffLong
|
|
152
|
+
signOffLong: number;
|
|
153
153
|
/**
|
|
154
154
|
*
|
|
155
155
|
* @type {Array<IncidentLiteResource>}
|
|
@@ -31,8 +31,6 @@ function instanceOfRegisterListResource(value) {
|
|
|
31
31
|
return false;
|
|
32
32
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined)
|
|
33
33
|
return false;
|
|
34
|
-
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined)
|
|
35
|
-
return false;
|
|
36
34
|
if (!('shiftLength' in value) || value['shiftLength'] === undefined)
|
|
37
35
|
return false;
|
|
38
36
|
if (!('signOffStatus' in value) || value['signOffStatus'] === undefined)
|
|
@@ -61,6 +59,10 @@ function instanceOfRegisterListResource(value) {
|
|
|
61
59
|
return false;
|
|
62
60
|
if (!('signOnLong' in value) || value['signOnLong'] === undefined)
|
|
63
61
|
return false;
|
|
62
|
+
if (!('signOffLat' in value) || value['signOffLat'] === undefined)
|
|
63
|
+
return false;
|
|
64
|
+
if (!('signOffLong' in value) || value['signOffLong'] === undefined)
|
|
65
|
+
return false;
|
|
64
66
|
if (!('incidents' in value) || value['incidents'] === undefined)
|
|
65
67
|
return false;
|
|
66
68
|
return true;
|
|
@@ -77,7 +79,7 @@ function RegisterListResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
77
79
|
'user': (0, UserLiteResource_1.UserLiteResourceFromJSON)(json['user']),
|
|
78
80
|
'venue': (0, VenueLiteResource_1.VenueLiteResourceFromJSON)(json['venue']),
|
|
79
81
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
80
|
-
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
82
|
+
'finishDateTime': json['finishDateTime'] == null ? undefined : (new Date(json['finishDateTime'])),
|
|
81
83
|
'shiftLength': json['shiftLength'],
|
|
82
84
|
'signOffStatus': json['signOffStatus'],
|
|
83
85
|
'badgeNumber': json['badgeNumber'] == null ? undefined : json['badgeNumber'],
|
|
@@ -93,8 +95,8 @@ function RegisterListResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
93
95
|
'firstAid': json['firstAid'],
|
|
94
96
|
'signOnLat': json['signOnLat'],
|
|
95
97
|
'signOnLong': json['signOnLong'],
|
|
96
|
-
'signOffLat': json['signOffLat']
|
|
97
|
-
'signOffLong': json['signOffLong']
|
|
98
|
+
'signOffLat': json['signOffLat'],
|
|
99
|
+
'signOffLong': json['signOffLong'],
|
|
98
100
|
'incidents': (json['incidents'] == null ? null : json['incidents'].map(IncidentLiteResource_1.IncidentLiteResourceFromJSON)),
|
|
99
101
|
};
|
|
100
102
|
}
|
|
@@ -102,6 +104,7 @@ function RegisterListResourceToJSON(json) {
|
|
|
102
104
|
return RegisterListResourceToJSONTyped(json, false);
|
|
103
105
|
}
|
|
104
106
|
function RegisterListResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
107
|
+
var _a;
|
|
105
108
|
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
106
109
|
if (value == null) {
|
|
107
110
|
return value;
|
|
@@ -111,7 +114,7 @@ function RegisterListResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
|
111
114
|
'user': (0, UserLiteResource_1.UserLiteResourceToJSON)(value['user']),
|
|
112
115
|
'venue': (0, VenueLiteResource_1.VenueLiteResourceToJSON)(value['venue']),
|
|
113
116
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
114
|
-
'finishDateTime': ((value['finishDateTime']).toISOString()),
|
|
117
|
+
'finishDateTime': value['finishDateTime'] === null ? null : ((_a = value['finishDateTime']) === null || _a === void 0 ? void 0 : _a.toISOString()),
|
|
115
118
|
'shiftLength': value['shiftLength'],
|
|
116
119
|
'signOffStatus': value['signOffStatus'],
|
|
117
120
|
'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,7 +106,7 @@ 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}
|
|
@@ -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,8 +50,6 @@ function instanceOfRegisterResource(value) {
|
|
|
48
50
|
return false;
|
|
49
51
|
if (!('signOnLong' in value) || value['signOnLong'] === undefined)
|
|
50
52
|
return false;
|
|
51
|
-
if (!('signOffLat' in value) || value['signOffLat'] === undefined)
|
|
52
|
-
return false;
|
|
53
53
|
if (!('signOffLong' in value) || value['signOffLong'] === undefined)
|
|
54
54
|
return false;
|
|
55
55
|
if (!('licenceNumber' in value) || value['licenceNumber'] === undefined)
|
|
@@ -74,7 +74,7 @@ function RegisterResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
74
74
|
'venue': (0, VenueLiteResource_1.VenueLiteResourceFromJSON)(json['venue']),
|
|
75
75
|
'user': (0, UserLiteResource_1.UserLiteResourceFromJSON)(json['user']),
|
|
76
76
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
77
|
-
'finishDateTime':
|
|
77
|
+
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
78
78
|
'signOffStatus': json['signOffStatus'],
|
|
79
79
|
'signOnSignature': json['signOnSignature'],
|
|
80
80
|
'signOffSignature': json['signOffSignature'],
|
|
@@ -84,7 +84,7 @@ function RegisterResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
84
84
|
'firstAidImage': json['firstAidImage'],
|
|
85
85
|
'signOnLat': json['signOnLat'],
|
|
86
86
|
'signOnLong': json['signOnLong'],
|
|
87
|
-
'signOffLat': json['signOffLat'],
|
|
87
|
+
'signOffLat': json['signOffLat'] == null ? undefined : json['signOffLat'],
|
|
88
88
|
'signOffLong': json['signOffLong'],
|
|
89
89
|
'licenceNumber': json['licenceNumber'],
|
|
90
90
|
'licenceExpiry': json['licenceExpiry'],
|
|
@@ -99,7 +99,7 @@ function RegisterResourceToJSON(json) {
|
|
|
99
99
|
return RegisterResourceToJSONTyped(json, false);
|
|
100
100
|
}
|
|
101
101
|
function RegisterResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
102
|
-
var _a, _b
|
|
102
|
+
var _a, _b;
|
|
103
103
|
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
104
104
|
if (value == null) {
|
|
105
105
|
return value;
|
|
@@ -109,7 +109,7 @@ function RegisterResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
|
109
109
|
'venue': (0, VenueLiteResource_1.VenueLiteResourceToJSON)(value['venue']),
|
|
110
110
|
'user': (0, UserLiteResource_1.UserLiteResourceToJSON)(value['user']),
|
|
111
111
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
112
|
-
'finishDateTime':
|
|
112
|
+
'finishDateTime': ((value['finishDateTime']).toISOString()),
|
|
113
113
|
'signOffStatus': value['signOffStatus'],
|
|
114
114
|
'signOnSignature': value['signOnSignature'],
|
|
115
115
|
'signOffSignature': value['signOffSignature'],
|
|
@@ -126,7 +126,7 @@ function RegisterResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
|
126
126
|
'licenceFirstName': value['licenceFirstName'],
|
|
127
127
|
'licenceLastName': value['licenceLastName'],
|
|
128
128
|
'badgeNumber': value['badgeNumber'],
|
|
129
|
-
'createdAt': value['createdAt'] === null ? null : ((
|
|
130
|
-
'updatedAt': value['updatedAt'] === null ? null : ((
|
|
129
|
+
'createdAt': value['createdAt'] === null ? null : ((_a = value['createdAt']) === null || _a === void 0 ? void 0 : _a.toISOString()),
|
|
130
|
+
'updatedAt': value['updatedAt'] === null ? null : ((_b = value['updatedAt']) === null || _b === void 0 ? void 0 : _b.toISOString()),
|
|
131
131
|
};
|
|
132
132
|
}
|
|
@@ -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
|
}
|
|
@@ -33,8 +33,6 @@ function instanceOfRosterWithRegistersResource(value) {
|
|
|
33
33
|
return false;
|
|
34
34
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined)
|
|
35
35
|
return false;
|
|
36
|
-
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined)
|
|
37
|
-
return false;
|
|
38
36
|
if (!('isCompliant' in value) || value['isCompliant'] === undefined)
|
|
39
37
|
return false;
|
|
40
38
|
if (!('isComplete' in value) || value['isComplete'] === undefined)
|
|
@@ -58,7 +56,7 @@ function RosterWithRegistersResourceFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
58
56
|
'state': json['state'],
|
|
59
57
|
'securityCompany': (0, SecurityCompanyLiteResource_1.SecurityCompanyLiteResourceFromJSON)(json['securityCompany']),
|
|
60
58
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
61
|
-
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
59
|
+
'finishDateTime': json['finishDateTime'] == null ? undefined : (new Date(json['finishDateTime'])),
|
|
62
60
|
'isCompliant': json['isCompliant'],
|
|
63
61
|
'isComplete': json['isComplete'],
|
|
64
62
|
'signOffStatus': json['signOffStatus'],
|
|
@@ -69,6 +67,7 @@ function RosterWithRegistersResourceToJSON(json) {
|
|
|
69
67
|
return RosterWithRegistersResourceToJSONTyped(json, false);
|
|
70
68
|
}
|
|
71
69
|
function RosterWithRegistersResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
70
|
+
var _a;
|
|
72
71
|
if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
|
|
73
72
|
if (value == null) {
|
|
74
73
|
return value;
|
|
@@ -79,7 +78,7 @@ function RosterWithRegistersResourceToJSONTyped(value, ignoreDiscriminator) {
|
|
|
79
78
|
'state': value['state'],
|
|
80
79
|
'securityCompany': (0, SecurityCompanyLiteResource_1.SecurityCompanyLiteResourceToJSON)(value['securityCompany']),
|
|
81
80
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
82
|
-
'finishDateTime': ((value['finishDateTime']).toISOString()),
|
|
81
|
+
'finishDateTime': value['finishDateTime'] === null ? null : ((_a = value['finishDateTime']) === null || _a === void 0 ? void 0 : _a.toISOString()),
|
|
83
82
|
'isCompliant': value['isCompliant'],
|
|
84
83
|
'isComplete': value['isComplete'],
|
|
85
84
|
'signOffStatus': value['signOffStatus'],
|
|
@@ -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 AddressResource {
|
|
|
36
36
|
* @type {string}
|
|
37
37
|
* @memberof AddressResource
|
|
38
38
|
*/
|
|
39
|
-
addressLine2
|
|
39
|
+
addressLine2?: string | null;
|
|
40
40
|
/**
|
|
41
41
|
*
|
|
42
42
|
* @type {string}
|
|
@@ -80,7 +80,6 @@ export interface AddressResource {
|
|
|
80
80
|
*/
|
|
81
81
|
export function instanceOfAddressResource(value: object): value is AddressResource {
|
|
82
82
|
if (!('addressLine1' in value) || value['addressLine1'] === undefined) return false;
|
|
83
|
-
if (!('addressLine2' in value) || value['addressLine2'] === undefined) return false;
|
|
84
83
|
if (!('suburb' in value) || value['suburb'] === undefined) return false;
|
|
85
84
|
if (!('city' in value) || value['city'] === undefined) return false;
|
|
86
85
|
if (!('state' in value) || value['state'] === undefined) return false;
|
|
@@ -102,7 +101,7 @@ export function AddressResourceFromJSONTyped(json: any, ignoreDiscriminator: boo
|
|
|
102
101
|
|
|
103
102
|
'id': json['id'] == null ? undefined : json['id'],
|
|
104
103
|
'addressLine1': json['addressLine1'],
|
|
105
|
-
'addressLine2': json['addressLine2'],
|
|
104
|
+
'addressLine2': json['addressLine2'] == null ? undefined : json['addressLine2'],
|
|
106
105
|
'suburb': json['suburb'],
|
|
107
106
|
'city': json['city'],
|
|
108
107
|
'state': json['state'],
|
|
@@ -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
|
}
|
|
@@ -70,13 +70,13 @@ export interface RegisterListResource {
|
|
|
70
70
|
* @type {Date}
|
|
71
71
|
* @memberof RegisterListResource
|
|
72
72
|
*/
|
|
73
|
-
finishDateTime
|
|
73
|
+
finishDateTime?: Date | null;
|
|
74
74
|
/**
|
|
75
75
|
*
|
|
76
|
-
* @type {
|
|
76
|
+
* @type {object}
|
|
77
77
|
* @memberof RegisterListResource
|
|
78
78
|
*/
|
|
79
|
-
shiftLength:
|
|
79
|
+
shiftLength: object;
|
|
80
80
|
/**
|
|
81
81
|
*
|
|
82
82
|
* @type {number}
|
|
@@ -166,13 +166,13 @@ export interface RegisterListResource {
|
|
|
166
166
|
* @type {number}
|
|
167
167
|
* @memberof RegisterListResource
|
|
168
168
|
*/
|
|
169
|
-
signOffLat
|
|
169
|
+
signOffLat: number;
|
|
170
170
|
/**
|
|
171
171
|
*
|
|
172
172
|
* @type {number}
|
|
173
173
|
* @memberof RegisterListResource
|
|
174
174
|
*/
|
|
175
|
-
signOffLong
|
|
175
|
+
signOffLong: number;
|
|
176
176
|
/**
|
|
177
177
|
*
|
|
178
178
|
* @type {Array<IncidentLiteResource>}
|
|
@@ -188,7 +188,6 @@ export function instanceOfRegisterListResource(value: object): value is Register
|
|
|
188
188
|
if (!('user' in value) || value['user'] === undefined) return false;
|
|
189
189
|
if (!('venue' in value) || value['venue'] === undefined) return false;
|
|
190
190
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined) return false;
|
|
191
|
-
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined) return false;
|
|
192
191
|
if (!('shiftLength' in value) || value['shiftLength'] === undefined) return false;
|
|
193
192
|
if (!('signOffStatus' in value) || value['signOffStatus'] === undefined) return false;
|
|
194
193
|
if (!('licenceNumber' in value) || value['licenceNumber'] === undefined) return false;
|
|
@@ -203,6 +202,8 @@ 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;
|
|
205
|
+
if (!('signOffLat' in value) || value['signOffLat'] === undefined) return false;
|
|
206
|
+
if (!('signOffLong' in value) || value['signOffLong'] === undefined) return false;
|
|
206
207
|
if (!('incidents' in value) || value['incidents'] === undefined) return false;
|
|
207
208
|
return true;
|
|
208
209
|
}
|
|
@@ -221,7 +222,7 @@ export function RegisterListResourceFromJSONTyped(json: any, ignoreDiscriminator
|
|
|
221
222
|
'user': UserLiteResourceFromJSON(json['user']),
|
|
222
223
|
'venue': VenueLiteResourceFromJSON(json['venue']),
|
|
223
224
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
224
|
-
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
225
|
+
'finishDateTime': json['finishDateTime'] == null ? undefined : (new Date(json['finishDateTime'])),
|
|
225
226
|
'shiftLength': json['shiftLength'],
|
|
226
227
|
'signOffStatus': json['signOffStatus'],
|
|
227
228
|
'badgeNumber': json['badgeNumber'] == null ? undefined : json['badgeNumber'],
|
|
@@ -237,8 +238,8 @@ export function RegisterListResourceFromJSONTyped(json: any, ignoreDiscriminator
|
|
|
237
238
|
'firstAid': json['firstAid'],
|
|
238
239
|
'signOnLat': json['signOnLat'],
|
|
239
240
|
'signOnLong': json['signOnLong'],
|
|
240
|
-
'signOffLat': json['signOffLat']
|
|
241
|
-
'signOffLong': json['signOffLong']
|
|
241
|
+
'signOffLat': json['signOffLat'],
|
|
242
|
+
'signOffLong': json['signOffLong'],
|
|
242
243
|
'incidents': (json['incidents'] == null ? null : (json['incidents'] as Array<any>).map(IncidentLiteResourceFromJSON)),
|
|
243
244
|
};
|
|
244
245
|
}
|
|
@@ -258,7 +259,7 @@ export function RegisterListResourceToJSONTyped(value?: RegisterListResource | n
|
|
|
258
259
|
'user': UserLiteResourceToJSON(value['user']),
|
|
259
260
|
'venue': VenueLiteResourceToJSON(value['venue']),
|
|
260
261
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
261
|
-
'finishDateTime': ((value['finishDateTime'])
|
|
262
|
+
'finishDateTime': value['finishDateTime'] === null ? null : ((value['finishDateTime'] as any)?.toISOString()),
|
|
262
263
|
'shiftLength': value['shiftLength'],
|
|
263
264
|
'signOffStatus': value['signOffStatus'],
|
|
264
265
|
'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,7 +123,7 @@ 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}
|
|
@@ -181,6 +181,7 @@ export function instanceOfRegisterResource(value: object): value is RegisterReso
|
|
|
181
181
|
if (!('venue' in value) || value['venue'] === undefined) return false;
|
|
182
182
|
if (!('user' in value) || value['user'] === undefined) return false;
|
|
183
183
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined) return false;
|
|
184
|
+
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined) return false;
|
|
184
185
|
if (!('signOffStatus' in value) || value['signOffStatus'] === undefined) return false;
|
|
185
186
|
if (!('signOnSignature' in value) || value['signOnSignature'] === undefined) return false;
|
|
186
187
|
if (!('signOffSignature' in value) || value['signOffSignature'] === undefined) return false;
|
|
@@ -190,7 +191,6 @@ export function instanceOfRegisterResource(value: object): value is RegisterReso
|
|
|
190
191
|
if (!('firstAidImage' in value) || value['firstAidImage'] === undefined) return false;
|
|
191
192
|
if (!('signOnLat' in value) || value['signOnLat'] === undefined) return false;
|
|
192
193
|
if (!('signOnLong' in value) || value['signOnLong'] === undefined) return false;
|
|
193
|
-
if (!('signOffLat' in value) || value['signOffLat'] === undefined) return false;
|
|
194
194
|
if (!('signOffLong' in value) || value['signOffLong'] === undefined) return false;
|
|
195
195
|
if (!('licenceNumber' in value) || value['licenceNumber'] === undefined) return false;
|
|
196
196
|
if (!('licenceExpiry' in value) || value['licenceExpiry'] === undefined) return false;
|
|
@@ -213,7 +213,7 @@ export function RegisterResourceFromJSONTyped(json: any, ignoreDiscriminator: bo
|
|
|
213
213
|
'venue': VenueLiteResourceFromJSON(json['venue']),
|
|
214
214
|
'user': UserLiteResourceFromJSON(json['user']),
|
|
215
215
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
216
|
-
'finishDateTime':
|
|
216
|
+
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
217
217
|
'signOffStatus': json['signOffStatus'],
|
|
218
218
|
'signOnSignature': json['signOnSignature'],
|
|
219
219
|
'signOffSignature': json['signOffSignature'],
|
|
@@ -223,7 +223,7 @@ export function RegisterResourceFromJSONTyped(json: any, ignoreDiscriminator: bo
|
|
|
223
223
|
'firstAidImage': json['firstAidImage'],
|
|
224
224
|
'signOnLat': json['signOnLat'],
|
|
225
225
|
'signOnLong': json['signOnLong'],
|
|
226
|
-
'signOffLat': json['signOffLat'],
|
|
226
|
+
'signOffLat': json['signOffLat'] == null ? undefined : json['signOffLat'],
|
|
227
227
|
'signOffLong': json['signOffLong'],
|
|
228
228
|
'licenceNumber': json['licenceNumber'],
|
|
229
229
|
'licenceExpiry': json['licenceExpiry'],
|
|
@@ -250,7 +250,7 @@ export function RegisterResourceToJSONTyped(value?: RegisterResource | null, ign
|
|
|
250
250
|
'venue': VenueLiteResourceToJSON(value['venue']),
|
|
251
251
|
'user': UserLiteResourceToJSON(value['user']),
|
|
252
252
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
253
|
-
'finishDateTime':
|
|
253
|
+
'finishDateTime': ((value['finishDateTime']).toISOString()),
|
|
254
254
|
'signOffStatus': value['signOffStatus'],
|
|
255
255
|
'signOnSignature': value['signOnSignature'],
|
|
256
256
|
'signOffSignature': value['signOffSignature'],
|
|
@@ -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
|
|
|
@@ -76,7 +76,7 @@ export interface RosterWithRegistersResource {
|
|
|
76
76
|
* @type {Date}
|
|
77
77
|
* @memberof RosterWithRegistersResource
|
|
78
78
|
*/
|
|
79
|
-
finishDateTime
|
|
79
|
+
finishDateTime?: Date | null;
|
|
80
80
|
/**
|
|
81
81
|
*
|
|
82
82
|
* @type {boolean}
|
|
@@ -111,7 +111,6 @@ export function instanceOfRosterWithRegistersResource(value: object): value is R
|
|
|
111
111
|
if (!('state' in value) || value['state'] === undefined) return false;
|
|
112
112
|
if (!('securityCompany' in value) || value['securityCompany'] === undefined) return false;
|
|
113
113
|
if (!('startDateTime' in value) || value['startDateTime'] === undefined) return false;
|
|
114
|
-
if (!('finishDateTime' in value) || value['finishDateTime'] === undefined) return false;
|
|
115
114
|
if (!('isCompliant' in value) || value['isCompliant'] === undefined) return false;
|
|
116
115
|
if (!('isComplete' in value) || value['isComplete'] === undefined) return false;
|
|
117
116
|
if (!('signOffStatus' in value) || value['signOffStatus'] === undefined) return false;
|
|
@@ -134,7 +133,7 @@ export function RosterWithRegistersResourceFromJSONTyped(json: any, ignoreDiscri
|
|
|
134
133
|
'state': json['state'],
|
|
135
134
|
'securityCompany': SecurityCompanyLiteResourceFromJSON(json['securityCompany']),
|
|
136
135
|
'startDateTime': (new Date(json['startDateTime'])),
|
|
137
|
-
'finishDateTime': (new Date(json['finishDateTime'])),
|
|
136
|
+
'finishDateTime': json['finishDateTime'] == null ? undefined : (new Date(json['finishDateTime'])),
|
|
138
137
|
'isCompliant': json['isCompliant'],
|
|
139
138
|
'isComplete': json['isComplete'],
|
|
140
139
|
'signOffStatus': json['signOffStatus'],
|
|
@@ -158,7 +157,7 @@ export function RosterWithRegistersResourceToJSONTyped(value?: RosterWithRegiste
|
|
|
158
157
|
'state': value['state'],
|
|
159
158
|
'securityCompany': SecurityCompanyLiteResourceToJSON(value['securityCompany']),
|
|
160
159
|
'startDateTime': ((value['startDateTime']).toISOString()),
|
|
161
|
-
'finishDateTime': ((value['finishDateTime'])
|
|
160
|
+
'finishDateTime': value['finishDateTime'] === null ? null : ((value['finishDateTime'] as any)?.toISOString()),
|
|
162
161
|
'isCompliant': value['isCompliant'],
|
|
163
162
|
'isComplete': value['isComplete'],
|
|
164
163
|
'signOffStatus': value['signOffStatus'],
|
|
@@ -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'],
|