@mydoormot/app-types 1.5.9 → 1.6.0

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.5.8 build /Users/chuksben/Desktop/projects/microservices/mydoormot/packages/app-types
2
+ > @mydoormot/app-types@1.5.9 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
@@ -8,11 +8,11 @@
8
8
  CLI Target: es2021
9
9
  ESM Build start
10
10
  CJS Build start
11
- CJS dist/index.cjs 6.93 KB
12
- CJS ⚡️ Build success in 184ms
13
11
  ESM dist/index.js 5.37 KB
14
- ESM ⚡️ Build success in 185ms
12
+ ESM ⚡️ Build success in 153ms
13
+ CJS dist/index.cjs 6.93 KB
14
+ CJS ⚡️ Build success in 153ms
15
15
  DTS Build start
16
- DTS ⚡️ Build success in 703ms
17
- DTS dist/index.d.ts 14.89 KB
18
- DTS dist/index.d.cts 14.89 KB
16
+ DTS ⚡️ Build success in 999ms
17
+ DTS dist/index.d.ts 15.43 KB
18
+ DTS dist/index.d.cts 15.43 KB
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @mydoormot/app-types
2
2
 
3
+ ## 1.6.0
4
+
5
+ ### Minor Changes
6
+
7
+ - Added stats
8
+
3
9
  ## 1.5.9
4
10
 
5
11
  ### Patch Changes
package/dist/index.d.cts CHANGED
@@ -277,6 +277,26 @@ type VehicleLogWithRiderAndErrands = VehicleLogWithErrands & {
277
277
  riderDetails: Rider | null;
278
278
  riderUserDetails: User | null;
279
279
  };
280
+ interface RiderStats {
281
+ totalErrands: number;
282
+ totalFuelCost: number;
283
+ numberOfRefills: number;
284
+ numberOfVehicles: number;
285
+ riderBreakdown: {
286
+ errandsPercentage: number;
287
+ fuelCostPercentage: number;
288
+ numberOfRefills: number;
289
+ numberOfVehicles: number;
290
+ riderEmail: string;
291
+ riderId: string;
292
+ riderName: string | null;
293
+ riderPhone: string;
294
+ totalErrands: number;
295
+ totalFuelCost: number;
296
+ totalFuelLiters: number;
297
+ _id: string;
298
+ }[];
299
+ }
280
300
 
