@mydoormot/app-types 1.7.30 → 1.7.32

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.
@@ -1,5 +1,5 @@
1
1
 
2
- > @mydoormot/app-types@1.7.29 build /Users/chuksben/Desktop/projects/microservices/mydoormot/packages/app-types
2
+ > @mydoormot/app-types@1.7.31 build /Users/chuksben/Desktop/projects/microservices/mydoormot/packages/app-types
3
3
  > tsup src/index.ts --format esm,cjs --dts
4
4
 
5
5
  CLI Building entry: src/index.ts
@@ -9,10 +9,10 @@
9
9
  ESM Build start
10
10
  CJS Build start
11
11
  ESM dist/index.js 7.15 KB
12
- ESM ⚡️ Build success in 61ms
12
+ ESM ⚡️ Build success in 64ms
13
13
  CJS dist/index.cjs 9.00 KB
14
- CJS ⚡️ Build success in 62ms
14
+ CJS ⚡️ Build success in 65ms
15
15
  DTS Build start
16
- DTS ⚡️ Build success in 846ms
17
- DTS dist/index.d.ts 28.00 KB
18
- DTS dist/index.d.cts 28.00 KB
16
+ DTS ⚡️ Build success in 685ms
17
+ DTS dist/index.d.ts 28.01 KB
18
+ DTS dist/index.d.cts 28.01 KB
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @mydoormot/app-types
2
2
 
3
+ ## 1.7.32
4
+
5
+ ### Patch Changes
6
+
7
+ - Modified app types
8
+
9
+ ## 1.7.31
10
+
11
+ ### Patch Changes
12
+
13
+ - Modified errand app types
14
+
3
15
  ## 1.7.30
4
16
 
5
17
  ### Patch Changes
