@digital8/security-registers-backend-ts-sdk 0.0.514 → 0.0.515

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.
@@ -25,6 +25,8 @@ src/models/BackAsset.ts
25
25
  src/models/CurrentRegisterResource.ts
26
26
  src/models/CurrentRegisterResourceArrayResponse.ts
27
27
  src/models/DevicesRegisterRequest.ts
28
+ src/models/EligibleIncidentOwnerResource.ts
29
+ src/models/EligibleIncidentOwnerResourceArrayResponse.ts
28
30
  src/models/ExportQueuedResource.ts
29
31
  src/models/ExportQueuedResourceArrayResponse.ts
30
32
  src/models/FirstAidAsset.ts
@@ -56,6 +58,7 @@ src/models/IncidentVideoSignedUrlResourceArrayResponse.ts
56
58
  src/models/IncidentVideoUploadTokenResource.ts
57
59
  src/models/IncidentVideoUploadTokenResourceArrayResponse.ts
58
60
  src/models/IncidentsApproveRequest.ts
61
+ src/models/IncidentsEligibleOwnersRequest.ts
59
62
  src/models/IncidentsExportCsvBulkRequest.ts
60
63
  src/models/IncidentsExportPdfBulkRequest.ts
61
64
  src/models/IncidentsExportPdfRequest.ts
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- ## @digital8/security-registers-backend-ts-sdk@0.0.514
1
+ ## @digital8/security-registers-backend-ts-sdk@0.0.515
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.514 --save
39
+ npm install @digital8/security-registers-backend-ts-sdk@0.0.515 --save
40
40
  ```
41
41
 
42
42
  _unPublished (not recommended):_
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { AssetFileForUploadResource, AuthChangePasswordRequest, AuthLoginWebRequest, AuthProfileUpdateRequest, AuthRegisterGuardFileRequest, AuthRegisterGuardRequest, DevicesRegisterRequest, ExportQueuedResource, GenericResponse, IncidentFieldSchemaResource, IncidentFieldSchemasShowRequest, IncidentResource, IncidentVersionResource, IncidentVersionResourceArrayResponse, IncidentVideoResource, IncidentVideoResourceArrayResponse, IncidentVideoSignedUrlResource, IncidentVideoUploadTokenResource, IncidentsApproveRequest, IncidentsExportCsvBulkRequest, IncidentsExportPdfBulkRequest, IncidentsExportPdfRequest, IncidentsListRequest, IncidentsStoreRequest, IncidentsUpdateRequest, IncidentsVideosStoreRequest, IncidentsVideosUploadTokenRequest, IndexMinimalUserRequest, IndexUserRequest, LicenceLiteResourceArrayResponse, LicenceResource, LicenceVerificationFallbackSettingResourceArrayResponse, LicencesCheckLogsListRequest, LicencesListAllRequest, LicencesListRequest, LicencesStoreRequest, LicencesUpdateRequest, LicencesVerifyRequest, MobileAppConfigRequest, MobileAppConfigResource, MobileDeviceResource, MobileInitResource, NotificationPreferenceResource, NotificationPreferenceResourceArrayResponse, NotificationPreferencesBulkRequest, NotificationPreferencesStoreRequest, NotificationTypeResourceArrayResponse, PaginatedIncidentListResourceResponse, PaginatedLicenceCheckLogResourceResponse, PaginatedLicenceListResourceResponse, PaginatedRegisterGroupedByRosterResourceResponse, PaginatedRosterListResourceResponse, PaginatedRosterWithRegistersResourceResponse, PaginatedSecurityCompanyResourceResponse, PaginatedUserResourceResponse, PaginatedVenueResourceResponse, PdfExportResource, RegisterLiteResourceArrayResponse, RegisterResource, RegistersCreateRequest, RegistersListAllRequest, RegistersListRequest, RegistersSignOffRequest, RegistersSignOnRequest, RegistersUpdateRequest, ResetPasswordAuthRequest, RosterLiteResourceArrayResponse, RosterResource, RostersExportPdfRequest, RostersListAllRequest, RostersListRequest, RostersListWithRegistersRequest, RostersUpdateRequest, SecurityCompaniesAttachUsersRequest, SecurityCompaniesListAllRequest, SecurityCompaniesListRequest, SecurityCompaniesStoreRequest, SecurityCompaniesUpdateRequest, SecurityCompanyLiteResourceArrayResponse, SecurityCompanyResource, SendForgotPasswordLinkAuthRequest, SettingsLicenceVerificationFallbackUpdateRequest, StoreAssetFileRequest, StoreUserRequest, UpdateUserRequest, UserAuthTokenResource, UserLiteResourceArrayResponse, UserResource, UserVenueResourceArrayResponse, UsersAttachSecurityCompaniesRequest, UsersAttachVenuesRequest, UsersCreateWithRoleRequest, UsersDetachVenuesRequest, UsersRegisterVenueManagerRequest, VenueGuardScheduleResourceArrayResponse, VenueLiteResourceArrayResponse, VenueResource, VenuesAttachUsersRequest, VenuesGuardScheduleUpdateRequest, VenuesListAllRequest, VenuesListForUserRequest, VenuesListRequest, VenuesNearbyRequest, VenuesPublicStoreRequest, VenuesUpdateRequest, VerifyLicenceResource } from '../models/index';
13
+ import type { AssetFileForUploadResource, AuthChangePasswordRequest, AuthLoginWebRequest, AuthProfileUpdateRequest, AuthRegisterGuardFileRequest, AuthRegisterGuardRequest, DevicesRegisterRequest, EligibleIncidentOwnerResourceArrayResponse, ExportQueuedResource, GenericResponse, IncidentFieldSchemaResource, IncidentFieldSchemasShowRequest, IncidentResource, IncidentVersionResource, IncidentVersionResourceArrayResponse, IncidentVideoResource, IncidentVideoResourceArrayResponse, IncidentVideoSignedUrlResource, IncidentVideoUploadTokenResource, IncidentsApproveRequest, IncidentsEligibleOwnersRequest, IncidentsExportCsvBulkRequest, IncidentsExportPdfBulkRequest, IncidentsExportPdfRequest, IncidentsListRequest, IncidentsStoreRequest, IncidentsUpdateRequest, IncidentsVideosStoreRequest, IncidentsVideosUploadTokenRequest, IndexMinimalUserRequest, IndexUserRequest, LicenceLiteResourceArrayResponse, LicenceResource, LicenceVerificationFallbackSettingResourceArrayResponse, LicencesCheckLogsListRequest, LicencesListAllRequest, LicencesListRequest, LicencesStoreRequest, LicencesUpdateRequest, LicencesVerifyRequest, MobileAppConfigRequest, MobileAppConfigResource, MobileDeviceResource, MobileInitResource, NotificationPreferenceResource, NotificationPreferenceResourceArrayResponse, NotificationPreferencesBulkRequest, NotificationPreferencesStoreRequest, NotificationTypeResourceArrayResponse, PaginatedIncidentListResourceResponse, PaginatedLicenceCheckLogResourceResponse, PaginatedLicenceListResourceResponse, PaginatedRegisterGroupedByRosterResourceResponse, PaginatedRosterListResourceResponse, PaginatedRosterWithRegistersResourceResponse, PaginatedSecurityCompanyResourceResponse, PaginatedUserResourceResponse, PaginatedVenueResourceResponse, PdfExportResource, RegisterLiteResourceArrayResponse, RegisterResource, RegistersCreateRequest, RegistersListAllRequest, RegistersListRequest, RegistersSignOffRequest, RegistersSignOnRequest, RegistersUpdateRequest, ResetPasswordAuthRequest, RosterLiteResourceArrayResponse, RosterResource, RostersExportPdfRequest, RostersListAllRequest, RostersListRequest, RostersListWithRegistersRequest, RostersUpdateRequest, SecurityCompaniesAttachUsersRequest, SecurityCompaniesListAllRequest, SecurityCompaniesListRequest, SecurityCompaniesStoreRequest, SecurityCompaniesUpdateRequest, SecurityCompanyLiteResourceArrayResponse, SecurityCompanyResource, SendForgotPasswordLinkAuthRequest, SettingsLicenceVerificationFallbackUpdateRequest, StoreAssetFileRequest, StoreUserRequest, UpdateUserRequest, UserAuthTokenResource, UserLiteResourceArrayResponse, UserResource, UserVenueResourceArrayResponse, UsersAttachSecurityCompaniesRequest, UsersAttachVenuesRequest, UsersCreateWithRoleRequest, UsersDetachVenuesRequest, UsersRegisterVenueManagerRequest, VenueGuardScheduleResourceArrayResponse, VenueLiteResourceArrayResponse, VenueResource, VenuesAttachUsersRequest, VenuesGuardScheduleUpdateRequest, VenuesListAllRequest, VenuesListForUserRequest, VenuesListRequest, VenuesNearbyRequest, VenuesPublicStoreRequest, VenuesUpdateRequest, VerifyLicenceResource } from '../models/index';
14
14
  export interface AuthChangePasswordOperationRequest {
15
15
  authChangePasswordRequest?: AuthChangePasswordRequest;
16
16
  }
@@ -48,6 +48,9 @@ export interface IncidentsApproveOperationRequest {
48
48
  export interface IncidentsDestroyRequest {
49
49
  incident: number;
50
50
  }
51
+ export interface IncidentsEligibleOwnersOperationRequest {
52
+ incidentsEligibleOwnersRequest?: IncidentsEligibleOwnersRequest;
53
+ }
51
54
  export interface IncidentsExportCsvRequest {
52
55
  incident: number;
53
56
  incidentsExportPdfRequest?: IncidentsExportPdfRequest;
@@ -452,6 +455,14 @@ export declare class GeneralApi extends runtime.BaseAPI {
452
455
  * Auto-generated: incidents.destroy
453
456
  */
454
457
  incidentsDestroy(requestParameters: IncidentsDestroyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GenericResponse>;
458
+ /**
459
+ * Auto-generated: incidents.eligibleOwners
460
+ */
461
+ incidentsEligibleOwnersRaw(requestParameters: IncidentsEligibleOwnersOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<EligibleIncidentOwnerResourceArrayResponse>>;
462
+ /**
463
+ * Auto-generated: incidents.eligibleOwners
464
+ */
465
+ incidentsEligibleOwners(requestParameters?: IncidentsEligibleOwnersOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<EligibleIncidentOwnerResourceArrayResponse>;
455
466
  /**
456
467
  * Auto-generated: incidents.exportCsv
457
468
  */
@@ -793,6 +793,61 @@ var GeneralApi = /** @class */ (function (_super) {
793
793
  });
794
794
  });
795
795
  };
796
+ /**
797
+ * Auto-generated: incidents.eligibleOwners
798
+ */
799
+ GeneralApi.prototype.incidentsEligibleOwnersRaw = function (requestParameters, initOverrides) {
800
+ return __awaiter(this, void 0, void 0, function () {
801
+ var queryParameters, headerParameters, token, tokenString, urlPath, response;
802
+ return __generator(this, function (_a) {
803
+ switch (_a.label) {
804
+ case 0:
805
+ queryParameters = {};
806
+ headerParameters = {};
807
+ headerParameters['Content-Type'] = 'application/json';
808
+ if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
809
+ token = this.configuration.accessToken;
810
+ return [4 /*yield*/, token("bearerAuth", [])];
811
+ case 1:
812
+ tokenString = _a.sent();
813
+ if (tokenString) {
814
+ headerParameters["Authorization"] = "Bearer ".concat(tokenString);
815
+ }
816
+ _a.label = 2;
817
+ case 2:
818
+ urlPath = "/api/incidents/eligible-owners";
819
+ return [4 /*yield*/, this.request({
820
+ path: urlPath,
821
+ method: 'POST',
822
+ headers: headerParameters,
823
+ query: queryParameters,
824
+ body: (0, index_1.IncidentsEligibleOwnersRequestToJSON)(requestParameters['incidentsEligibleOwnersRequest']),
825
+ }, initOverrides)];
826
+ case 3:
827
+ response = _a.sent();
828
+ return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, index_1.EligibleIncidentOwnerResourceArrayResponseFromJSON)(jsonValue); })];
829
+ }
830
+ });
831
+ });
832
+ };
833
+ /**
834
+ * Auto-generated: incidents.eligibleOwners
835
+ */
836
+ GeneralApi.prototype.incidentsEligibleOwners = function () {
837
+ return __awaiter(this, arguments, void 0, function (requestParameters, initOverrides) {
838
+ var response;
839
+ if (requestParameters === void 0) { requestParameters = {}; }
840
+ return __generator(this, function (_a) {
841
+ switch (_a.label) {
842
+ case 0: return [4 /*yield*/, this.incidentsEligibleOwnersRaw(requestParameters, initOverrides)];
843
+ case 1:
844
+ response = _a.sent();
845
+ return [4 /*yield*/, response.value()];
846
+ case 2: return [2 /*return*/, _a.sent()];
847
+ }
848
+ });
849
+ });
850
+ };
796
851
  /**
797
852
  * Auto-generated: incidents.exportCsv
798
853
  */
@@ -32,7 +32,7 @@ export interface AddressResource {
32
32
  * @type {string}
33
33
  * @memberof AddressResource
34
34
  */
35
- addressLine2: string;
35
+ addressLine2?: string | null;
36
36
  /**
37
37
  *
38
38
  * @type {string}
@@ -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'],
@@ -44,7 +44,7 @@ export interface AssetResource {
44
44
  * @type {string}
45
45
  * @memberof AssetResource
46
46
  */
47
- altText?: string | null;
47
+ altText: string;
48
48
  /**
49
49
  *
50
50
  * @type {number}
@@ -30,6 +30,8 @@ function instanceOfAssetResource(value) {
30
30
  return false;
31
31
  if (!('mimeType' in value) || value['mimeType'] === undefined)
32
32
  return false;
33
+ if (!('altText' in value) || value['altText'] === undefined)
34
+ return false;
33
35
  if (!('index' in value) || value['index'] === undefined)
34
36
  return false;
35
37
  if (!('fileId' in value) || value['fileId'] === undefined)
@@ -50,7 +52,7 @@ function AssetResourceFromJSONTyped(json, ignoreDiscriminator) {
50
52
  'filePath': json['filePath'],
51
53
  'fileName': json['fileName'],
52
54
  'mimeType': json['mimeType'],
53
- 'altText': json['altText'] == null ? undefined : json['altText'],
55
+ 'altText': json['altText'],
54
56
  'index': json['index'],
55
57
  'fileId': json['fileId'],
56
58
  'isExternal': json['isExternal'],
@@ -0,0 +1,62 @@
1
+ /**
2
+ * My API
3
+ * API documentation for my Laravel app
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface EligibleIncidentOwnerResource
16
+ */
17
+ export interface EligibleIncidentOwnerResource {
18
+ /**
19
+ *
20
+ * @type {number}
21
+ * @memberof EligibleIncidentOwnerResource
22
+ */
23
+ id: number;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof EligibleIncidentOwnerResource
28
+ */
29
+ firstName: string;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof EligibleIncidentOwnerResource
34
+ */
35
+ lastName: string;
36
+ /**
37
+ *
38
+ * @type {string}
39
+ * @memberof EligibleIncidentOwnerResource
40
+ */
41
+ fullName: string;
42
+ /**
43
+ *
44
+ * @type {string}
45
+ * @memberof EligibleIncidentOwnerResource
46
+ */
47
+ role: string;
48
+ /**
49
+ *
50
+ * @type {boolean}
51
+ * @memberof EligibleIncidentOwnerResource
52
+ */
53
+ activeRegisterAtIncidentDatetime: boolean;
54
+ }
55
+ /**
56
+ * Check if a given object implements the EligibleIncidentOwnerResource interface.
57
+ */
58
+ export declare function instanceOfEligibleIncidentOwnerResource(value: object): value is EligibleIncidentOwnerResource;
59
+ export declare function EligibleIncidentOwnerResourceFromJSON(json: any): EligibleIncidentOwnerResource;
60
+ export declare function EligibleIncidentOwnerResourceFromJSONTyped(json: any, ignoreDiscriminator: boolean): EligibleIncidentOwnerResource;
61
+ export declare function EligibleIncidentOwnerResourceToJSON(json: any): EligibleIncidentOwnerResource;
62
+ export declare function EligibleIncidentOwnerResourceToJSONTyped(value?: EligibleIncidentOwnerResource | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,71 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * My API
6
+ * API documentation for my Laravel app
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfEligibleIncidentOwnerResource = instanceOfEligibleIncidentOwnerResource;
17
+ exports.EligibleIncidentOwnerResourceFromJSON = EligibleIncidentOwnerResourceFromJSON;
18
+ exports.EligibleIncidentOwnerResourceFromJSONTyped = EligibleIncidentOwnerResourceFromJSONTyped;
19
+ exports.EligibleIncidentOwnerResourceToJSON = EligibleIncidentOwnerResourceToJSON;
20
+ exports.EligibleIncidentOwnerResourceToJSONTyped = EligibleIncidentOwnerResourceToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the EligibleIncidentOwnerResource interface.
23
+ */
24
+ function instanceOfEligibleIncidentOwnerResource(value) {
25
+ if (!('id' in value) || value['id'] === undefined)
26
+ return false;
27
+ if (!('firstName' in value) || value['firstName'] === undefined)
28
+ return false;
29
+ if (!('lastName' in value) || value['lastName'] === undefined)
30
+ return false;
31
+ if (!('fullName' in value) || value['fullName'] === undefined)
32
+ return false;
33
+ if (!('role' in value) || value['role'] === undefined)
34
+ return false;
35
+ if (!('activeRegisterAtIncidentDatetime' in value) || value['activeRegisterAtIncidentDatetime'] === undefined)
36
+ return false;
37
+ return true;
38
+ }
39
+ function EligibleIncidentOwnerResourceFromJSON(json) {
40
+ return EligibleIncidentOwnerResourceFromJSONTyped(json, false);
41
+ }
42
+ function EligibleIncidentOwnerResourceFromJSONTyped(json, ignoreDiscriminator) {
43
+ if (json == null) {
44
+ return json;
45
+ }
46
+ return {
47
+ 'id': json['id'],
48
+ 'firstName': json['firstName'],
49
+ 'lastName': json['lastName'],
50
+ 'fullName': json['fullName'],
51
+ 'role': json['role'],
52
+ 'activeRegisterAtIncidentDatetime': json['activeRegisterAtIncidentDatetime'],
53
+ };
54
+ }
55
+ function EligibleIncidentOwnerResourceToJSON(json) {
56
+ return EligibleIncidentOwnerResourceToJSONTyped(json, false);
57
+ }
58
+ function EligibleIncidentOwnerResourceToJSONTyped(value, ignoreDiscriminator) {
59
+ if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
60
+ if (value == null) {
61
+ return value;
62
+ }
63
+ return {
64
+ 'id': value['id'],
65
+ 'firstName': value['firstName'],
66
+ 'lastName': value['lastName'],
67
+ 'fullName': value['fullName'],
68
+ 'role': value['role'],
69
+ 'activeRegisterAtIncidentDatetime': value['activeRegisterAtIncidentDatetime'],
70
+ };
71
+ }
@@ -0,0 +1,33 @@
1
+ /**
2
+ * My API
3
+ * API documentation for my Laravel app
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { EligibleIncidentOwnerResource } from './EligibleIncidentOwnerResource';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface EligibleIncidentOwnerResourceArrayResponse
17
+ */
18
+ export interface EligibleIncidentOwnerResourceArrayResponse {
19
+ /**
20
+ *
21
+ * @type {Array<EligibleIncidentOwnerResource>}
22
+ * @memberof EligibleIncidentOwnerResourceArrayResponse
23
+ */
24
+ data?: Array<EligibleIncidentOwnerResource>;
25
+ }
26
+ /**
27
+ * Check if a given object implements the EligibleIncidentOwnerResourceArrayResponse interface.
28
+ */
29
+ export declare function instanceOfEligibleIncidentOwnerResourceArrayResponse(value: object): value is EligibleIncidentOwnerResourceArrayResponse;
30
+ export declare function EligibleIncidentOwnerResourceArrayResponseFromJSON(json: any): EligibleIncidentOwnerResourceArrayResponse;
31
+ export declare function EligibleIncidentOwnerResourceArrayResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): EligibleIncidentOwnerResourceArrayResponse;
32
+ export declare function EligibleIncidentOwnerResourceArrayResponseToJSON(json: any): EligibleIncidentOwnerResourceArrayResponse;
33
+ export declare function EligibleIncidentOwnerResourceArrayResponseToJSONTyped(value?: EligibleIncidentOwnerResourceArrayResponse | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,50 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * My API
6
+ * API documentation for my Laravel app
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfEligibleIncidentOwnerResourceArrayResponse = instanceOfEligibleIncidentOwnerResourceArrayResponse;
17
+ exports.EligibleIncidentOwnerResourceArrayResponseFromJSON = EligibleIncidentOwnerResourceArrayResponseFromJSON;
18
+ exports.EligibleIncidentOwnerResourceArrayResponseFromJSONTyped = EligibleIncidentOwnerResourceArrayResponseFromJSONTyped;
19
+ exports.EligibleIncidentOwnerResourceArrayResponseToJSON = EligibleIncidentOwnerResourceArrayResponseToJSON;
20
+ exports.EligibleIncidentOwnerResourceArrayResponseToJSONTyped = EligibleIncidentOwnerResourceArrayResponseToJSONTyped;
21
+ var EligibleIncidentOwnerResource_1 = require("./EligibleIncidentOwnerResource");
22
+ /**
23
+ * Check if a given object implements the EligibleIncidentOwnerResourceArrayResponse interface.
24
+ */
25
+ function instanceOfEligibleIncidentOwnerResourceArrayResponse(value) {
26
+ return true;
27
+ }
28
+ function EligibleIncidentOwnerResourceArrayResponseFromJSON(json) {
29
+ return EligibleIncidentOwnerResourceArrayResponseFromJSONTyped(json, false);
30
+ }
31
+ function EligibleIncidentOwnerResourceArrayResponseFromJSONTyped(json, ignoreDiscriminator) {
32
+ if (json == null) {
33
+ return json;
34
+ }
35
+ return {
36
+ 'data': json['data'] == null ? undefined : (json['data'].map(EligibleIncidentOwnerResource_1.EligibleIncidentOwnerResourceFromJSON)),
37
+ };
38
+ }
39
+ function EligibleIncidentOwnerResourceArrayResponseToJSON(json) {
40
+ return EligibleIncidentOwnerResourceArrayResponseToJSONTyped(json, false);
41
+ }
42
+ function EligibleIncidentOwnerResourceArrayResponseToJSONTyped(value, ignoreDiscriminator) {
43
+ if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
44
+ if (value == null) {
45
+ return value;
46
+ }
47
+ return {
48
+ 'data': value['data'] == null ? undefined : (value['data'].map(EligibleIncidentOwnerResource_1.EligibleIncidentOwnerResourceToJSON)),
49
+ };
50
+ }
@@ -0,0 +1,38 @@
1
+ /**
2
+ * My API
3
+ * API documentation for my Laravel app
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface IncidentsEligibleOwnersRequest
16
+ */
17
+ export interface IncidentsEligibleOwnersRequest {
18
+ /**
19
+ *
20
+ * @type {number}
21
+ * @memberof IncidentsEligibleOwnersRequest
22
+ */
23
+ venueId: number;
24
+ /**
25
+ * Optional incident start datetime (ISO-8601, in the venue's timezone). Used to decide guard eligibility ("signed on at this venue OR not signed on at any other venue at that time") and to flag the `activeRegisterAtIncidentDatetime` field on each result. Omit to fall back to the current server time.
26
+ * @type {Date}
27
+ * @memberof IncidentsEligibleOwnersRequest
28
+ */
29
+ incidentDatetime?: Date;
30
+ }
31
+ /**
32
+ * Check if a given object implements the IncidentsEligibleOwnersRequest interface.
33
+ */
34
+ export declare function instanceOfIncidentsEligibleOwnersRequest(value: object): value is IncidentsEligibleOwnersRequest;
35
+ export declare function IncidentsEligibleOwnersRequestFromJSON(json: any): IncidentsEligibleOwnersRequest;
36
+ export declare function IncidentsEligibleOwnersRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): IncidentsEligibleOwnersRequest;
37
+ export declare function IncidentsEligibleOwnersRequestToJSON(json: any): IncidentsEligibleOwnersRequest;
38
+ export declare function IncidentsEligibleOwnersRequestToJSONTyped(value?: IncidentsEligibleOwnersRequest | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,53 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * My API
6
+ * API documentation for my Laravel app
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfIncidentsEligibleOwnersRequest = instanceOfIncidentsEligibleOwnersRequest;
17
+ exports.IncidentsEligibleOwnersRequestFromJSON = IncidentsEligibleOwnersRequestFromJSON;
18
+ exports.IncidentsEligibleOwnersRequestFromJSONTyped = IncidentsEligibleOwnersRequestFromJSONTyped;
19
+ exports.IncidentsEligibleOwnersRequestToJSON = IncidentsEligibleOwnersRequestToJSON;
20
+ exports.IncidentsEligibleOwnersRequestToJSONTyped = IncidentsEligibleOwnersRequestToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the IncidentsEligibleOwnersRequest interface.
23
+ */
24
+ function instanceOfIncidentsEligibleOwnersRequest(value) {
25
+ if (!('venueId' in value) || value['venueId'] === undefined)
26
+ return false;
27
+ return true;
28
+ }
29
+ function IncidentsEligibleOwnersRequestFromJSON(json) {
30
+ return IncidentsEligibleOwnersRequestFromJSONTyped(json, false);
31
+ }
32
+ function IncidentsEligibleOwnersRequestFromJSONTyped(json, ignoreDiscriminator) {
33
+ if (json == null) {
34
+ return json;
35
+ }
36
+ return {
37
+ 'venueId': json['venue_id'],
38
+ 'incidentDatetime': json['incident_datetime'] == null ? undefined : (new Date(json['incident_datetime'])),
39
+ };
40
+ }
41
+ function IncidentsEligibleOwnersRequestToJSON(json) {
42
+ return IncidentsEligibleOwnersRequestToJSONTyped(json, false);
43
+ }
44
+ function IncidentsEligibleOwnersRequestToJSONTyped(value, ignoreDiscriminator) {
45
+ if (ignoreDiscriminator === void 0) { ignoreDiscriminator = false; }
46
+ if (value == null) {
47
+ return value;
48
+ }
49
+ return {
50
+ 'venue_id': value['venueId'],
51
+ 'incident_datetime': value['incidentDatetime'] == null ? undefined : ((value['incidentDatetime']).toISOString()),
52
+ };
53
+ }
@@ -64,7 +64,7 @@ export interface RegisterListResource {
64
64
  * @type {string}
65
65
  * @memberof RegisterListResource
66
66
  */
67
- badgeNumber: string;
67
+ badgeNumber?: string | null;
68
68
  /**
69
69
  *
70
70
  * @type {Date}
@@ -148,13 +148,13 @@ export interface RegisterListResource {
148
148
  * @type {number}
149
149
  * @memberof RegisterListResource
150
150
  */
151
- signOffLat?: number | null;
151
+ signOffLat: number;
152
152
  /**
153
153
  *
154
154
  * @type {number}
155
155
  * @memberof RegisterListResource
156
156
  */
157
- signOffLong: number;
157
+ signOffLong?: number | null;
158
158
  /**
159
159
  *
160
160
  * @type {boolean}
@@ -43,8 +43,6 @@ function instanceOfRegisterListResource(value) {
43
43
  return false;
44
44
  if (!('signOffStatus' in value) || value['signOffStatus'] === undefined)
45
45
  return false;
46
- if (!('badgeNumber' in value) || value['badgeNumber'] === undefined)
47
- return false;
48
46
  if (!('licenceNumber' in value) || value['licenceNumber'] === undefined)
49
47
  return false;
50
48
  if (!('licenceFirstName' in value) || value['licenceFirstName'] === undefined)
@@ -69,7 +67,7 @@ function instanceOfRegisterListResource(value) {
69
67
  return false;
70
68
  if (!('signOnLong' in value) || value['signOnLong'] === undefined)
71
69
  return false;
72
- if (!('signOffLong' in value) || value['signOffLong'] === undefined)
70
+ if (!('signOffLat' in value) || value['signOffLat'] === undefined)
73
71
  return false;
74
72
  if (!('hasIncidents' in value) || value['hasIncidents'] === undefined)
75
73
  return false;
@@ -90,7 +88,7 @@ function RegisterListResourceFromJSONTyped(json, ignoreDiscriminator) {
90
88
  'finishDateTime': json['finishDateTime'] == null ? undefined : (new Date(json['finishDateTime'])),
91
89
  'shiftLength': json['shiftLength'],
92
90
  'signOffStatus': json['signOffStatus'],
93
- 'badgeNumber': json['badgeNumber'],
91
+ 'badgeNumber': json['badgeNumber'] == null ? undefined : json['badgeNumber'],
94
92
  'rampReadAt': json['rampReadAt'] == null ? undefined : (new Date(json['rampReadAt'])),
95
93
  'licenceNumber': json['licenceNumber'],
96
94
  'licenceFirstName': json['licenceFirstName'],
@@ -104,8 +102,8 @@ function RegisterListResourceFromJSONTyped(json, ignoreDiscriminator) {
104
102
  'firstAid': json['firstAid'],
105
103
  'signOnLat': json['signOnLat'],
106
104
  'signOnLong': json['signOnLong'],
107
- 'signOffLat': json['signOffLat'] == null ? undefined : json['signOffLat'],
108
- 'signOffLong': json['signOffLong'],
105
+ 'signOffLat': json['signOffLat'],
106
+ 'signOffLong': json['signOffLong'] == null ? undefined : json['signOffLong'],
109
107
  'hasIncidents': json['hasIncidents'],
110
108
  };
111
109
  }
@@ -17,6 +17,8 @@ export * from './BackAsset';
17
17
  export * from './CurrentRegisterResource';
18
18
  export * from './CurrentRegisterResourceArrayResponse';
19
19
  export * from './DevicesRegisterRequest';
20
+ export * from './EligibleIncidentOwnerResource';
21
+ export * from './EligibleIncidentOwnerResourceArrayResponse';
20
22
  export * from './ExportQueuedResource';
21
23
  export * from './ExportQueuedResourceArrayResponse';
22
24
  export * from './FirstAidAsset';
@@ -48,6 +50,7 @@ export * from './IncidentVideoSignedUrlResourceArrayResponse';
48
50
  export * from './IncidentVideoUploadTokenResource';
49
51
  export * from './IncidentVideoUploadTokenResourceArrayResponse';
50
52
  export * from './IncidentsApproveRequest';
53
+ export * from './IncidentsEligibleOwnersRequest';
51
54
  export * from './IncidentsExportCsvBulkRequest';
52
55
  export * from './IncidentsExportPdfBulkRequest';
53
56
  export * from './IncidentsExportPdfRequest';
@@ -35,6 +35,8 @@ __exportStar(require("./BackAsset"), exports);
35
35
  __exportStar(require("./CurrentRegisterResource"), exports);
36
36
  __exportStar(require("./CurrentRegisterResourceArrayResponse"), exports);
37
37
  __exportStar(require("./DevicesRegisterRequest"), exports);
38
+ __exportStar(require("./EligibleIncidentOwnerResource"), exports);
39
+ __exportStar(require("./EligibleIncidentOwnerResourceArrayResponse"), exports);
38
40
  __exportStar(require("./ExportQueuedResource"), exports);
39
41
  __exportStar(require("./ExportQueuedResourceArrayResponse"), exports);
40
42
  __exportStar(require("./FirstAidAsset"), exports);
@@ -66,6 +68,7 @@ __exportStar(require("./IncidentVideoSignedUrlResourceArrayResponse"), exports);
66
68
  __exportStar(require("./IncidentVideoUploadTokenResource"), exports);
67
69
  __exportStar(require("./IncidentVideoUploadTokenResourceArrayResponse"), exports);
68
70
  __exportStar(require("./IncidentsApproveRequest"), exports);
71
+ __exportStar(require("./IncidentsEligibleOwnersRequest"), exports);
69
72
  __exportStar(require("./IncidentsExportCsvBulkRequest"), exports);
70
73
  __exportStar(require("./IncidentsExportPdfBulkRequest"), exports);
71
74
  __exportStar(require("./IncidentsExportPdfRequest"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@digital8/security-registers-backend-ts-sdk",
3
- "version": "0.0.514",
3
+ "version": "0.0.515",
4
4
  "description": "OpenAPI client for @digital8/security-registers-backend-ts-sdk",
5
5
  "author": "OpenAPI-Generator",
6
6
  "repository": {
@@ -22,6 +22,7 @@ import type {
22
22
  AuthRegisterGuardFileRequest,
23
23
  AuthRegisterGuardRequest,
24
24
  DevicesRegisterRequest,
25
+ EligibleIncidentOwnerResourceArrayResponse,
25
26
  ExportQueuedResource,
26
27
  GenericResponse,
27
28
  IncidentFieldSchemaResource,
@@ -34,6 +35,7 @@ import type {
34
35
  IncidentVideoSignedUrlResource,
35
36
  IncidentVideoUploadTokenResource,
36
37
  IncidentsApproveRequest,
38
+ IncidentsEligibleOwnersRequest,
37
39
  IncidentsExportCsvBulkRequest,
38
40
  IncidentsExportPdfBulkRequest,
39
41
  IncidentsExportPdfRequest,
@@ -137,6 +139,8 @@ import {
137
139
  AuthRegisterGuardRequestToJSON,
138
140
  DevicesRegisterRequestFromJSON,
139
141
  DevicesRegisterRequestToJSON,
142
+ EligibleIncidentOwnerResourceArrayResponseFromJSON,
143
+ EligibleIncidentOwnerResourceArrayResponseToJSON,
140
144
  ExportQueuedResourceFromJSON,
141
145
  ExportQueuedResourceToJSON,
142
146
  GenericResponseFromJSON,
@@ -161,6 +165,8 @@ import {
161
165
  IncidentVideoUploadTokenResourceToJSON,
162
166
  IncidentsApproveRequestFromJSON,
163
167
  IncidentsApproveRequestToJSON,
168
+ IncidentsEligibleOwnersRequestFromJSON,
169
+ IncidentsEligibleOwnersRequestToJSON,
164
170
  IncidentsExportCsvBulkRequestFromJSON,
165
171
  IncidentsExportCsvBulkRequestToJSON,
166
172
  IncidentsExportPdfBulkRequestFromJSON,
@@ -386,6 +392,10 @@ export interface IncidentsDestroyRequest {
386
392
  incident: number;
387
393
  }
388
394
 
395
+ export interface IncidentsEligibleOwnersOperationRequest {
396
+ incidentsEligibleOwnersRequest?: IncidentsEligibleOwnersRequest;
397
+ }
398
+
389
399
  export interface IncidentsExportCsvRequest {
390
400
  incident: number;
391
401
  incidentsExportPdfRequest?: IncidentsExportPdfRequest;
@@ -1317,6 +1327,46 @@ export class GeneralApi extends runtime.BaseAPI {
1317
1327
  return await response.value();
1318
1328
  }
1319
1329
 
1330
+ /**
1331
+ * Auto-generated: incidents.eligibleOwners
1332
+ */
1333
+ async incidentsEligibleOwnersRaw(requestParameters: IncidentsEligibleOwnersOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<EligibleIncidentOwnerResourceArrayResponse>> {
1334
+ const queryParameters: any = {};
1335
+
1336
+ const headerParameters: runtime.HTTPHeaders = {};
1337
+
1338
+ headerParameters['Content-Type'] = 'application/json';
1339
+
1340
+ if (this.configuration && this.configuration.accessToken) {
1341
+ const token = this.configuration.accessToken;
1342
+ const tokenString = await token("bearerAuth", []);
1343
+
1344
+ if (tokenString) {
1345
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
1346
+ }
1347
+ }
1348
+
1349
+ let urlPath = `/api/incidents/eligible-owners`;
1350
+
1351
+ const response = await this.request({
1352
+ path: urlPath,
1353
+ method: 'POST',
1354
+ headers: headerParameters,
1355
+ query: queryParameters,
1356
+ body: IncidentsEligibleOwnersRequestToJSON(requestParameters['incidentsEligibleOwnersRequest']),
1357
+ }, initOverrides);
1358
+
1359
+ return new runtime.JSONApiResponse(response, (jsonValue) => EligibleIncidentOwnerResourceArrayResponseFromJSON(jsonValue));
1360
+ }
1361
+
1362
+ /**
1363
+ * Auto-generated: incidents.eligibleOwners
1364
+ */
1365
+ async incidentsEligibleOwners(requestParameters: IncidentsEligibleOwnersOperationRequest = {}, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<EligibleIncidentOwnerResourceArrayResponse> {
1366
+ const response = await this.incidentsEligibleOwnersRaw(requestParameters, initOverrides);
1367
+ return await response.value();
1368
+ }
1369
+
1320
1370
  /**
1321
1371
  * Auto-generated: incidents.exportCsv
1322
1372
  */
@@ -36,7 +36,7 @@ export interface AddressResource {
36
36
  * @type {string}
37
37
  * @memberof AddressResource
38
38
  */
39
- addressLine2: string;
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'],
@@ -48,7 +48,7 @@ export interface AssetResource {
48
48
  * @type {string}
49
49
  * @memberof AssetResource
50
50
  */
51
- altText?: string | null;
51
+ altText: string;
52
52
  /**
53
53
  *
54
54
  * @type {number}
@@ -83,6 +83,7 @@ export function instanceOfAssetResource(value: object): value is AssetResource {
83
83
  if (!('filePath' in value) || value['filePath'] === undefined) return false;
84
84
  if (!('fileName' in value) || value['fileName'] === undefined) return false;
85
85
  if (!('mimeType' in value) || value['mimeType'] === undefined) return false;
86
+ if (!('altText' in value) || value['altText'] === undefined) return false;
86
87
  if (!('index' in value) || value['index'] === undefined) return false;
87
88
  if (!('fileId' in value) || value['fileId'] === undefined) return false;
88
89
  if (!('isExternal' in value) || value['isExternal'] === undefined) return false;
@@ -103,7 +104,7 @@ export function AssetResourceFromJSONTyped(json: any, ignoreDiscriminator: boole
103
104
  'filePath': json['filePath'],
104
105
  'fileName': json['fileName'],
105
106
  'mimeType': json['mimeType'],
106
- 'altText': json['altText'] == null ? undefined : json['altText'],
107
+ 'altText': json['altText'],
107
108
  'index': json['index'],
108
109
  'fileId': json['fileId'],
109
110
  'isExternal': json['isExternal'],
@@ -0,0 +1,111 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * My API
5
+ * API documentation for my Laravel app
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface EligibleIncidentOwnerResource
20
+ */
21
+ export interface EligibleIncidentOwnerResource {
22
+ /**
23
+ *
24
+ * @type {number}
25
+ * @memberof EligibleIncidentOwnerResource
26
+ */
27
+ id: number;
28
+ /**
29
+ *
30
+ * @type {string}
31
+ * @memberof EligibleIncidentOwnerResource
32
+ */
33
+ firstName: string;
34
+ /**
35
+ *
36
+ * @type {string}
37
+ * @memberof EligibleIncidentOwnerResource
38
+ */
39
+ lastName: string;
40
+ /**
41
+ *
42
+ * @type {string}
43
+ * @memberof EligibleIncidentOwnerResource
44
+ */
45
+ fullName: string;
46
+ /**
47
+ *
48
+ * @type {string}
49
+ * @memberof EligibleIncidentOwnerResource
50
+ */
51
+ role: string;
52
+ /**
53
+ *
54
+ * @type {boolean}
55
+ * @memberof EligibleIncidentOwnerResource
56
+ */
57
+ activeRegisterAtIncidentDatetime: boolean;
58
+ }
59
+
60
+ /**
61
+ * Check if a given object implements the EligibleIncidentOwnerResource interface.
62
+ */
63
+ export function instanceOfEligibleIncidentOwnerResource(value: object): value is EligibleIncidentOwnerResource {
64
+ if (!('id' in value) || value['id'] === undefined) return false;
65
+ if (!('firstName' in value) || value['firstName'] === undefined) return false;
66
+ if (!('lastName' in value) || value['lastName'] === undefined) return false;
67
+ if (!('fullName' in value) || value['fullName'] === undefined) return false;
68
+ if (!('role' in value) || value['role'] === undefined) return false;
69
+ if (!('activeRegisterAtIncidentDatetime' in value) || value['activeRegisterAtIncidentDatetime'] === undefined) return false;
70
+ return true;
71
+ }
72
+
73
+ export function EligibleIncidentOwnerResourceFromJSON(json: any): EligibleIncidentOwnerResource {
74
+ return EligibleIncidentOwnerResourceFromJSONTyped(json, false);
75
+ }
76
+
77
+ export function EligibleIncidentOwnerResourceFromJSONTyped(json: any, ignoreDiscriminator: boolean): EligibleIncidentOwnerResource {
78
+ if (json == null) {
79
+ return json;
80
+ }
81
+ return {
82
+
83
+ 'id': json['id'],
84
+ 'firstName': json['firstName'],
85
+ 'lastName': json['lastName'],
86
+ 'fullName': json['fullName'],
87
+ 'role': json['role'],
88
+ 'activeRegisterAtIncidentDatetime': json['activeRegisterAtIncidentDatetime'],
89
+ };
90
+ }
91
+
92
+ export function EligibleIncidentOwnerResourceToJSON(json: any): EligibleIncidentOwnerResource {
93
+ return EligibleIncidentOwnerResourceToJSONTyped(json, false);
94
+ }
95
+
96
+ export function EligibleIncidentOwnerResourceToJSONTyped(value?: EligibleIncidentOwnerResource | null, ignoreDiscriminator: boolean = false): any {
97
+ if (value == null) {
98
+ return value;
99
+ }
100
+
101
+ return {
102
+
103
+ 'id': value['id'],
104
+ 'firstName': value['firstName'],
105
+ 'lastName': value['lastName'],
106
+ 'fullName': value['fullName'],
107
+ 'role': value['role'],
108
+ 'activeRegisterAtIncidentDatetime': value['activeRegisterAtIncidentDatetime'],
109
+ };
110
+ }
111
+
@@ -0,0 +1,73 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * My API
5
+ * API documentation for my Laravel app
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime';
16
+ import type { EligibleIncidentOwnerResource } from './EligibleIncidentOwnerResource';
17
+ import {
18
+ EligibleIncidentOwnerResourceFromJSON,
19
+ EligibleIncidentOwnerResourceFromJSONTyped,
20
+ EligibleIncidentOwnerResourceToJSON,
21
+ EligibleIncidentOwnerResourceToJSONTyped,
22
+ } from './EligibleIncidentOwnerResource';
23
+
24
+ /**
25
+ *
26
+ * @export
27
+ * @interface EligibleIncidentOwnerResourceArrayResponse
28
+ */
29
+ export interface EligibleIncidentOwnerResourceArrayResponse {
30
+ /**
31
+ *
32
+ * @type {Array<EligibleIncidentOwnerResource>}
33
+ * @memberof EligibleIncidentOwnerResourceArrayResponse
34
+ */
35
+ data?: Array<EligibleIncidentOwnerResource>;
36
+ }
37
+
38
+ /**
39
+ * Check if a given object implements the EligibleIncidentOwnerResourceArrayResponse interface.
40
+ */
41
+ export function instanceOfEligibleIncidentOwnerResourceArrayResponse(value: object): value is EligibleIncidentOwnerResourceArrayResponse {
42
+ return true;
43
+ }
44
+
45
+ export function EligibleIncidentOwnerResourceArrayResponseFromJSON(json: any): EligibleIncidentOwnerResourceArrayResponse {
46
+ return EligibleIncidentOwnerResourceArrayResponseFromJSONTyped(json, false);
47
+ }
48
+
49
+ export function EligibleIncidentOwnerResourceArrayResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): EligibleIncidentOwnerResourceArrayResponse {
50
+ if (json == null) {
51
+ return json;
52
+ }
53
+ return {
54
+
55
+ 'data': json['data'] == null ? undefined : ((json['data'] as Array<any>).map(EligibleIncidentOwnerResourceFromJSON)),
56
+ };
57
+ }
58
+
59
+ export function EligibleIncidentOwnerResourceArrayResponseToJSON(json: any): EligibleIncidentOwnerResourceArrayResponse {
60
+ return EligibleIncidentOwnerResourceArrayResponseToJSONTyped(json, false);
61
+ }
62
+
63
+ export function EligibleIncidentOwnerResourceArrayResponseToJSONTyped(value?: EligibleIncidentOwnerResourceArrayResponse | null, ignoreDiscriminator: boolean = false): any {
64
+ if (value == null) {
65
+ return value;
66
+ }
67
+
68
+ return {
69
+
70
+ 'data': value['data'] == null ? undefined : ((value['data'] as Array<any>).map(EligibleIncidentOwnerResourceToJSON)),
71
+ };
72
+ }
73
+
@@ -0,0 +1,74 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * My API
5
+ * API documentation for my Laravel app
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface IncidentsEligibleOwnersRequest
20
+ */
21
+ export interface IncidentsEligibleOwnersRequest {
22
+ /**
23
+ *
24
+ * @type {number}
25
+ * @memberof IncidentsEligibleOwnersRequest
26
+ */
27
+ venueId: number;
28
+ /**
29
+ * Optional incident start datetime (ISO-8601, in the venue's timezone). Used to decide guard eligibility ("signed on at this venue OR not signed on at any other venue at that time") and to flag the `activeRegisterAtIncidentDatetime` field on each result. Omit to fall back to the current server time.
30
+ * @type {Date}
31
+ * @memberof IncidentsEligibleOwnersRequest
32
+ */
33
+ incidentDatetime?: Date;
34
+ }
35
+
36
+ /**
37
+ * Check if a given object implements the IncidentsEligibleOwnersRequest interface.
38
+ */
39
+ export function instanceOfIncidentsEligibleOwnersRequest(value: object): value is IncidentsEligibleOwnersRequest {
40
+ if (!('venueId' in value) || value['venueId'] === undefined) return false;
41
+ return true;
42
+ }
43
+
44
+ export function IncidentsEligibleOwnersRequestFromJSON(json: any): IncidentsEligibleOwnersRequest {
45
+ return IncidentsEligibleOwnersRequestFromJSONTyped(json, false);
46
+ }
47
+
48
+ export function IncidentsEligibleOwnersRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): IncidentsEligibleOwnersRequest {
49
+ if (json == null) {
50
+ return json;
51
+ }
52
+ return {
53
+
54
+ 'venueId': json['venue_id'],
55
+ 'incidentDatetime': json['incident_datetime'] == null ? undefined : (new Date(json['incident_datetime'])),
56
+ };
57
+ }
58
+
59
+ export function IncidentsEligibleOwnersRequestToJSON(json: any): IncidentsEligibleOwnersRequest {
60
+ return IncidentsEligibleOwnersRequestToJSONTyped(json, false);
61
+ }
62
+
63
+ export function IncidentsEligibleOwnersRequestToJSONTyped(value?: IncidentsEligibleOwnersRequest | null, ignoreDiscriminator: boolean = false): any {
64
+ if (value == null) {
65
+ return value;
66
+ }
67
+
68
+ return {
69
+
70
+ 'venue_id': value['venueId'],
71
+ 'incident_datetime': value['incidentDatetime'] == null ? undefined : ((value['incidentDatetime']).toISOString()),
72
+ };
73
+ }
74
+
@@ -81,7 +81,7 @@ export interface RegisterListResource {
81
81
  * @type {string}
82
82
  * @memberof RegisterListResource
83
83
  */
84
- badgeNumber: string;
84
+ badgeNumber?: string | null;
85
85
  /**
86
86
  *
87
87
  * @type {Date}
@@ -165,13 +165,13 @@ export interface RegisterListResource {
165
165
  * @type {number}
166
166
  * @memberof RegisterListResource
167
167
  */
168
- signOffLat?: number | null;
168
+ signOffLat: number;
169
169
  /**
170
170
  *
171
171
  * @type {number}
172
172
  * @memberof RegisterListResource
173
173
  */
174
- signOffLong: number;
174
+ signOffLong?: number | null;
175
175
  /**
176
176
  *
177
177
  * @type {boolean}
@@ -201,7 +201,6 @@ export function instanceOfRegisterListResource(value: object): value is Register
201
201
  if (!('startDateTime' in value) || value['startDateTime'] === undefined) return false;
202
202
  if (!('shiftLength' in value) || value['shiftLength'] === undefined) return false;
203
203
  if (!('signOffStatus' in value) || value['signOffStatus'] === undefined) return false;
204
- if (!('badgeNumber' in value) || value['badgeNumber'] === undefined) return false;
205
204
  if (!('licenceNumber' in value) || value['licenceNumber'] === undefined) return false;
206
205
  if (!('licenceFirstName' in value) || value['licenceFirstName'] === undefined) return false;
207
206
  if (!('licenceLastName' in value) || value['licenceLastName'] === undefined) return false;
@@ -214,7 +213,7 @@ export function instanceOfRegisterListResource(value: object): value is Register
214
213
  if (!('firstAid' in value) || value['firstAid'] === undefined) return false;
215
214
  if (!('signOnLat' in value) || value['signOnLat'] === undefined) return false;
216
215
  if (!('signOnLong' in value) || value['signOnLong'] === undefined) return false;
217
- if (!('signOffLong' in value) || value['signOffLong'] === undefined) return false;
216
+ if (!('signOffLat' in value) || value['signOffLat'] === undefined) return false;
218
217
  if (!('hasIncidents' in value) || value['hasIncidents'] === undefined) return false;
219
218
  return true;
220
219
  }
@@ -236,7 +235,7 @@ export function RegisterListResourceFromJSONTyped(json: any, ignoreDiscriminator
236
235
  'finishDateTime': json['finishDateTime'] == null ? undefined : (new Date(json['finishDateTime'])),
237
236
  'shiftLength': json['shiftLength'],
238
237
  'signOffStatus': json['signOffStatus'],
239
- 'badgeNumber': json['badgeNumber'],
238
+ 'badgeNumber': json['badgeNumber'] == null ? undefined : json['badgeNumber'],
240
239
  'rampReadAt': json['rampReadAt'] == null ? undefined : (new Date(json['rampReadAt'])),
241
240
  'licenceNumber': json['licenceNumber'],
242
241
  'licenceFirstName': json['licenceFirstName'],
@@ -250,8 +249,8 @@ export function RegisterListResourceFromJSONTyped(json: any, ignoreDiscriminator
250
249
  'firstAid': json['firstAid'],
251
250
  'signOnLat': json['signOnLat'],
252
251
  'signOnLong': json['signOnLong'],
253
- 'signOffLat': json['signOffLat'] == null ? undefined : json['signOffLat'],
254
- 'signOffLong': json['signOffLong'],
252
+ 'signOffLat': json['signOffLat'],
253
+ 'signOffLong': json['signOffLong'] == null ? undefined : json['signOffLong'],
255
254
  'hasIncidents': json['hasIncidents'],
256
255
  };
257
256
  }
@@ -19,6 +19,8 @@ export * from './BackAsset';
19
19
  export * from './CurrentRegisterResource';
20
20
  export * from './CurrentRegisterResourceArrayResponse';
21
21
  export * from './DevicesRegisterRequest';
22
+ export * from './EligibleIncidentOwnerResource';
23
+ export * from './EligibleIncidentOwnerResourceArrayResponse';
22
24
  export * from './ExportQueuedResource';
23
25
  export * from './ExportQueuedResourceArrayResponse';
24
26
  export * from './FirstAidAsset';
@@ -50,6 +52,7 @@ export * from './IncidentVideoSignedUrlResourceArrayResponse';
50
52
  export * from './IncidentVideoUploadTokenResource';
51
53
  export * from './IncidentVideoUploadTokenResourceArrayResponse';
52
54
  export * from './IncidentsApproveRequest';
55
+ export * from './IncidentsEligibleOwnersRequest';
53
56
  export * from './IncidentsExportCsvBulkRequest';
54
57
  export * from './IncidentsExportPdfBulkRequest';
55
58
  export * from './IncidentsExportPdfRequest';