@bizmap/sdk 0.0.9 → 0.0.11

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
@@ -20,7 +20,7 @@ declare const PriceTag: z.ZodObject<{
20
20
  createdAt: z.ZodReadonly<z.ZodNumber>;
21
21
  lastModified: z.ZodNullable<z.ZodNumber>;
22
22
  uid: z.ZodString;
23
- name: z.ZodString;
23
+ item: z.ZodString;
24
24
  cost: z.ZodNumber;
25
25
  }, z.core.$strip>;
26
26
  type PriceTag = z.infer<typeof PriceTag>;
@@ -31,18 +31,21 @@ declare const CompanyIdentity: z.ZodObject<{
31
31
  uid: z.ZodReadonly<z.ZodString>;
32
32
  displayName: z.ZodString;
33
33
  logo: z.ZodOptional<z.ZodString>;
34
- slogan: z.ZodString;
35
- regNo: z.ZodReadonly<z.ZodString>;
36
- email: z.ZodEmail;
34
+ contact: z.ZodObject<{
35
+ email: z.ZodEmail;
36
+ phoneNumber: z.ZodOptional<z.ZodString>;
37
+ }, z.core.$strip>;
37
38
  address: z.ZodRecord<z.ZodEnum<{
38
39
  streetAddress: "streetAddress";
39
40
  city: "city";
40
41
  parish: "parish";
41
42
  country: "country";
42
43
  }>, z.ZodString>;
43
- phoneNumber: z.ZodOptional<z.ZodString>;
44
- trn: z.ZodOptional<z.ZodString>;
45
- gctRegNo: z.ZodOptional<z.ZodString>;
44
+ legal: z.ZodObject<{
45
+ regNo: z.ZodReadonly<z.ZodString>;
46
+ trn: z.ZodOptional<z.ZodString>;
47
+ gctRegNo: z.ZodOptional<z.ZodString>;
48
+ }, z.core.$strip>;
46
49
  }, z.core.$strip>;
47
50
  type CompanyIdentity = z.infer<typeof CompanyIdentity>;
48
51
  declare const CompanyOpState: z.ZodObject<{
@@ -62,10 +65,6 @@ declare const CompanyPreferences: z.ZodObject<{
62
65
  RR: "RR";
63
66
  LOR: "LOR";
64
67
  }>;
65
- workingHours: z.ZodObject<{
66
- start: z.ZodString;
67
- end: z.ZodString;
68
- }, z.core.$strip>;
69
68
  }, z.core.$strip>;
70
69
  type CompanyPreferences = z.infer<typeof CompanyPreferences>;