281
301
  declare enum ErrandStatus {
282
302
  Pending = "pending",
@@ -603,4 +623,4 @@ declare enum LinkDestination {
603
623
  }
604
624
  type NullOrUndefined = null | undefined;
605
625
 
606
- export { type AddressDetails, AddressTypes, type AggregatedErrand, AuthType, type Business, type BusinessCategory, type BusinessPg, type City, type Coupon, type Customer, DeliveryStatus, type Enterprise, type EnterpriseCategoryDoc, type EnterpriseSubCategoryDoc, EnterpriseType, type Errand, type ErrandRating, ErrandStatus, type ErrandTimeline, type Invoice, InvoiceGenerationType, type InvoiceItem, InvoiceItemType, InvoiceStatus, type LatLng, LinkDestination, type Notification, type NotificationData, NotificationType, type NullOrUndefined, type PaginateResult, ParcelSize, PaymentOptions, type PendingErrand, type Rider, RoleType, type State, type Transaction, type TransactionCategory, type TransactionType, type TransactionWithCategory, type TransactionWithJoin, type User, type UserAddress, type Vehicle, type VehicleLog, VehicleLogType, type VehicleLogWithErrands, type VehicleLogWithRiderAndErrands, VehicleType, type VehicleWithRider, errandTimeline };
626
+ export { type AddressDetails, AddressTypes, type AggregatedErrand, AuthType, type Business, type BusinessCategory, type BusinessPg, type City, type Coupon, type Customer, DeliveryStatus, type Enterprise, type EnterpriseCategoryDoc, type EnterpriseSubCategoryDoc, EnterpriseType, type Errand, type ErrandRating, ErrandStatus, type ErrandTimeline, type Invoice, InvoiceGenerationType, type InvoiceItem, InvoiceItemType, InvoiceStatus, type LatLng, LinkDestination, type Notification, type NotificationData, NotificationType, type NullOrUndefined, type PaginateResult, ParcelSize, PaymentOptions, type PendingErrand, type Rider, type RiderStats, RoleType, type State, type Transaction, type TransactionCategory, type TransactionType, type TransactionWithCategory, type TransactionWithJoin, type User, type UserAddress, type Vehicle, type VehicleLog, VehicleLogType, type VehicleLogWithErrands, type VehicleLogWithRiderAndErrands, VehicleType, type VehicleWithRider, errandTimeline };
package/dist/index.d.ts CHANGED
@@ -277,6 +277,26 @@ type VehicleLogWithRiderAndErrands = VehicleLogWithErrands & {
277
277
  riderDetails: Rider | null;
278
278
  riderUserDetails: User | null;
279
279
  };
280
+ interface RiderStats {
281
+ totalErrands: number;
282
+ totalFuelCost: number;
283
+ numberOfRefills: number;
284
+ numberOfVehicles: number;
285
+ riderBreakdown: {
286
+ errandsPercentage: number;
287
+ fuelCostPercentage: number;
288
+ numberOfRefills: number;
289
+ numberOfVehicles: number;
290
+ riderEmail: string;
291
+ riderId: string;
292
+ riderName: string | null;
293
+ riderPhone: string;
294
+ totalErrands: number;
295
+ totalFuelCost: number;
296
+ totalFuelLiters: number;
297
+ _id: string;
298
+ }[];
299
+ }
280
300
 
281
301
  declare enum ErrandStatus {
282
302
  Pending = "pending",
@@ -603,4 +623,4 @@ declare enum LinkDestination {
603
623
  }
604
624
  type NullOrUndefined = null | undefined;
605
625
 
606
- export { type AddressDetails, AddressTypes, type AggregatedErrand, AuthType, type Business, type BusinessCategory, type BusinessPg, type City, type Coupon, type Customer, DeliveryStatus, type Enterprise, type EnterpriseCategoryDoc, type EnterpriseSubCategoryDoc, EnterpriseType, type Errand, type ErrandRating, ErrandStatus, type ErrandTimeline, type Invoice, InvoiceGenerationType, type InvoiceItem, InvoiceItemType, InvoiceStatus, type LatLng, LinkDestination, type Notification, type NotificationData, NotificationType, type NullOrUndefined, type PaginateResult, ParcelSize, PaymentOptions, type PendingErrand, type Rider, RoleType, type State, type Transaction, type TransactionCategory, type TransactionType, type TransactionWithCategory, type TransactionWithJoin, type User, type UserAddress, type Vehicle, type VehicleLog, VehicleLogType, type VehicleLogWithErrands, type VehicleLogWithRiderAndErrands, VehicleType, type VehicleWithRider, errandTimeline };
626
+ export { type AddressDetails, AddressTypes, type AggregatedErrand, AuthType, type Business, type BusinessCategory, type BusinessPg, type City, type Coupon, type Customer, DeliveryStatus, type Enterprise, type EnterpriseCategoryDoc, type EnterpriseSubCategoryDoc, EnterpriseType, type Errand, type ErrandRating, ErrandStatus, type ErrandTimeline, type Invoice, InvoiceGenerationType, type InvoiceItem, InvoiceItemType, InvoiceStatus, type LatLng, LinkDestination, type Notification, type NotificationData, NotificationType, type NullOrUndefined, type PaginateResult, ParcelSize, PaymentOptions, type PendingErrand, type Rider, type RiderStats, RoleType, type State, type Transaction, type TransactionCategory, type TransactionType, type TransactionWithCategory, type TransactionWithJoin, type User, type UserAddress, type Vehicle, type VehicleLog, VehicleLogType, type VehicleLogWithErrands, type VehicleLogWithRiderAndErrands, VehicleType, type VehicleWithRider, errandTimeline };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mydoormot/app-types",
3
- "version": "1.5.9",
3
+ "version": "1.6.0",
4
4
  "description": "",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.js",
package/src/rider.ts CHANGED
@@ -80,3 +80,24 @@ export type VehicleLogWithRiderAndErrands = VehicleLogWithErrands & {
80
80
  riderDetails: Rider | null;
81
81
  riderUserDetails: User | null;
82
82
  };
83
+
84
+ export interface RiderStats {
85
+ totalErrands: number;
86
+ totalFuelCost: number;
87
+ numberOfRefills: number;
88
+ numberOfVehicles: number;
89
+ riderBreakdown: {
90
+ errandsPercentage: number;
91
+ fuelCostPercentage: number;
92
+ numberOfRefills: number;
93
+ numberOfVehicles: number;
94
+ riderEmail: string;
95
+ riderId: string;
96
+ riderName: string | null;
97
+ riderPhone: string;
98
+ totalErrands: number;
99
+ totalFuelCost: number;
100
+ totalFuelLiters: number;
101
+ _id: string;
102
+ }[];
103
+ }