@blackcode_sa/metaestetics-api 1.4.4 → 1.4.6
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/index.d.mts +108 -93
- package/dist/index.d.ts +108 -93
- package/dist/index.js +16 -6
- package/dist/index.mjs +11 -6
- package/package.json +1 -1
- package/src/index.ts +17 -0
- package/src/services/auth.service.ts +1 -1
- package/src/types/clinic/index.ts +4 -4
- package/src/validations/clinic.schema.ts +5 -5
package/dist/index.mjs
CHANGED
|
@@ -2283,9 +2283,9 @@ var clinicTagsSchema = z9.object({
|
|
|
2283
2283
|
var contactPersonSchema = z9.object({
|
|
2284
2284
|
firstName: z9.string(),
|
|
2285
2285
|
lastName: z9.string(),
|
|
2286
|
-
title: z9.string(),
|
|
2286
|
+
title: z9.string().nullable().optional(),
|
|
2287
2287
|
email: z9.string().email(),
|
|
2288
|
-
phoneNumber: z9.string()
|
|
2288
|
+
phoneNumber: z9.string().nullable().optional()
|
|
2289
2289
|
});
|
|
2290
2290
|
var adminInfoSchema = z9.object({
|
|
2291
2291
|
id: z9.string(),
|
|
@@ -2381,7 +2381,7 @@ var clinicGroupSchema = z9.object({
|
|
|
2381
2381
|
updatedAt: z9.instanceof(Date).or(z9.instanceof(Timestamp5)),
|
|
2382
2382
|
// Timestamp
|
|
2383
2383
|
isActive: z9.boolean(),
|
|
2384
|
-
logo: z9.string().optional(),
|
|
2384
|
+
logo: z9.string().optional().nullable(),
|
|
2385
2385
|
practiceType: z9.nativeEnum(PracticeType).optional(),
|
|
2386
2386
|
languages: z9.array(z9.nativeEnum(Language)).optional(),
|
|
2387
2387
|
subscriptionModel: z9.nativeEnum(SubscriptionModel),
|
|
@@ -2453,7 +2453,7 @@ var createClinicGroupSchema = z9.object({
|
|
|
2453
2453
|
contactPerson: contactPersonSchema,
|
|
2454
2454
|
ownerId: z9.string(),
|
|
2455
2455
|
isActive: z9.boolean(),
|
|
2456
|
-
logo: z9.string().optional(),
|
|
2456
|
+
logo: z9.string().optional().nullable(),
|
|
2457
2457
|
practiceType: z9.nativeEnum(PracticeType).optional(),
|
|
2458
2458
|
languages: z9.array(z9.nativeEnum(Language)).optional(),
|
|
2459
2459
|
subscriptionModel: z9.nativeEnum(SubscriptionModel).optional().default("no_subscription" /* NO_SUBSCRIPTION */),
|
|
@@ -2490,7 +2490,7 @@ var createDefaultClinicGroupSchema = z9.object({
|
|
|
2490
2490
|
contactInfo: clinicContactInfoSchema,
|
|
2491
2491
|
hqLocation: clinicLocationSchema,
|
|
2492
2492
|
isActive: z9.boolean(),
|
|
2493
|
-
logo: z9.string().optional(),
|
|
2493
|
+
logo: z9.string().optional().nullable(),
|
|
2494
2494
|
practiceType: z9.nativeEnum(PracticeType).optional(),
|
|
2495
2495
|
languages: z9.array(z9.nativeEnum(Language)).optional(),
|
|
2496
2496
|
subscriptionModel: z9.nativeEnum(SubscriptionModel).optional().default("no_subscription" /* NO_SUBSCRIPTION */)
|
|
@@ -4498,7 +4498,7 @@ var AuthService = class extends BaseService {
|
|
|
4498
4498
|
contactPerson,
|
|
4499
4499
|
ownerId: firebaseUser.uid,
|
|
4500
4500
|
isActive: true,
|
|
4501
|
-
logo: data.clinicGroupData.logo,
|
|
4501
|
+
logo: data.clinicGroupData.logo || null,
|
|
4502
4502
|
subscriptionModel: data.clinicGroupData.subscriptionModel || "no_subscription" /* NO_SUBSCRIPTION */
|
|
4503
4503
|
};
|
|
4504
4504
|
await clinicGroupService.createClinicGroup(
|
|
@@ -5513,6 +5513,7 @@ var notificationSchema = z16.discriminatedUnion("notificationType", [
|
|
|
5513
5513
|
]);
|
|
5514
5514
|
export {
|
|
5515
5515
|
AUTH_ERRORS,
|
|
5516
|
+
AdminTokenStatus,
|
|
5516
5517
|
AllergyType,
|
|
5517
5518
|
AuthService,
|
|
5518
5519
|
BlockingCondition,
|
|
@@ -5524,6 +5525,7 @@ export {
|
|
|
5524
5525
|
ClinicAdminService,
|
|
5525
5526
|
ClinicGroupService,
|
|
5526
5527
|
ClinicService,
|
|
5528
|
+
ClinicTag,
|
|
5527
5529
|
Contraindication,
|
|
5528
5530
|
CosmeticAllergySubtype,
|
|
5529
5531
|
Currency,
|
|
@@ -5539,6 +5541,7 @@ export {
|
|
|
5539
5541
|
FoodAllergySubtype,
|
|
5540
5542
|
Gender,
|
|
5541
5543
|
HeadingLevel,
|
|
5544
|
+
Language,
|
|
5542
5545
|
ListType,
|
|
5543
5546
|
MedicationAllergySubtype,
|
|
5544
5547
|
NotificationService,
|
|
@@ -5552,9 +5555,11 @@ export {
|
|
|
5552
5555
|
PATIENT_SENSITIVE_INFO_COLLECTION,
|
|
5553
5556
|
PRACTITIONERS_COLLECTION,
|
|
5554
5557
|
PatientService,
|
|
5558
|
+
PracticeType,
|
|
5555
5559
|
PractitionerService,
|
|
5556
5560
|
PricingMeasure,
|
|
5557
5561
|
ProcedureFamily,
|
|
5562
|
+
SubscriptionModel,
|
|
5558
5563
|
TreatmentBenefit,
|
|
5559
5564
|
USER_ERRORS,
|
|
5560
5565
|
UserService,
|
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -134,11 +134,28 @@ export type {
|
|
|
134
134
|
WorkingHours,
|
|
135
135
|
ClinicTags,
|
|
136
136
|
ClinicReview,
|
|
137
|
+
ClinicAdminSignupData,
|
|
138
|
+
ContactPerson,
|
|
139
|
+
ClinicInfo,
|
|
140
|
+
AdminToken,
|
|
141
|
+
AdminInfo,
|
|
142
|
+
CreateAdminTokenData,
|
|
143
|
+
DoctorInfo,
|
|
144
|
+
ServiceInfo,
|
|
145
|
+
ReviewInfo,
|
|
146
|
+
CreateDefaultClinicGroupData,
|
|
147
|
+
ClinicGroupSetupData,
|
|
148
|
+
ClinicBranchSetupData,
|
|
137
149
|
} from "./types/clinic";
|
|
138
150
|
export {
|
|
139
151
|
CLINICS_COLLECTION,
|
|
140
152
|
CLINIC_GROUPS_COLLECTION,
|
|
141
153
|
CLINIC_ADMINS_COLLECTION,
|
|
154
|
+
PracticeType,
|
|
155
|
+
Language,
|
|
156
|
+
ClinicTag,
|
|
157
|
+
AdminTokenStatus,
|
|
158
|
+
SubscriptionModel,
|
|
142
159
|
} from "./types/clinic";
|
|
143
160
|
|
|
144
161
|
// Certification types
|
|
@@ -175,7 +175,7 @@ export class AuthService extends BaseService {
|
|
|
175
175
|
contactPerson: contactPerson,
|
|
176
176
|
ownerId: firebaseUser.uid,
|
|
177
177
|
isActive: true,
|
|
178
|
-
logo: data.clinicGroupData.logo,
|
|
178
|
+
logo: data.clinicGroupData.logo || null,
|
|
179
179
|
subscriptionModel:
|
|
180
180
|
data.clinicGroupData.subscriptionModel ||
|
|
181
181
|
SubscriptionModel.NO_SUBSCRIPTION,
|
|
@@ -84,9 +84,9 @@ export interface WorkingHours {
|
|
|
84
84
|
export interface ContactPerson {
|
|
85
85
|
firstName: string;
|
|
86
86
|
lastName: string;
|
|
87
|
-
title
|
|
87
|
+
title?: string | null;
|
|
88
88
|
email: string;
|
|
89
|
-
phoneNumber
|
|
89
|
+
phoneNumber?: string | null;
|
|
90
90
|
}
|
|
91
91
|
|
|
92
92
|
/**
|
|
@@ -199,7 +199,7 @@ export interface ClinicGroup {
|
|
|
199
199
|
createdAt: Timestamp;
|
|
200
200
|
updatedAt: Timestamp;
|
|
201
201
|
isActive: boolean;
|
|
202
|
-
logo?: string;
|
|
202
|
+
logo?: string | null;
|
|
203
203
|
practiceType?: PracticeType;
|
|
204
204
|
languages?: Language[];
|
|
205
205
|
subscriptionModel: SubscriptionModel;
|
|
@@ -218,7 +218,7 @@ export interface CreateClinicGroupData {
|
|
|
218
218
|
contactPerson: ContactPerson;
|
|
219
219
|
ownerId: string;
|
|
220
220
|
isActive: boolean;
|
|
221
|
-
logo?: string;
|
|
221
|
+
logo?: string | null;
|
|
222
222
|
practiceType?: PracticeType;
|
|
223
223
|
languages?: Language[];
|
|
224
224
|
subscriptionModel?: SubscriptionModel;
|
|
@@ -76,9 +76,9 @@ export const clinicTagsSchema = z.object({
|
|
|
76
76
|
export const contactPersonSchema = z.object({
|
|
77
77
|
firstName: z.string(),
|
|
78
78
|
lastName: z.string(),
|
|
79
|
-
title: z.string(),
|
|
79
|
+
title: z.string().nullable().optional(),
|
|
80
80
|
email: z.string().email(),
|
|
81
|
-
phoneNumber: z.string(),
|
|
81
|
+
phoneNumber: z.string().nullable().optional(),
|
|
82
82
|
});
|
|
83
83
|
|
|
84
84
|
/**
|
|
@@ -204,7 +204,7 @@ export const clinicGroupSchema = z.object({
|
|
|
204
204
|
createdAt: z.instanceof(Date).or(z.instanceof(Timestamp)), // Timestamp
|
|
205
205
|
updatedAt: z.instanceof(Date).or(z.instanceof(Timestamp)), // Timestamp
|
|
206
206
|
isActive: z.boolean(),
|
|
207
|
-
logo: z.string().optional(),
|
|
207
|
+
logo: z.string().optional().nullable(),
|
|
208
208
|
practiceType: z.nativeEnum(PracticeType).optional(),
|
|
209
209
|
languages: z.array(z.nativeEnum(Language)).optional(),
|
|
210
210
|
subscriptionModel: z.nativeEnum(SubscriptionModel),
|
|
@@ -292,7 +292,7 @@ export const createClinicGroupSchema = z.object({
|
|
|
292
292
|
contactPerson: contactPersonSchema,
|
|
293
293
|
ownerId: z.string(),
|
|
294
294
|
isActive: z.boolean(),
|
|
295
|
-
logo: z.string().optional(),
|
|
295
|
+
logo: z.string().optional().nullable(),
|
|
296
296
|
practiceType: z.nativeEnum(PracticeType).optional(),
|
|
297
297
|
languages: z.array(z.nativeEnum(Language)).optional(),
|
|
298
298
|
subscriptionModel: z
|
|
@@ -342,7 +342,7 @@ export const createDefaultClinicGroupSchema = z.object({
|
|
|
342
342
|
contactInfo: clinicContactInfoSchema,
|
|
343
343
|
hqLocation: clinicLocationSchema,
|
|
344
344
|
isActive: z.boolean(),
|
|
345
|
-
logo: z.string().optional(),
|
|
345
|
+
logo: z.string().optional().nullable(),
|
|
346
346
|
practiceType: z.nativeEnum(PracticeType).optional(),
|
|
347
347
|
languages: z.array(z.nativeEnum(Language)).optional(),
|
|
348
348
|
subscriptionModel: z
|