71
70
  declare const CompanyBillingModel: z.ZodObject<{
@@ -79,6 +78,9 @@ declare const CompanyBillingModel: z.ZodObject<{
79
78
  primaryCurrency: z.ZodEnum<{
80
79
  JMD: "JMD";
81
80
  }>;
81
+ acceptedCurrencies: z.ZodArray<z.ZodEnum<{
82
+ JMD: "JMD";
83
+ }>>;
82
84
  additionalFees: z.ZodOptional<z.ZodArray<z.ZodObject<{
83
85
  createdAt: z.ZodReadonly<z.ZodNumber>;
84
86
  lastModified: z.ZodNullable<z.ZodNumber>;
@@ -96,13 +98,9 @@ declare const CompanyBillingModel: z.ZodObject<{
96
98
  services: z.ZodOptional<z.ZodArray<z.ZodObject<{
97
99
  createdAt: z.ZodReadonly<z.ZodNumber>;
98
100
  lastModified: z.ZodNullable<z.ZodNumber>;
99
- uid: z.ZodString;
100
- name: z.ZodString;
101
+ item: z.ZodString;
101
102
  cost: z.ZodNumber;
102
103
  }, z.core.$strip>>>;
103
- acceptedCurrencies: z.ZodArray<z.ZodEnum<{
104
- JMD: "JMD";
105
- }>>;
106
104
  }, z.core.$strip>;
107
105
  type CompanyBillingModel = z.infer<typeof CompanyBillingModel>;
108
106
  declare const RegisterCompanyForm: z.ZodObject<{
@@ -111,10 +109,6 @@ declare const RegisterCompanyForm: z.ZodObject<{
111
109
  slogan: z.ZodString;
112
110
  email: z.ZodEmail;
113
111
  phoneNumber: z.ZodString;
114
- workingHours: z.ZodObject<{
115
- start: z.ZodString;
116
- end: z.ZodString;
117
- }, z.core.$strip>;
118
112
  logo: z.ZodObject<{
119
113
  lastModified: z.ZodNullable<z.ZodNumber>;
120
114
  uid: z.ZodOptional<z.ZodString>;
@@ -233,6 +227,7 @@ declare const StaffDetails: z.ZodObject<{
233
227
  uid: z.ZodString;
234
228
  }, z.core.$strip>>;
235
229
  partnerMap: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString>>;
230
+ blackList: z.ZodArray<z.ZodString>;
236
231
  }, z.core.$strip>;
237
232
  type StaffDetails = z.infer<typeof StaffDetails>;
238
233
 
package/dist/main.js CHANGED
@@ -25,7 +25,8 @@ var PriceAdjustment = z2.object({
25
25
  });
26
26
  var PriceTag = z2.object({
27
27
  uid: z2.string(),
28
- name: z2.string(),
28
+ /**The name of the item that's being priced */
29
+ item: z2.string(),
29
30
  cost: z2.number(),
30
31
  ...TimeLog.shape
31
32
  });
@@ -61,19 +62,19 @@ var appointmentDistAlgs = z3.enum(["RR", "LOR"]);
61
62
  var CompanyIdentity = z4.object({
62
63
  uid: z4.string().readonly(),
63
64
  // The company's uid
64
- // Organizational
65
65
  displayName: z4.string(),
66
66
  logo: z4.string().optional(),
67
- slogan: z4.string(),
68
- regNo: z4.string().readonly(),
69
- // The company's registration number
70
- // Social
71
- email: z4.email(),
67
+ contact: z4.object({
68
+ email: z4.email(),
69
+ phoneNumber: PhoneNumber.optional()
70
+ }),
72
71
  address: Address,
73
- phoneNumber: PhoneNumber.optional(),
74
- // Legal
75
- trn: z4.string().optional(),
76
- gctRegNo: z4.string().optional(),
72
+ legal: z4.object({
73
+ regNo: z4.string().readonly(),
74
+ // The company's registration number
75
+ trn: z4.string().optional(),
76
+ gctRegNo: z4.string().optional()
77
+ }),
77
78
  ...TimeLog.shape
78
79
  });
79
80
  var CompanyOpState = z4.object({
@@ -93,25 +94,26 @@ var CompanyPreferences = z4.object({
93
94
  * @property LOR (Least Outstanding Requests): Distribute based on availability.
94
95
  */
95
96
  apptDistAlg: appointmentDistAlgs,
96
- // Required to determine:
97
- // [1] when the working directory on the server should reset
98
- // [2] the time that company session requests are cut-off
99
- // (the cutoff time affects non-admins)
100
- workingHours: z4.object({
101
- start: Time,
102
- end: Time
103
- }),
97
+ // // Required to determine:
98
+ // // [1] when the working directory on the server should reset
99
+ // // [2] the time that company session requests are cut-off
100
+ // // (the cutoff time affects non-admins)
101
+ // workingHours: z.object({
102
+ // start: Time,
103
+ // end: Time,
104
+ // }),
104
105
  ...TimeLog.shape
105
106
  });
106
107
  var CompanyBillingModel = z4.object({
107
108
  uid: CompanyIdentity.shape.uid,
109
+ // Preferences
108
110
  /** The user that provides the bill to the client */
109
111
  biller: companyUserRoles.extract(["doc", "fdc"]),
110
112
  primaryCurrency: currencies,
113
+ acceptedCurrencies: z4.array(currencies),
111
114
  additionalFees: z4.array(PriceAdjustment).optional(),
112
115
  discounts: z4.array(PriceAdjustment).optional(),
113
- services: z4.array(PriceTag).optional(),
114
- acceptedCurrencies: z4.array(currencies),
116
+ services: z4.array(PriceTag.omit({ uid: true })).optional(),
115
117
  ...TimeLog.shape
116
118
  });
117
119
  var RegisterCompanyForm = z4.object({
@@ -120,7 +122,6 @@ var RegisterCompanyForm = z4.object({
120
122
  slogan: z4.string(),
121
123
  email: z4.email(),
122
124
  phoneNumber: PhoneNumber,
123
- workingHours: CompanyPreferences.shape.workingHours,
124
125
  logo: FileDetails,
125
126
  receipt: FileDetails,
126
127
  _claims: z4.string()
@@ -143,7 +144,8 @@ var StaffDetails = z4.object({
143
144
  /**
144
145
  * @relationship one -> many
145
146
  *@description A map of doctor `uids` to their assistants `uids` */
146
- partnerMap: z4.record(CompanyUser.shape.uid, z4.array(CompanyUser.shape.uid))
147
+ partnerMap: z4.record(CompanyUser.shape.uid, z4.array(CompanyUser.shape.uid)),
148
+ blackList: z4.array(CompanyUser.shape.uid)
147
149
  });
148
150
  export {
149
151
  CompanyBillingModel,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bizmap/sdk",
3
- "version": "0.0.9",
3
+ "version": "0.0.11",
4
4
  "main": "./dist/main.js",
5
5
  "types": "./dist/main.d.ts",
6
6
  "type": "module",