@turndown/library 0.1.20 → 0.1.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/helpers/object/index.js +9 -6
- package/dist/helpers/string/index.d.ts +5 -4
- package/dist/helpers/string/index.js +7 -6
- package/dist/types/auth/routes.d.ts +27 -7
- package/dist/types/base/index.d.ts +72 -69
- package/dist/types/base/index.js +60 -67
- package/dist/types/checklist-template/routes.d.ts +55 -26
- package/dist/types/checklist-template/routes.js +0 -1
- package/dist/types/company/index.d.ts +5 -5
- package/dist/types/company/routes.d.ts +81 -33
- package/dist/types/company/routes.js +0 -1
- package/dist/types/damage-report/index.d.ts +18 -2
- package/dist/types/damage-report/index.js +15 -0
- package/dist/types/damage-report/routes.d.ts +122 -45
- package/dist/types/damage-report/routes.js +0 -1
- package/dist/types/health/index.d.ts +20 -0
- package/dist/types/health/index.js +1 -0
- package/dist/types/health/routes.d.ts +10 -0
- package/dist/types/health/routes.js +1 -0
- package/dist/types/image/index.d.ts +34 -0
- package/dist/types/image/index.js +11 -0
- package/dist/types/image/routes.d.ts +32 -0
- package/dist/types/image/routes.js +1 -0
- package/dist/types/index.d.ts +2 -0
- package/dist/types/index.js +2 -0
- package/dist/types/inventory/index.d.ts +0 -74
- package/dist/types/inventory/routes.d.ts +72 -35
- package/dist/types/inventory/routes.js +0 -1
- package/dist/types/property/index.d.ts +10 -9
- package/dist/types/property/routes.d.ts +27 -28
- package/dist/types/room/routes.d.ts +26 -7
- package/dist/types/room/routes.js +0 -1
- package/dist/types/room-checklist/routes.d.ts +48 -26
- package/dist/types/room-checklist/routes.js +0 -1
- package/dist/types/user/index.d.ts +2 -3
- package/dist/types/user/index.js +2 -3
- package/dist/types/user/routes.d.ts +13 -3
- package/dist/types/user/routes.js +0 -1
- package/dist/types/work-session/routes.d.ts +53 -32
- package/dist/types/work-session/routes.js +0 -1
- package/package.json +3 -2
|
@@ -1,72 +1,109 @@
|
|
|
1
|
-
|
|
1
|
+
import type { IInventoryCount, IInventoryItem, IInventoryRestockOrder, IInventoryRestockOrderItem, IPropertyInventory, IRoomInventory, TInventoryRestockOrderStatus } from ".";
|
|
2
|
+
import type { IMessageResponse } from "../base";
|
|
3
|
+
export interface IInventoryCompanyRouteParams {
|
|
4
|
+
companyId: string;
|
|
2
5
|
}
|
|
3
|
-
export interface
|
|
6
|
+
export interface IInventoryItemRouteParams {
|
|
7
|
+
itemId: string;
|
|
4
8
|
}
|
|
5
|
-
export interface
|
|
9
|
+
export interface IInventoryRoomRouteParams {
|
|
10
|
+
roomId: string;
|
|
6
11
|
}
|
|
7
|
-
export interface
|
|
12
|
+
export interface IInventoryPropertyRouteParams {
|
|
13
|
+
propertyId: string;
|
|
8
14
|
}
|
|
9
|
-
export interface
|
|
15
|
+
export interface IInventoryExecutionRouteParams {
|
|
16
|
+
executionId: string;
|
|
10
17
|
}
|
|
11
|
-
export interface
|
|
18
|
+
export interface IRoomInventoryIdParams {
|
|
19
|
+
roomInventoryId: string;
|
|
12
20
|
}
|
|
13
|
-
export interface
|
|
21
|
+
export interface IInventoryOrderRouteParams {
|
|
22
|
+
orderId: string;
|
|
14
23
|
}
|
|
15
|
-
export interface
|
|
24
|
+
export interface ICreateInventoryItemRequest extends Partial<IInventoryItem> {
|
|
25
|
+
companyId: string;
|
|
26
|
+
name: string;
|
|
16
27
|
}
|
|
17
|
-
export interface
|
|
28
|
+
export interface ICreateInventoryItemResponse extends IInventoryItem {
|
|
18
29
|
}
|
|
19
|
-
export interface
|
|
30
|
+
export interface IGetInventoryItemByIdRequest extends IInventoryItemRouteParams {
|
|
20
31
|
}
|
|
21
|
-
export interface
|
|
32
|
+
export interface IGetInventoryItemByIdResponse extends IInventoryItem {
|
|
22
33
|
}
|
|
23
|
-
export interface
|
|
34
|
+
export interface IUpdateInventoryItemRequest extends Partial<IInventoryItem> {
|
|
24
35
|
}
|
|
25
|
-
export interface
|
|
36
|
+
export interface IUpdateInventoryItemResponse extends IInventoryItem {
|
|
26
37
|
}
|
|
27
|
-
export interface
|
|
38
|
+
export interface IDeleteInventoryItemRequest extends IInventoryItemRouteParams {
|
|
28
39
|
}
|
|
29
|
-
export interface
|
|
40
|
+
export interface IDeleteInventoryItemResponse extends IMessageResponse {
|
|
30
41
|
}
|
|
31
|
-
export interface
|
|
42
|
+
export interface IGetInventoryByCompanyIdRequest extends IInventoryCompanyRouteParams {
|
|
32
43
|
}
|
|
33
|
-
export
|
|
44
|
+
export type IGetInventoryByCompanyIdResponse = IInventoryItem[];
|
|
45
|
+
export interface IAddInventoryToPropertyRequest extends Partial<IPropertyInventory> {
|
|
46
|
+
propertyId: string;
|
|
47
|
+
inventoryItemId: string;
|
|
34
48
|
}
|
|
35
|
-
export interface
|
|
49
|
+
export interface IAddInventoryToPropertyResponse extends IPropertyInventory {
|
|
36
50
|
}
|
|
37
|
-
export interface
|
|
51
|
+
export interface IGetPropertyInventoryRequest extends IInventoryPropertyRouteParams {
|
|
38
52
|
}
|
|
39
|
-
export
|
|
53
|
+
export type IGetPropertyInventoryResponse = IPropertyInventory[];
|
|
54
|
+
export interface IGetPropertyInventoryNeedingRestockRequest extends IInventoryPropertyRouteParams {
|
|
40
55
|
}
|
|
41
|
-
export
|
|
56
|
+
export type IGetPropertyInventoryNeedingRestockResponse = IPropertyInventory[];
|
|
57
|
+
export interface IAddInventoryToRoomRequest extends Partial<IRoomInventory> {
|
|
58
|
+
roomId: string;
|
|
59
|
+
inventoryItemId: string;
|
|
42
60
|
}
|
|
43
|
-
export interface
|
|
61
|
+
export interface IAddInventoryToRoomResponse extends IRoomInventory {
|
|
44
62
|
}
|
|
45
|
-
export interface
|
|
63
|
+
export interface IGetRoomInventoryRequest extends IInventoryRoomRouteParams {
|
|
46
64
|
}
|
|
47
|
-
export
|
|
65
|
+
export type IGetRoomInventoryResponse = IRoomInventory[];
|
|
66
|
+
export interface IUpdateRoomInventoryRequest extends Partial<IRoomInventory> {
|
|
48
67
|
}
|
|
49
|
-
export interface
|
|
68
|
+
export interface IUpdateRoomInventoryResponse extends IRoomInventory {
|
|
50
69
|
}
|
|
51
|
-
export interface
|
|
70
|
+
export interface IGetRoomInventoryNeedingRestockRequest extends IInventoryRoomRouteParams {
|
|
52
71
|
}
|
|
53
|
-
export
|
|
72
|
+
export type IGetRoomInventoryNeedingRestockResponse = IRoomInventory[];
|
|
73
|
+
export interface IRecordInventoryCountRequest extends Partial<IInventoryCount> {
|
|
74
|
+
checklistExecutionId: string;
|
|
75
|
+
roomInventoryId: string;
|
|
76
|
+
countedLevel: number;
|
|
77
|
+
countedBy: string;
|
|
54
78
|
}
|
|
55
|
-
export interface
|
|
79
|
+
export interface IRecordInventoryCountResponse extends IInventoryCount {
|
|
56
80
|
}
|
|
57
|
-
export interface
|
|
81
|
+
export interface IGetInventoryCountsByExecutionIdRequest extends IInventoryExecutionRouteParams {
|
|
58
82
|
}
|
|
59
|
-
export
|
|
83
|
+
export type IGetInventoryCountsByExecutionIdResponse = IInventoryCount[];
|
|
84
|
+
export interface IRestockOrderItemInput {
|
|
85
|
+
inventoryItemId: string;
|
|
86
|
+
roomInventoryId?: string;
|
|
87
|
+
propertyInventoryId?: string;
|
|
88
|
+
quantityOrdered: number;
|
|
89
|
+
unitCost?: number;
|
|
60
90
|
}
|
|
61
|
-
export interface
|
|
91
|
+
export interface ICreateRestockOrderRequest extends Partial<IInventoryRestockOrder> {
|
|
92
|
+
companyId: string;
|
|
93
|
+
orderedBy: string;
|
|
94
|
+
items: IRestockOrderItemInput[];
|
|
62
95
|
}
|
|
63
|
-
export interface
|
|
96
|
+
export interface ICreateRestockOrderResponse extends IInventoryRestockOrder {
|
|
64
97
|
}
|
|
65
|
-
export interface
|
|
98
|
+
export interface IGetRestockOrdersByCompanyIdRequest extends IInventoryCompanyRouteParams {
|
|
66
99
|
}
|
|
67
|
-
export
|
|
100
|
+
export type IGetRestockOrdersByCompanyIdResponse = IInventoryRestockOrder[];
|
|
101
|
+
export interface IGetRestockOrderItemsRequest extends IInventoryOrderRouteParams {
|
|
68
102
|
}
|
|
103
|
+
export type IGetRestockOrderItemsResponse = IInventoryRestockOrderItem[];
|
|
69
104
|
export interface IUpdateRestockOrderStatusRequest {
|
|
105
|
+
status: TInventoryRestockOrderStatus;
|
|
106
|
+
receivedBy?: string;
|
|
70
107
|
}
|
|
71
|
-
export interface IUpdateRestockOrderStatusResponse {
|
|
108
|
+
export interface IUpdateRestockOrderStatusResponse extends IInventoryRestockOrder {
|
|
72
109
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ISelectOption, IMetaData, TRecordValue, TStatus,
|
|
1
|
+
import { ISelectOption, IMetaData, TRecordValue, TStatus, TUSStateCode } from "../index";
|
|
2
2
|
export * from "./routes";
|
|
3
3
|
export declare const PROPERTY_STATUS: {
|
|
4
4
|
readonly Active: "Active";
|
|
@@ -12,14 +12,14 @@ export declare const PropertyTypeOptions: ISelectOption<TPropertyType>[];
|
|
|
12
12
|
export interface IProperty extends IMetaData {
|
|
13
13
|
id: string;
|
|
14
14
|
displayName: string;
|
|
15
|
-
addressLine1
|
|
15
|
+
addressLine1: string;
|
|
16
16
|
addressLine2?: string;
|
|
17
|
-
city
|
|
18
|
-
stateCode
|
|
17
|
+
city: string;
|
|
18
|
+
stateCode: TUSStateCode | string;
|
|
19
19
|
propertyType?: TPropertyType;
|
|
20
20
|
status?: TPropertyStatus;
|
|
21
21
|
sqft?: number;
|
|
22
|
-
postalCode
|
|
22
|
+
postalCode: string;
|
|
23
23
|
country?: string;
|
|
24
24
|
timezone?: string;
|
|
25
25
|
imageUrl?: string;
|
|
@@ -97,10 +97,11 @@ export interface IPropertySummary {
|
|
|
97
97
|
id: string;
|
|
98
98
|
displayName: string;
|
|
99
99
|
propertyType: TPropertyType;
|
|
100
|
-
addressLine1
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
100
|
+
addressLine1: string;
|
|
101
|
+
addressLine2: string;
|
|
102
|
+
city: string;
|
|
103
|
+
stateCode: string;
|
|
104
|
+
postalCode: string;
|
|
104
105
|
imageUrl?: string;
|
|
105
106
|
status?: string;
|
|
106
107
|
}
|
|
@@ -1,12 +1,25 @@
|
|
|
1
|
-
import type { IPropertyAccessInformation, IPropertyDetail, IPropertySummary } from ".";
|
|
1
|
+
import type { IProperty, IPropertyAccessInformation, IPropertyDetail, IPropertySummary } from ".";
|
|
2
|
+
import type { IMessageResponse } from "../base";
|
|
3
|
+
export interface IPropertyIdParams {
|
|
4
|
+
propertyId: string;
|
|
5
|
+
}
|
|
6
|
+
export interface ICompanyIdParams {
|
|
7
|
+
companyId: string;
|
|
8
|
+
}
|
|
2
9
|
export interface ICreatePropertyRequest {
|
|
10
|
+
companyId: string;
|
|
3
11
|
displayName: string;
|
|
4
12
|
propertyType: string;
|
|
5
|
-
status
|
|
13
|
+
status?: string;
|
|
6
14
|
addressLine1: string;
|
|
15
|
+
addressLine2?: string;
|
|
7
16
|
city: string;
|
|
8
17
|
stateCode: string;
|
|
9
18
|
postalCode: string;
|
|
19
|
+
country?: string;
|
|
20
|
+
sqft?: number;
|
|
21
|
+
timezone?: string;
|
|
22
|
+
photoUrl?: string;
|
|
10
23
|
specialNotes?: string;
|
|
11
24
|
}
|
|
12
25
|
export interface IUpdatePropertyRequest extends Partial<ICreatePropertyRequest> {
|
|
@@ -14,42 +27,28 @@ export interface IUpdatePropertyRequest extends Partial<ICreatePropertyRequest>
|
|
|
14
27
|
export interface IGetPropertiesRequest {
|
|
15
28
|
companyId?: string;
|
|
16
29
|
}
|
|
17
|
-
export interface IGetPropertyByIdRequest {
|
|
18
|
-
id: string;
|
|
19
|
-
}
|
|
20
|
-
export interface IDeletePropertyRequest {
|
|
21
|
-
id: string;
|
|
30
|
+
export interface IGetPropertyByIdRequest extends IPropertyIdParams {
|
|
22
31
|
}
|
|
23
|
-
export interface
|
|
24
|
-
properties: IPropertySummary[];
|
|
32
|
+
export interface IDeletePropertyRequest extends IPropertyIdParams {
|
|
25
33
|
}
|
|
26
|
-
export
|
|
27
|
-
|
|
34
|
+
export type IGetPropertiesResponse = IPropertySummary[];
|
|
35
|
+
export interface IGetPropertyResponse extends IPropertyDetail {
|
|
28
36
|
}
|
|
29
|
-
export interface ICreatePropertyResponse {
|
|
30
|
-
property: IPropertyDetail;
|
|
37
|
+
export interface ICreatePropertyResponse extends IPropertyDetail {
|
|
31
38
|
}
|
|
32
|
-
export interface IUpdatePropertyResponse {
|
|
33
|
-
property: IPropertyDetail;
|
|
39
|
+
export interface IUpdatePropertyResponse extends IPropertyDetail {
|
|
34
40
|
}
|
|
35
|
-
export interface IDeletePropertyResponse {
|
|
36
|
-
message?: string;
|
|
41
|
+
export interface IDeletePropertyResponse extends IMessageResponse {
|
|
37
42
|
}
|
|
38
43
|
export interface IUpdatePropertyAccessInformationRequest extends Partial<IPropertyAccessInformation> {
|
|
39
|
-
propertyId: string;
|
|
40
|
-
}
|
|
41
|
-
export interface IUpdatePropertyAccessInformationResponse {
|
|
42
|
-
propertyAccessInformation: IPropertyAccessInformation;
|
|
43
44
|
}
|
|
44
|
-
export interface
|
|
45
|
-
propertyId: string;
|
|
45
|
+
export interface IUpdatePropertyAccessInformationResponse extends IPropertyAccessInformation {
|
|
46
46
|
}
|
|
47
|
-
export interface
|
|
48
|
-
propertyAccessInformation: IPropertyAccessInformation | null;
|
|
47
|
+
export interface IGetPropertyAccessInformationRequest extends IPropertyIdParams {
|
|
49
48
|
}
|
|
49
|
+
export type IGetPropertyAccessInformationResponse = IPropertyAccessInformation | null;
|
|
50
50
|
export interface IGetPropertyByIdResponse extends IGetPropertyResponse {
|
|
51
51
|
}
|
|
52
|
-
export interface IGetPropertiesByCompanyIdRequest extends
|
|
53
|
-
}
|
|
54
|
-
export interface IGetPropertiesByCompanyIdResponse extends IGetPropertiesResponse {
|
|
52
|
+
export interface IGetPropertiesByCompanyIdRequest extends ICompanyIdParams {
|
|
55
53
|
}
|
|
54
|
+
export type IGetPropertiesByCompanyIdResponse = IProperty[];
|
|
@@ -1,16 +1,35 @@
|
|
|
1
|
+
import type { IRoom } from ".";
|
|
2
|
+
import type { IMessageResponse } from "../base";
|
|
3
|
+
export interface IRoomPropertyRouteParams {
|
|
4
|
+
propertyId: string;
|
|
5
|
+
}
|
|
6
|
+
export interface IRoomRouteParams {
|
|
7
|
+
roomId: string;
|
|
8
|
+
}
|
|
1
9
|
export interface ICreateRoomRequest {
|
|
10
|
+
propertyId: string;
|
|
11
|
+
displayName: string;
|
|
12
|
+
description?: string;
|
|
13
|
+
checklistTemplateId?: string;
|
|
14
|
+
}
|
|
15
|
+
export interface ICreateRoomResponse extends IRoom {
|
|
16
|
+
}
|
|
17
|
+
export interface IGetRoomsByPropertyIdRequest extends IRoomPropertyRouteParams {
|
|
2
18
|
}
|
|
3
|
-
export
|
|
19
|
+
export type IGetRoomsByPropertyIdResponse = IRoom[];
|
|
20
|
+
export interface IGetDetailedRoomsByPropertyIdRequest extends IRoomPropertyRouteParams {
|
|
4
21
|
}
|
|
5
|
-
export
|
|
22
|
+
export type IGetDetailedRoomsByPropertyIdResponse = IRoom[];
|
|
23
|
+
export interface IGetRoomByIdRequest extends IRoomRouteParams {
|
|
6
24
|
}
|
|
7
|
-
export interface
|
|
25
|
+
export interface IGetRoomByIdResponse extends IRoom {
|
|
8
26
|
}
|
|
9
|
-
export interface IUpdateRoomRequest {
|
|
27
|
+
export interface IUpdateRoomRequest extends Partial<ICreateRoomRequest> {
|
|
28
|
+
displayName?: string;
|
|
10
29
|
}
|
|
11
|
-
export interface IUpdateRoomResponse {
|
|
30
|
+
export interface IUpdateRoomResponse extends IRoom {
|
|
12
31
|
}
|
|
13
|
-
export interface IDeleteRoomRequest {
|
|
32
|
+
export interface IDeleteRoomRequest extends IRoomRouteParams {
|
|
14
33
|
}
|
|
15
|
-
export interface IDeleteRoomResponse {
|
|
34
|
+
export interface IDeleteRoomResponse extends IMessageResponse {
|
|
16
35
|
}
|
|
@@ -1,56 +1,78 @@
|
|
|
1
|
-
|
|
1
|
+
import type { ICreateRoomChecklistInput, ICreateRoomChecklistItemInput, IRoomChecklist, IRoomChecklistItem, IRoomChecklistWithItems } from ".";
|
|
2
|
+
import type { IMessageResponse } from "../base";
|
|
3
|
+
export interface IRoomChecklistRoomRouteParams {
|
|
4
|
+
roomId: string;
|
|
2
5
|
}
|
|
3
|
-
export interface
|
|
6
|
+
export interface IChecklistIdParams {
|
|
7
|
+
checklistId: string;
|
|
8
|
+
}
|
|
9
|
+
export interface IChecklistAndItemIdParams {
|
|
10
|
+
checklistId: string;
|
|
11
|
+
itemId: string;
|
|
12
|
+
}
|
|
13
|
+
export interface ICreateChecklistRequest extends Omit<ICreateRoomChecklistInput, "roomId"> {
|
|
14
|
+
name: string;
|
|
15
|
+
}
|
|
16
|
+
export interface ICreateChecklistResponse extends IRoomChecklist {
|
|
4
17
|
}
|
|
5
18
|
export interface ICreateCustomChecklistRequest {
|
|
19
|
+
roomId: string;
|
|
20
|
+
name: string;
|
|
21
|
+
items: ICreateRoomChecklistItemInput[];
|
|
6
22
|
}
|
|
7
|
-
export interface ICreateCustomChecklistResponse {
|
|
23
|
+
export interface ICreateCustomChecklistResponse extends IRoomChecklistWithItems {
|
|
8
24
|
}
|
|
9
|
-
export interface IGetChecklistByRoomIdRequest {
|
|
25
|
+
export interface IGetChecklistByRoomIdRequest extends IRoomChecklistRoomRouteParams {
|
|
10
26
|
}
|
|
11
|
-
export interface IGetChecklistByRoomIdResponse {
|
|
27
|
+
export interface IGetChecklistByRoomIdResponse extends IRoomChecklist {
|
|
12
28
|
}
|
|
13
|
-
export interface IGetChecklistByIdRequest {
|
|
29
|
+
export interface IGetChecklistByIdRequest extends IChecklistIdParams {
|
|
14
30
|
}
|
|
15
|
-
export interface IGetChecklistByIdResponse {
|
|
31
|
+
export interface IGetChecklistByIdResponse extends IRoomChecklist {
|
|
16
32
|
}
|
|
17
|
-
export interface IGetChecklistWithItemsRequest {
|
|
33
|
+
export interface IGetChecklistWithItemsRequest extends IChecklistIdParams {
|
|
18
34
|
}
|
|
19
|
-
export interface IGetChecklistWithItemsResponse {
|
|
35
|
+
export interface IGetChecklistWithItemsResponse extends IRoomChecklistWithItems {
|
|
20
36
|
}
|
|
21
|
-
export interface IUpdateChecklistRequest {
|
|
37
|
+
export interface IUpdateChecklistRequest extends Partial<ICreateRoomChecklistInput> {
|
|
22
38
|
}
|
|
23
|
-
export interface IUpdateChecklistResponse {
|
|
39
|
+
export interface IUpdateChecklistResponse extends IRoomChecklist {
|
|
24
40
|
}
|
|
25
|
-
export interface IDeleteChecklistRequest {
|
|
41
|
+
export interface IDeleteChecklistRequest extends IChecklistIdParams {
|
|
26
42
|
}
|
|
27
|
-
export interface IDeleteChecklistResponse {
|
|
43
|
+
export interface IDeleteChecklistResponse extends IMessageResponse {
|
|
28
44
|
}
|
|
29
45
|
export interface ICloneChecklistRequest {
|
|
46
|
+
targetRoomId: string;
|
|
30
47
|
}
|
|
31
|
-
export interface ICloneChecklistResponse {
|
|
32
|
-
}
|
|
33
|
-
export interface IGetChecklistItemsRequest {
|
|
48
|
+
export interface ICloneChecklistResponse extends IRoomChecklistWithItems {
|
|
34
49
|
}
|
|
35
|
-
export interface
|
|
50
|
+
export interface IGetChecklistItemsRequest extends IChecklistIdParams {
|
|
36
51
|
}
|
|
37
|
-
export
|
|
52
|
+
export type IGetChecklistItemsResponse = IRoomChecklistItem[];
|
|
53
|
+
export interface IGetCustomChecklistItemsRequest extends IChecklistIdParams {
|
|
38
54
|
}
|
|
39
|
-
export
|
|
55
|
+
export type IGetCustomChecklistItemsResponse = IRoomChecklistItem[];
|
|
56
|
+
export interface IAddChecklistItemRequest extends ICreateRoomChecklistItemInput {
|
|
57
|
+
title: string;
|
|
58
|
+
displayOrder: number;
|
|
40
59
|
}
|
|
41
|
-
export interface
|
|
60
|
+
export interface IAddChecklistItemResponse extends IRoomChecklistItem {
|
|
42
61
|
}
|
|
43
|
-
export interface
|
|
62
|
+
export interface IUpdateChecklistItemRequest extends Partial<ICreateRoomChecklistItemInput> {
|
|
44
63
|
}
|
|
45
|
-
export interface
|
|
64
|
+
export interface IUpdateChecklistItemResponse extends IRoomChecklistItem {
|
|
46
65
|
}
|
|
47
|
-
export interface
|
|
66
|
+
export interface IDeleteChecklistItemRequest extends IChecklistAndItemIdParams {
|
|
48
67
|
}
|
|
49
|
-
export interface
|
|
68
|
+
export interface IDeleteChecklistItemResponse extends IMessageResponse {
|
|
50
69
|
}
|
|
51
|
-
export interface
|
|
70
|
+
export interface IChecklistItemOrder {
|
|
71
|
+
itemId: string;
|
|
72
|
+
displayOrder: number;
|
|
52
73
|
}
|
|
53
74
|
export interface IReorderChecklistItemsRequest {
|
|
75
|
+
itemOrders: IChecklistItemOrder[];
|
|
54
76
|
}
|
|
55
|
-
export interface IReorderChecklistItemsResponse {
|
|
77
|
+
export interface IReorderChecklistItemsResponse extends IMessageResponse {
|
|
56
78
|
}
|
|
@@ -26,10 +26,9 @@ export interface IUserSafe extends Omit<IUser, "passwordHash" | "loginAttempts"
|
|
|
26
26
|
}
|
|
27
27
|
export declare const ACCOUNT_TYPE: {
|
|
28
28
|
readonly TURNDOWN_ADMIN: "TURNDOWN_ADMIN";
|
|
29
|
-
readonly PROPERTY_MANAGER: "PROPERTY_MANAGER";
|
|
30
29
|
readonly ACCOUNT_ADMIN: "ACCOUNT_ADMIN";
|
|
31
|
-
readonly
|
|
32
|
-
readonly
|
|
30
|
+
readonly MANAGER: "MANAGER";
|
|
31
|
+
readonly STAFF: "STAFF";
|
|
33
32
|
readonly GUEST: "GUEST";
|
|
34
33
|
};
|
|
35
34
|
export type TAccountType = TRecordValue<typeof ACCOUNT_TYPE>;
|
package/dist/types/user/index.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
export * from "./routes";
|
|
2
2
|
export const ACCOUNT_TYPE = {
|
|
3
3
|
TURNDOWN_ADMIN: "TURNDOWN_ADMIN",
|
|
4
|
-
PROPERTY_MANAGER: "PROPERTY_MANAGER",
|
|
5
4
|
ACCOUNT_ADMIN: "ACCOUNT_ADMIN",
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
MANAGER: "MANAGER",
|
|
6
|
+
STAFF: "STAFF",
|
|
8
7
|
GUEST: "GUEST",
|
|
9
8
|
};
|
|
10
9
|
export const ACCOUNT_STATUS = {
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
import { TLanguage, IUserSafe } from "
|
|
1
|
+
import type { TAccountType, TLanguage, IUserSafe } from ".";
|
|
2
|
+
export interface IUserIdParams {
|
|
3
|
+
id: string;
|
|
4
|
+
}
|
|
2
5
|
export interface IGetUserResponse {
|
|
3
6
|
user: IUserSafe | null;
|
|
4
7
|
}
|
|
@@ -6,8 +9,7 @@ export interface IGetCurrentUserRequest {
|
|
|
6
9
|
}
|
|
7
10
|
export interface IGetCurrentUserResponse extends IGetUserResponse {
|
|
8
11
|
}
|
|
9
|
-
export interface IGetUserByIdRequest {
|
|
10
|
-
userId: string;
|
|
12
|
+
export interface IGetUserByIdRequest extends IUserIdParams {
|
|
11
13
|
}
|
|
12
14
|
export interface IGetUserByIdResponse extends IGetUserResponse {
|
|
13
15
|
}
|
|
@@ -16,6 +18,11 @@ export interface IGetUserByEmailRequest {
|
|
|
16
18
|
}
|
|
17
19
|
export interface IGetUserByEmailResponse extends IGetUserResponse {
|
|
18
20
|
}
|
|
21
|
+
export interface IGetCleanersRequest {
|
|
22
|
+
}
|
|
23
|
+
export interface IGetCleanersResponse {
|
|
24
|
+
cleaners: IUserSafe[];
|
|
25
|
+
}
|
|
19
26
|
export interface IUpdateUserRequest {
|
|
20
27
|
firstName?: string;
|
|
21
28
|
lastName?: string;
|
|
@@ -34,3 +41,6 @@ export interface IDeleteUserRequest {
|
|
|
34
41
|
export interface IDeleteUserResponse {
|
|
35
42
|
message: string;
|
|
36
43
|
}
|
|
44
|
+
export interface IGetUsersByAccountTypeRequest {
|
|
45
|
+
accountType: TAccountType;
|
|
46
|
+
}
|
|
@@ -1,68 +1,89 @@
|
|
|
1
|
-
|
|
1
|
+
import type { IChecklistExecution, IChecklistItemCompletion, ICompleteChecklistItemInput, ICreateWorkSessionInput, IWorkSession, IWorkSessionWithExecutions } from ".";
|
|
2
|
+
export interface IWorkSessionRouteParams {
|
|
3
|
+
sessionId: string;
|
|
2
4
|
}
|
|
3
|
-
export interface
|
|
5
|
+
export interface IWorkSessionPropertyRouteParams {
|
|
6
|
+
propertyId: string;
|
|
4
7
|
}
|
|
5
|
-
export interface
|
|
8
|
+
export interface IWorkSessionUserRouteParams {
|
|
9
|
+
userId: string;
|
|
6
10
|
}
|
|
7
|
-
export interface
|
|
11
|
+
export interface IWorkSessionExecutionRouteParams {
|
|
12
|
+
executionId: string;
|
|
8
13
|
}
|
|
9
|
-
export interface
|
|
14
|
+
export interface ILimitQuery {
|
|
15
|
+
limit?: string;
|
|
10
16
|
}
|
|
11
|
-
export interface
|
|
17
|
+
export interface ICreateWorkSessionRequest extends Omit<ICreateWorkSessionInput, "propertyId"> {
|
|
18
|
+
serviceProviderCompanyId: string;
|
|
19
|
+
performedBy: string;
|
|
12
20
|
}
|
|
13
|
-
export interface
|
|
21
|
+
export interface ICreateWorkSessionResponse extends IWorkSession {
|
|
14
22
|
}
|
|
15
|
-
export interface
|
|
23
|
+
export interface IGetWorkSessionByIdRequest extends IWorkSessionRouteParams {
|
|
16
24
|
}
|
|
17
|
-
export interface
|
|
25
|
+
export interface IGetWorkSessionByIdResponse extends IWorkSession {
|
|
18
26
|
}
|
|
19
|
-
export interface
|
|
27
|
+
export interface IGetWorkSessionWithExecutionsRequest extends IWorkSessionRouteParams {
|
|
20
28
|
}
|
|
21
|
-
export interface
|
|
29
|
+
export interface IGetWorkSessionWithExecutionsResponse extends IWorkSessionWithExecutions {
|
|
22
30
|
}
|
|
23
|
-
export interface
|
|
31
|
+
export interface IUpdateWorkSessionRequest extends Partial<IWorkSession> {
|
|
24
32
|
}
|
|
25
|
-
export interface
|
|
33
|
+
export interface IUpdateWorkSessionResponse extends IWorkSession {
|
|
26
34
|
}
|
|
27
|
-
export interface
|
|
35
|
+
export interface ICompleteWorkSessionRequest extends IWorkSessionRouteParams {
|
|
28
36
|
}
|
|
29
|
-
export interface
|
|
37
|
+
export interface ICompleteWorkSessionResponse extends IWorkSession {
|
|
30
38
|
}
|
|
31
|
-
export interface
|
|
39
|
+
export interface ICancelWorkSessionRequest extends IWorkSessionRouteParams {
|
|
32
40
|
}
|
|
33
|
-
export interface
|
|
41
|
+
export interface ICancelWorkSessionResponse extends IWorkSession {
|
|
34
42
|
}
|
|
35
|
-
export interface
|
|
43
|
+
export interface IGetWorkSessionsByPropertyIdRequest extends IWorkSessionPropertyRouteParams {
|
|
36
44
|
}
|
|
37
|
-
export
|
|
45
|
+
export type IGetWorkSessionsByPropertyIdResponse = IWorkSession[];
|
|
46
|
+
export interface IGetActiveWorkSessionRequest extends IWorkSessionPropertyRouteParams {
|
|
38
47
|
}
|
|
39
|
-
export interface
|
|
48
|
+
export interface IGetActiveWorkSessionResponse extends IWorkSession {
|
|
40
49
|
}
|
|
41
|
-
export interface
|
|
50
|
+
export interface IGetWorkSessionsByUserIdRequest extends IWorkSessionUserRouteParams {
|
|
42
51
|
}
|
|
43
|
-
export
|
|
52
|
+
export type IGetWorkSessionsByUserIdResponse = IWorkSession[];
|
|
53
|
+
export interface IGetChecklistExecutionsRequest extends IWorkSessionRouteParams {
|
|
44
54
|
}
|
|
45
|
-
export
|
|
55
|
+
export type IGetChecklistExecutionsResponse = IChecklistExecution[];
|
|
56
|
+
export interface IGetChecklistExecutionByIdRequest extends IWorkSessionExecutionRouteParams {
|
|
46
57
|
}
|
|
47
|
-
export interface
|
|
58
|
+
export interface IGetChecklistExecutionByIdResponse extends IChecklistExecution {
|
|
59
|
+
}
|
|
60
|
+
export interface IStartChecklistExecutionRequest extends IWorkSessionExecutionRouteParams {
|
|
61
|
+
}
|
|
62
|
+
export interface IStartChecklistExecutionResponse extends IChecklistExecution {
|
|
48
63
|
}
|
|
49
64
|
export interface ICompleteChecklistExecutionRequest {
|
|
65
|
+
notes?: string;
|
|
50
66
|
}
|
|
51
|
-
export interface ICompleteChecklistExecutionResponse {
|
|
67
|
+
export interface ICompleteChecklistExecutionResponse extends IChecklistExecution {
|
|
52
68
|
}
|
|
53
69
|
export interface ISkipChecklistExecutionRequest {
|
|
70
|
+
notes?: string;
|
|
54
71
|
}
|
|
55
|
-
export interface ISkipChecklistExecutionResponse {
|
|
72
|
+
export interface ISkipChecklistExecutionResponse extends IChecklistExecution {
|
|
56
73
|
}
|
|
57
|
-
export interface IGetExecutionProgressRequest {
|
|
74
|
+
export interface IGetExecutionProgressRequest extends IWorkSessionExecutionRouteParams {
|
|
58
75
|
}
|
|
59
76
|
export interface IGetExecutionProgressResponse {
|
|
77
|
+
totalItems: number;
|
|
78
|
+
completedItems: number;
|
|
79
|
+
skippedItems: number;
|
|
80
|
+
progressPercentage: number;
|
|
60
81
|
}
|
|
61
|
-
export interface IGetExecutionItemsRequest {
|
|
62
|
-
}
|
|
63
|
-
export interface IGetExecutionItemsResponse {
|
|
82
|
+
export interface IGetExecutionItemsRequest extends IWorkSessionExecutionRouteParams {
|
|
64
83
|
}
|
|
65
|
-
export
|
|
84
|
+
export type IGetExecutionItemsResponse = IChecklistItemCompletion[];
|
|
85
|
+
export interface ICompleteExecutionItemRequest extends ICompleteChecklistItemInput {
|
|
86
|
+
roomChecklistItemId: string;
|
|
66
87
|
}
|
|
67
|
-
export interface ICompleteExecutionItemResponse {
|
|
88
|
+
export interface ICompleteExecutionItemResponse extends IChecklistItemCompletion {
|
|
68
89
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@turndown/library",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.23",
|
|
4
4
|
"description": "Shared TypeScript library for the Turndown suite.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"types",
|
|
@@ -34,13 +34,14 @@
|
|
|
34
34
|
"clean": "rimraf dist",
|
|
35
35
|
"build": "npm run clean && tsc -p .",
|
|
36
36
|
"dev": "tsc -w -p .",
|
|
37
|
+
"format": "prettier --write .",
|
|
37
38
|
"test": "jest",
|
|
38
39
|
"test:watch": "jest --watch",
|
|
39
40
|
"test:coverage": "jest --coverage"
|
|
40
41
|
},
|
|
41
42
|
"devDependencies": {
|
|
42
43
|
"@types/jest": "^30.0.0",
|
|
43
|
-
"@types/node": "^24.
|
|
44
|
+
"@types/node": "^24.12.4",
|
|
44
45
|
"jest": "^30.4.2",
|
|
45
46
|
"rimraf": "^6.0.1",
|
|
46
47
|
"ts-jest": "^29.4.9",
|