@bizmap/sdk 0.0.124 → 0.0.125

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/main.d.ts CHANGED
@@ -26,11 +26,11 @@ declare const healthcareProviderRoles: z.ZodEnum<{
26
26
  physAsst: "physAsst";
27
27
  }>;
28
28
  type HealthcareProviderRole = z.infer<typeof healthcareProviderRoles>;
29
- declare const taskDistAlgs: z.ZodEnum<{
29
+ declare const serviceDistAlgs: z.ZodEnum<{
30
30
  RR: "RR";
31
31
  LOR: "LOR";
32
32
  }>;
33
- type TaskDistAlg = z.infer<typeof taskDistAlgs>;
33
+ type ServiceDistAlg = z.infer<typeof serviceDistAlgs>;
34
34
  declare const companyServiceSelectors: z.ZodEnum<{
35
35
  scheduler: "scheduler";
36
36
  doctor: "doctor";
@@ -122,11 +122,11 @@ declare const CompanyDetails: z.ZodObject<{
122
122
  scheduler: "scheduler";
123
123
  doctor: "doctor";
124
124
  }>;
125
- taskDistAlg: z.ZodEnum<{
125
+ serviceDistAlg: z.ZodEnum<{
126
126
  RR: "RR";
127
127
  LOR: "LOR";
128
128
  }>;
129
- ppt: z.ZodBoolean;
129
+ pps: z.ZodBoolean;
130
130
  servicesDeployed: z.ZodBoolean;
131
131
  }, z.core.$strip>;
132
132
  billing: z.ZodObject<{
@@ -196,7 +196,7 @@ declare const CompanyDetails: z.ZodObject<{
196
196
  "a/r": "a/r";
197
197
  ceo: "ceo";
198
198
  }>>, z.ZodTransform<("doc" | "physAsst" | "rcpst" | "cshr" | "a/r" | "ceo")[], ("doc" | "physAsst" | "rcpst" | "cshr" | "a/r" | "ceo")[]>>;
199
- dailyTaskCounter: z.ZodOptional<z.ZodRecord<z.ZodLiteral<"undone" | "done">, z.ZodInt>>;
199
+ dailyServiceCounter: z.ZodOptional<z.ZodRecord<z.ZodLiteral<"undone" | "done">, z.ZodInt>>;
200
200
  }, z.core.$strip>>;
201
201
  partnerMap: z.ZodOptional<z.ZodRecord<z.ZodUUID, z.ZodRecord<z.ZodUUID, z.ZodObject<{
202
202
  addedAt: z.ZodISODateTime;
@@ -238,11 +238,11 @@ declare const MutableCompanyDetails: z.ZodObject<{
238
238
  scheduler: "scheduler";
239
239
  doctor: "doctor";
240
240
  }>>;
241
- taskDistAlg: z.ZodOptional<z.ZodEnum<{
241
+ serviceDistAlg: z.ZodOptional<z.ZodEnum<{
242
242
  RR: "RR";
243
243
  LOR: "LOR";
244
244
  }>>;
245
- ppt: z.ZodOptional<z.ZodBoolean>;
245
+ pps: z.ZodOptional<z.ZodBoolean>;
246
246
  servicesDeployed: z.ZodOptional<z.ZodBoolean>;
247
247
  }, z.core.$strip>>;
248
248
  billing: z.ZodOptional<z.ZodObject<{
@@ -492,8 +492,8 @@ declare const CompanyPreferences: z.ZodObject<{
492
492
  scheduler: "scheduler";
493
493
  doctor: "doctor";
494
494
  }>;
495
- ppt: z.ZodBoolean;
496
- taskDistAlg: z.ZodEnum<{
495
+ pps: z.ZodBoolean;
496
+ serviceDistAlg: z.ZodEnum<{
497
497
  RR: "RR";
498
498
  LOR: "LOR";
499
499
  }>;
@@ -506,11 +506,11 @@ declare const MutableCompanyPreferences: z.ZodObject<{
506
506
  scheduler: "scheduler";
507
507
  doctor: "doctor";
508
508
  }>;
509
- taskDistAlg: z.ZodEnum<{
509
+ serviceDistAlg: z.ZodEnum<{
510
510
  RR: "RR";
511
511
  LOR: "LOR";
512
512
  }>;
513
- ppt: z.ZodBoolean;
513
+ pps: z.ZodBoolean;
514
514
  servicesDeployed: z.ZodBoolean;
515
515
  }, z.core.$strip>;
516
516
  type MutableCompanyPreferences = z.infer<typeof MutableCompanyPreferences>;
@@ -531,7 +531,7 @@ declare const CompanyStaff: z.ZodObject<{
531
531
  "a/r": "a/r";
532
532
  ceo: "ceo";
533
533
  }>>, z.ZodTransform<("doc" | "physAsst" | "rcpst" | "cshr" | "a/r" | "ceo")[], ("doc" | "physAsst" | "rcpst" | "cshr" | "a/r" | "ceo")[]>>;
534
- dailyTaskCounter: z.ZodOptional<z.ZodRecord<z.ZodLiteral<"undone" | "done">, z.ZodInt>>;
534
+ dailyServiceCounter: z.ZodOptional<z.ZodRecord<z.ZodLiteral<"undone" | "done">, z.ZodInt>>;
535
535
  }, z.core.$strip>>;
536
536
  partnerMap: z.ZodOptional<z.ZodRecord<z.ZodUUID, z.ZodRecord<z.ZodUUID, z.ZodObject<{
537
537
  addedAt: z.ZodISODateTime;
@@ -649,7 +649,7 @@ declare const CompanySession: z.ZodObject<{
649
649
  value: z.ZodBoolean;
650
650
  lastModified: z.ZodOptional<z.ZodISODateTime>;
651
651
  }, z.core.$strip>;
652
- taskCounter: z.ZodRecord<z.ZodLiteral<"undone" | "done">, z.ZodInt>;
652
+ serviceCounter: z.ZodRecord<z.ZodLiteral<"undone" | "done">, z.ZodInt>;
653
653
  roles: z.ZodPipe<z.ZodArray<z.ZodEnum<{
654
654
  doc: "doc";
655
655
  physAsst: "physAsst";
@@ -1209,4 +1209,4 @@ declare function createNotifId(options?: {
1209
1209
  to: string;
1210
1210
  }): string;
1211
1211
 
1212
- export { type AcceptedCurrency, AlphaNumeric, COMPANY_USER_RELATIONSHIP, ClientDetails, ClientForm, CompanyBilling, CompanyDetails, CompanyIdentity, CompanyIndustry, CompanyNotifications, CompanyPreferences, type CompanyServiceSelector, CompanySession, CompanyStaff, CompanyState, type CompanyUserRole, CreateCompanyForm, CreditCurrency, type EmployeeRole, type Gender, type HealthcareProviderRole, InviteResponse, InvoiceNo, MAX_COMPANY_PRICE_MODS, MedicalDetails, Medicine, MutableCompanyBilling, MutableCompanyDetails, MutableCompanyIdentity, MutableCompanyPreferences, MutableCompanyStaff, MutableServiceDetails, Notification, PaymentDetails, type PaymentMethod, PriceMod, PriceModList, PriceTag, Reason, Receipts, ServiceDetails, ServiceSeverity, StandardTime, type TaskDistAlg, TicketNo, type Tier, TierList, TimeLog, Timestamp, Trn, UserDetails, Vitals, acceptedCurrencies, adminRoles, calcBalance, calcPriceMod, companyServiceSelectors, companyUserRoles, createNotifId, employeeRoles, genders, getCompatibleRoles, getIncompatibleRoles, healthcareProviderRoles, normalizeCompanyId, normalizeNidKey, parseClientName, paymentMethods, taskDistAlgs, tiers, vitalKeys };
1212
+ export { type AcceptedCurrency, AlphaNumeric, COMPANY_USER_RELATIONSHIP, ClientDetails, ClientForm, CompanyBilling, CompanyDetails, CompanyIdentity, CompanyIndustry, CompanyNotifications, CompanyPreferences, type CompanyServiceSelector, CompanySession, CompanyStaff, CompanyState, type CompanyUserRole, CreateCompanyForm, CreditCurrency, type EmployeeRole, type Gender, type HealthcareProviderRole, InviteResponse, InvoiceNo, MAX_COMPANY_PRICE_MODS, MedicalDetails, Medicine, MutableCompanyBilling, MutableCompanyDetails, MutableCompanyIdentity, MutableCompanyPreferences, MutableCompanyStaff, MutableServiceDetails, Notification, PaymentDetails, type PaymentMethod, PriceMod, PriceModList, PriceTag, Reason, Receipts, ServiceDetails, type ServiceDistAlg, ServiceSeverity, StandardTime, TicketNo, type Tier, TierList, TimeLog, Timestamp, Trn, UserDetails, Vitals, acceptedCurrencies, adminRoles, calcBalance, calcPriceMod, companyServiceSelectors, companyUserRoles, createNotifId, employeeRoles, genders, getCompatibleRoles, getIncompatibleRoles, healthcareProviderRoles, normalizeCompanyId, normalizeNidKey, parseClientName, paymentMethods, serviceDistAlgs, tiers, vitalKeys };
package/dist/main.js CHANGED
@@ -15,7 +15,7 @@ var healthcareProviderRoles = companyUserRoles.extract([
15
15
  "physAsst",
16
16
  "doc"
17
17
  ]);
18
- var taskDistAlgs = z.enum(["RR", "LOR"]);
18
+ var serviceDistAlgs = z.enum(["RR", "LOR"]);
19
19
  var companyServiceSelectors = z.enum(["scheduler", "doctor"]);
20
20
 
21
21
  // src/enums/Global.ts
@@ -256,18 +256,18 @@ var CompanyPreferences = z10.object({
256
256
  _id: CompanyState.shape._id,
257
257
  /** The user that's allowed to record the client's services. */
258
258
  serviceSelector: companyServiceSelectors,
259
- /** Pay per task */
260
- ppt: z10.boolean(),
259
+ /** Pay per service */
260
+ pps: z10.boolean(),
261
261
  /**
262
262
  * @property RR (Round Robin): Even distribution.
263
263
  * @property LOR (Least Outstanding Requests): Distribute based on availability.
264
264
  */
265
- taskDistAlg: taskDistAlgs,
265
+ serviceDistAlg: serviceDistAlgs,
266
266
  servicesDeployed: z10.boolean(),
267
267
  ...TimeLog.shape
268
268
  }).refine(
269
- (data) => !data.ppt || data.ppt && data.serviceSelector === "scheduler",
270
- `Pay per task is only allowed when the service selector is the "${"scheduler"}".`
269
+ (data) => !data.pps || data.pps && data.serviceSelector === "scheduler",
270
+ `Pay per service is only allowed when the service selector is the "${"scheduler"}".`
271
271
  );
272
272
  var MutableCompanyPreferences = CompanyPreferences.omit({
273
273
  _id: true,
@@ -425,7 +425,7 @@ var CompanySession = z13.object({
425
425
  value: z13.boolean(),
426
426
  lastModified: Timestamp.optional()
427
427
  }),
428
- taskCounter: z13.record(z13.literal(["undone", "done"]), z13.int().min(0)),
428
+ serviceCounter: z13.record(z13.literal(["undone", "done"]), z13.int().min(0)),
429
429
  roles: CompanyMemberRoles,
430
430
  ttl: z13.number(),
431
431
  expiresAfter: z13.date(),
@@ -447,7 +447,7 @@ var CompanyStaff = z14.object({
447
447
  joinedAt: Timestamp,
448
448
  lastActive: Timestamp,
449
449
  roles: CompanyMemberRoles,
450
- dailyTaskCounter: CompanySession.shape.taskCounter.optional()
450
+ dailyServiceCounter: CompanySession.shape.serviceCounter.optional()
451
451
  })
452
452
  ),
453
453
  /**
@@ -645,7 +645,7 @@ var CreateCompanyForm = z18.object({
645
645
  }
646
646
  });
647
647
 
648
- // src/schemas/company/core/service/components/Medical.ts
648
+ // src/schemas/company/core/service/payloads/Medical.ts
649
649
  import * as z19 from "zod";
650
650
  var Vitals = z19.record(
651
651
  vitalKeys,
@@ -744,8 +744,8 @@ var ServiceDetails = z20.object({
744
744
  lockedBy: UserDetails.shape._id.optional(),
745
745
  /** Role based access control
746
746
  * If a role is:
747
- * [1] Ommitted -> any user with that role that's from the same company can access the TaskDetails.
748
- * [1] Addded -> only the users that have that role and an id in the respective array can access the TaskDetails.
747
+ * [1] Ommitted -> any user with that role that's from the same company can access the ServiceDetails.
748
+ * [1] Addded -> only the users that have that role and an id in the respective array can access the ServiceDetails.
749
749
  */
750
750
  rbac: z20.record(companyUserRoles, z20.array(UserDetails.shape._id).optional()),
751
751
  timeline: z20.record(
@@ -890,7 +890,7 @@ export {
890
890
  normalizeNidKey,
891
891
  parseClientName,
892
892
  paymentMethods,
893
- taskDistAlgs,
893
+ serviceDistAlgs,
894
894
  tiers,
895
895
  vitalKeys
896
896
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bizmap/sdk",
3
- "version": "0.0.124",
3
+ "version": "0.0.125",
4
4
  "main": "./dist/main.js",
5
5
  "types": "./dist/main.d.ts",
6
6
  "type": "module",