package/dist/index.d.cts CHANGED
@@ -72,7 +72,6 @@ type User = {
72
72
  accountType?: 'business' | 'personal';
73
73
  hasOnboarded?: boolean;
74
74
  lastActivity?: string;
75
- isManaged?: boolean;
76
75
  lastLoggedInBusinessId?: string;
77
76
  globalRole: GlobalRoles | `${GlobalRoles}`;
78
77
  isActive?: boolean;
@@ -180,6 +179,84 @@ interface InvoiceItem {
180
179
  itemDetails?: Errand;
181
180
  }
182
181
 
182
+ declare enum BusinessCapability {
183
+ SELF_FULFILLMENT = "self_fulfillment"
184
+ }
185
+ interface Business {
186
+ id: string;
187
+ userId: string;
188
+ name: string;
189
+ description: string;
190
+ officeNumber: string;
191
+ categoryId: string;
192
+ address: string | NullOrUndefined;
193
+ addressCoordinates: number[] | NullOrUndefined | {
194
+ x: number;
195
+ y: number;
196
+ };
197
+ loggedIn: boolean | NullOrUndefined;
198
+ slug: string;
199
+ verified: boolean | NullOrUndefined;
200
+ isVirtual: boolean | NullOrUndefined;
201
+ registrationCompleted: boolean | NullOrUndefined;
202
+ stateId: string | NullOrUndefined;
203
+ cityId: string | NullOrUndefined;
204
+ originalLogoUrl: string | NullOrUndefined;
205
+ logoUrl: string | NullOrUndefined;
206
+ logoBlurHash: string | NullOrUndefined;
207
+ coverImageUrl: string | NullOrUndefined;
208
+ orginalCoverImageUrl: string | NullOrUndefined;
209
+ coverImageBlurHash: string | NullOrUndefined;
210
+ createdAt: string | Date;
211
+ updatedAt: string | NullOrUndefined | Date;
212
+ verifiedAt: string | NullOrUndefined | Date;
213
+ registrationCompletedAt: string | NullOrUndefined | Date;
214
+ businessCategoryDetails: BusinessCategory | NullOrUndefined;
215
+ capabilities: BusinessCapability[] | NullOrUndefined;
216
+ }
217
+ interface BusinessPg extends Business {
218
+ pgId: any;
219
+ }
220
+ interface BusinessCategory {
221
+ id: string;
222
+ seqId: number;
223
+ name: string;
224
+ slug: string;
225
+ createdAt: string;
226
+ updatedAt: string;
227
+ }
228
+ interface Vendor {
229
+ id: string;
230
+ name: string;
231
+ handle: string;
232
+ businessId: string;
233
+ logo?: string;
234
+ }
235
+ declare enum BusinessRole {
236
+ OWNER = "OWNER",
237
+ MANAGER = "MANAGER",
238
+ RIDER = "RIDER",
239
+ STAFF = "STAFF"
240
+ }
241
+ declare enum MembershipStatus {
242
+ ACTIVE = "ACTIVE",
243
+ PENDING_ACTIVATION = "PENDING_ACTIVATION",
244
+ SUSPENDED = "SUSPENDED"
245
+ }
246
+ interface BusinessMember {
247
+ id: string;
248
+ userId: string;
249
+ businessId: string;
250
+ pgId: string;
251
+ role: BusinessRole | `${BusinessRole}`;
252
+ status: MembershipStatus | `${MembershipStatus}`;
253
+ invitedBy: string | NullOrUndefined;
254
+ userDetails: User | NullOrUndefined;
255
+ invitedByUserDetails: User | NullOrUndefined;
256
+ createdAt: string;
257
+ updatedAt: string | NullOrUndefined;
258
+ }
259
+
183
260
  declare enum VehicleType {
184
261
  Bike = "bike",
185
262
  Shuttle = "shuttle"
@@ -281,6 +358,7 @@ type Rider = {
281
358
  };
282
359
  type RiderWithUserDetails = Rider & {
283
360
  userDetails?: User;
361
+ businessMemberDetails?: BusinessMember;
284
362
  };
285
363
  declare enum RemittanceStatus {
286
364
  Pending = "pending",
@@ -443,6 +521,7 @@ interface Errand {
443
521
  userDetails?: User;
444
522
  courierBusinessDetails?: Business;
445
523
  riderDetails?: Rider;
524
+ vehicleDetails?: Vehicle;
446
525
  }
447
526
  interface AggregatedErrand extends Errand {
448
527
  parcelSize: `${ParcelSize}`;
@@ -637,85 +716,6 @@ interface EnterpriseSubCategoryDoc {
637
716
  createdAt: string;
638
717
  }
639
718
 
640
- declare enum BusinessCapability {
641
- SELF_FULFILLMENT = "self_fulfillment"
642
- }
643
- interface Business {
644
- id: string;
645
- userId: string;
646
- name: string;
647
- description: string;
648
- officeNumber: string;
649
- categoryId: string;
650
- address: string | NullOrUndefined;
651
- addressCoordinates: number[] | NullOrUndefined | {
652
- x: number;
653
- y: number;
654
- };
655
- loggedIn: boolean | NullOrUndefined;
656
- slug: string;
657
- verified: boolean | NullOrUndefined;
658
- isVirtual: boolean | NullOrUndefined;
659
- registrationCompleted: boolean | NullOrUndefined;
660
- stateId: string | NullOrUndefined;
661
- cityId: string | NullOrUndefined;
662
- originalLogoUrl: string | NullOrUndefined;
663
- logoUrl: string | NullOrUndefined;
664
- logoBlurHash: string | NullOrUndefined;
665
- coverImageUrl: string | NullOrUndefined;
666
- orginalCoverImageUrl: string | NullOrUndefined;
667
- coverImageBlurHash: string | NullOrUndefined;
668
- createdAt: string | Date;
669
- updatedAt: string | NullOrUndefined | Date;
670
- verifiedAt: string | NullOrUndefined | Date;
671
- registrationCompletedAt: string | NullOrUndefined | Date;
672
- isManaged: boolean | NullOrUndefined;
673
- businessCategoryDetails: BusinessCategory | NullOrUndefined;
674
- capabilities: BusinessCapability[] | NullOrUndefined;
675
- }
676
- interface BusinessPg extends Business {
677
- pgId: any;
678
- }
679
- interface BusinessCategory {
680
- id: string;
681
- seqId: number;
682
- name: string;
683
- slug: string;
684
- createdAt: string;
685
- updatedAt: string;
686
- }
687
- interface Vendor {
688
- id: string;
689
- name: string;
690
- handle: string;
691
- businessId: string;
692
- logo?: string;
693
- }
694
- declare enum BusinessRole {
695
- OWNER = "OWNER",
696
- MANAGER = "MANAGER",
697
- RIDER = "RIDER",
698
- STAFF = "STAFF"
699
- }
700
- declare enum MembershipStatus {
701
- ACTIVE = "ACTIVE",
702
- PENDING_ACTIVATION = "PENDING_ACTIVATION",
703
- SUSPENDED = "SUSPENDED"
704
- }
705
- interface BusinessMember {
706
- id: string;
707
- userId: string;
708
- businessId: string;
709
- pgId: string;
710
- role: BusinessRole | `${BusinessRole}`;
711
- status: MembershipStatus | `${MembershipStatus}`;
712
- invitedBy: string | NullOrUndefined;
713
- userDetails: User | NullOrUndefined;
714
- invitedByUserDetails: User | NullOrUndefined;
715
- createdAt: string;
716
- updatedAt: string | NullOrUndefined;
717
- }
718
-
719
719
  type ProductStatus = 'draft' | 'proposed' | 'published' | 'rejected';
720
720
  interface ProductImage {
721
721
  id: string;
package/dist/index.d.ts CHANGED
@@ -72,7 +72,6 @@ type User = {
72
72
  accountType?: 'business' | 'personal';
73
73
  hasOnboarded?: boolean;
74
74
  lastActivity?: string;
75
- isManaged?: boolean;
76
75
  lastLoggedInBusinessId?: string;
77
76
  globalRole: GlobalRoles | `${GlobalRoles}`;
78
77
  isActive?: boolean;
@@ -180,6 +179,84 @@ interface InvoiceItem {
180
179
  itemDetails?: Errand;
181
180
  }
182
181
 
182
+ declare enum BusinessCapability {
183
+ SELF_FULFILLMENT = "self_fulfillment"
184
+ }
185
+ interface Business {
186
+ id: string;
187
+ userId: string;
188
+ name: string;
189
+ description: string;
190
+ officeNumber: string;
191
+ categoryId: string;
192
+ address: string | NullOrUndefined;
193
+ addressCoordinates: number[] | NullOrUndefined | {
194
+ x: number;
195
+ y: number;
196
+ };
197
+ loggedIn: boolean | NullOrUndefined;
198
+ slug: string;
199
+ verified: boolean | NullOrUndefined;
200
+ isVirtual: boolean | NullOrUndefined;
201
+ registrationCompleted: boolean | NullOrUndefined;
202
+ stateId: string | NullOrUndefined;
203
+ cityId: string | NullOrUndefined;
204
+ originalLogoUrl: string | NullOrUndefined;
205
+ logoUrl: string | NullOrUndefined;
206
+ logoBlurHash: string | NullOrUndefined;
207
+ coverImageUrl: string | NullOrUndefined;
208
+ orginalCoverImageUrl: string | NullOrUndefined;
209
+ coverImageBlurHash: string | NullOrUndefined;
210
+ createdAt: string | Date;
211
+ updatedAt: string | NullOrUndefined | Date;
212
+ verifiedAt: string | NullOrUndefined | Date;
213
+ registrationCompletedAt: string | NullOrUndefined | Date;
214
+ businessCategoryDetails: BusinessCategory | NullOrUndefined;
215
+ capabilities: BusinessCapability[] | NullOrUndefined;
216
+ }
217
+ interface BusinessPg extends Business {
218
+ pgId: any;
219
+ }
220
+ interface BusinessCategory {
221
+ id: string;
222
+ seqId: number;
223
+ name: string;
224
+ slug: string;
225
+ createdAt: string;
226
+ updatedAt: string;
227
+ }
228
+ interface Vendor {
229
+ id: string;
230
+ name: string;
231
+ handle: string;
232
+ businessId: string;
233
+ logo?: string;
234
+ }
235
+ declare enum BusinessRole {
236
+ OWNER = "OWNER",
237
+ MANAGER = "MANAGER",
238
+ RIDER = "RIDER",
239
+ STAFF = "STAFF"
240
+ }
241
+ declare enum MembershipStatus {
242
+ ACTIVE = "ACTIVE",
243
+ PENDING_ACTIVATION = "PENDING_ACTIVATION",
244
+ SUSPENDED = "SUSPENDED"
245
+ }
246
+ interface BusinessMember {
247
+ id: string;
248
+ userId: string;
249
+ businessId: string;
250
+ pgId: string;
251
+ role: BusinessRole | `${BusinessRole}`;
252
+ status: MembershipStatus | `${MembershipStatus}`;
253
+ invitedBy: string | NullOrUndefined;
254
+ userDetails: User | NullOrUndefined;
255
+ invitedByUserDetails: User | NullOrUndefined;
256
+ createdAt: string;
257
+ updatedAt: string | NullOrUndefined;
258
+ }
259
+
183
260
  declare enum VehicleType {
184
261
  Bike = "bike",
185
262
  Shuttle = "shuttle"
@@ -281,6 +358,7 @@ type Rider = {
281
358
  };
282
359
  type RiderWithUserDetails = Rider & {
283
360
  userDetails?: User;
361
+ businessMemberDetails?: BusinessMember;
284
362
  };
285
363
  declare enum RemittanceStatus {
286
364
  Pending = "pending",
@@ -443,6 +521,7 @@ interface Errand {
443
521
  userDetails?: User;
444
522
  courierBusinessDetails?: Business;
445
523
  riderDetails?: Rider;
524
+ vehicleDetails?: Vehicle;
446
525
  }
447
526
  interface AggregatedErrand extends Errand {
448
527
  parcelSize: `${ParcelSize}`;
@@ -637,85 +716,6 @@ interface EnterpriseSubCategoryDoc {
637
716
  createdAt: string;
638
717
  }
639
718
 
640
- declare enum BusinessCapability {
641
- SELF_FULFILLMENT = "self_fulfillment"
642
- }
643
- interface Business {
644
- id: string;
645
- userId: string;
646
- name: string;
647
- description: string;
648
- officeNumber: string;
649
- categoryId: string;
650
- address: string | NullOrUndefined;
651
- addressCoordinates: number[] | NullOrUndefined | {
652
- x: number;
653
- y: number;
654
- };
655
- loggedIn: boolean | NullOrUndefined;
656
- slug: string;
657
- verified: boolean | NullOrUndefined;
658
- isVirtual: boolean | NullOrUndefined;
659
- registrationCompleted: boolean | NullOrUndefined;
660
- stateId: string | NullOrUndefined;
661
- cityId: string | NullOrUndefined;
662
- originalLogoUrl: string | NullOrUndefined;
663
- logoUrl: string | NullOrUndefined;
664
- logoBlurHash: string | NullOrUndefined;
665
- coverImageUrl: string | NullOrUndefined;
666
- orginalCoverImageUrl: string | NullOrUndefined;
667
- coverImageBlurHash: string | NullOrUndefined;
668
- createdAt: string | Date;
669
- updatedAt: string | NullOrUndefined | Date;
670
- verifiedAt: string | NullOrUndefined | Date;
671
- registrationCompletedAt: string | NullOrUndefined | Date;
672
- isManaged: boolean | NullOrUndefined;
673
- businessCategoryDetails: BusinessCategory | NullOrUndefined;
674
- capabilities: BusinessCapability[] | NullOrUndefined;
675
- }
676
- interface BusinessPg extends Business {
677
- pgId: any;
678
- }
679
- interface BusinessCategory {
680
- id: string;
681
- seqId: number;
682
- name: string;
683
- slug: string;
684
- createdAt: string;
685
- updatedAt: string;
686
- }
687
- interface Vendor {
688
- id: string;
689
- name: string;
690
- handle: string;
691
- businessId: string;
692
- logo?: string;
693
- }
694
- declare enum BusinessRole {
695
- OWNER = "OWNER",
696
- MANAGER = "MANAGER",
697
- RIDER = "RIDER",
698
- STAFF = "STAFF"
699
- }
700
- declare enum MembershipStatus {
701
- ACTIVE = "ACTIVE",
702
- PENDING_ACTIVATION = "PENDING_ACTIVATION",
703
- SUSPENDED = "SUSPENDED"
704
- }
705
- interface BusinessMember {
706
- id: string;
707
- userId: string;
708
- businessId: string;
709
- pgId: string;
710
- role: BusinessRole | `${BusinessRole}`;
711
- status: MembershipStatus | `${MembershipStatus}`;
712
- invitedBy: string | NullOrUndefined;
713
- userDetails: User | NullOrUndefined;
714
- invitedByUserDetails: User | NullOrUndefined;
715
- createdAt: string;
716
- updatedAt: string | NullOrUndefined;
717
- }
718
-
719
719
  type ProductStatus = 'draft' | 'proposed' | 'published' | 'rejected';
720
720
  interface ProductImage {
721
721
  id: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mydoormot/app-types",
3
- "version": "1.7.30",
3
+ "version": "1.7.32",
4
4
  "description": "",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.js",
package/src/business.ts CHANGED
@@ -40,7 +40,6 @@ export interface Business {
40
40
  updatedAt: string | NullOrUndefined | Date;
41
41
  verifiedAt: string | NullOrUndefined | Date;
42
42
  registrationCompletedAt: string | NullOrUndefined | Date;
43
- isManaged: boolean | NullOrUndefined;
44
43
  businessCategoryDetails: BusinessCategory | NullOrUndefined;
45
44
  capabilities: BusinessCapability[] | NullOrUndefined;
46
45
  }
package/src/errand.ts CHANGED
@@ -4,6 +4,7 @@ import { Invoice, InvoiceStatus } from './invoice';
4
4
  import { City } from './location';
5
5
  import { Rider } from './rider';
6
6
  import { User } from './user';
7
+ import { Vehicle } from './vehicle';
7
8
 
8
9
  export enum ErrandStatus {
9
10
  Pending = 'pending',
@@ -163,7 +164,7 @@ export interface Errand {
163
164
 
164
165
  // new fields
165
166
  riderDetails?: Rider;
166
- // vehicleDetails?: Vehicle;
167
+ vehicleDetails?: Vehicle;
167
168
  }
168
169
 
169
170
  export interface AggregatedErrand extends Errand {
package/src/rider.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  // import { Enterprise } from './enterprise';
2
+ import { BusinessMember } from './business';
2
3
  import { Errand } from './errand';
3
4
  import { State } from './location';
4
5
  import { User } from './user';
@@ -35,6 +36,7 @@ export type Rider = {
35
36
 
36
37
  export type RiderWithUserDetails = Rider & {
37
38
  userDetails?: User;
39
+ businessMemberDetails?: BusinessMember;
38
40
  };
39
41
 
40
42
  // Rider Settlement Types
package/src/user.ts CHANGED
@@ -44,7 +44,6 @@ export type User = {
44
44
  accountType?: 'business' | 'personal';
45
45
  hasOnboarded?: boolean;
46
46
  lastActivity?: string;
47
- isManaged?: boolean;
48
47
  lastLoggedInBusinessId?: string;
49
48
  globalRole: GlobalRoles | `${GlobalRoles}`;
50
49
  isActive?: boolean;