wiil-core-js 0.0.82
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/LICENSE +21 -0
- package/README.md +174 -0
- package/dist/core/account/index.d.ts +7 -0
- package/dist/core/account/index.js +23 -0
- package/dist/core/account/organization.schema.d.ts +118 -0
- package/dist/core/account/organization.schema.js +91 -0
- package/dist/core/account/project.schema.d.ts +121 -0
- package/dist/core/account/project.schema.js +102 -0
- package/dist/core/account/supported-business-verticals.d.ts +8 -0
- package/dist/core/account/supported-business-verticals.js +23 -0
- package/dist/core/assistant-setups/assistant-setup-result.schema.d.ts +115 -0
- package/dist/core/assistant-setups/assistant-setup-result.schema.js +17 -0
- package/dist/core/assistant-setups/base-assistant-setup.schema.d.ts +61 -0
- package/dist/core/assistant-setups/base-assistant-setup.schema.js +29 -0
- package/dist/core/assistant-setups/index.d.ts +4 -0
- package/dist/core/assistant-setups/index.js +21 -0
- package/dist/core/assistant-setups/phone-assistant-setup.schema.d.ts +63 -0
- package/dist/core/assistant-setups/phone-assistant-setup.schema.js +14 -0
- package/dist/core/assistant-setups/web-assitant-setup.schema.d.ts +56 -0
- package/dist/core/assistant-setups/web-assitant-setup.schema.js +17 -0
- package/dist/core/base.schema.d.ts +34 -0
- package/dist/core/base.schema.js +36 -0
- package/dist/core/business-mgt/appointment-additional-info.schema.d.ts +63 -0
- package/dist/core/business-mgt/appointment-additional-info.schema.js +53 -0
- package/dist/core/business-mgt/appointment-field-config.schema.d.ts +251 -0
- package/dist/core/business-mgt/appointment-field-config.schema.js +49 -0
- package/dist/core/business-mgt/bookings.shared.schema.d.ts +47 -0
- package/dist/core/business-mgt/bookings.shared.schema.js +60 -0
- package/dist/core/business-mgt/business-location.schema.d.ts +327 -0
- package/dist/core/business-mgt/business-location.schema.js +176 -0
- package/dist/core/business-mgt/customer-management/customer-group.schema.d.ts +87 -0
- package/dist/core/business-mgt/customer-management/customer-group.schema.js +53 -0
- package/dist/core/business-mgt/customer-management/customer.schema.d.ts +156 -0
- package/dist/core/business-mgt/customer-management/customer.schema.js +93 -0
- package/dist/core/business-mgt/customer-management/index.d.ts +7 -0
- package/dist/core/business-mgt/customer-management/index.js +23 -0
- package/dist/core/business-mgt/customer-management/shipping-address.schema.d.ts +112 -0
- package/dist/core/business-mgt/customer-management/shipping-address.schema.js +79 -0
- package/dist/core/business-mgt/customer.schema.d.ts +111 -0
- package/dist/core/business-mgt/customer.schema.js +73 -0
- package/dist/core/business-mgt/discount-rule.schema.d.ts +183 -0
- package/dist/core/business-mgt/discount-rule.schema.js +108 -0
- package/dist/core/business-mgt/index.d.ts +16 -0
- package/dist/core/business-mgt/index.js +38 -0
- package/dist/core/business-mgt/menu-config.schema.d.ts +165 -0
- package/dist/core/business-mgt/menu-config.schema.js +86 -0
- package/dist/core/business-mgt/menu-management/index.d.ts +11 -0
- package/dist/core/business-mgt/menu-management/index.js +27 -0
- package/dist/core/business-mgt/menu-management/menu-catalog.schema.d.ts +386 -0
- package/dist/core/business-mgt/menu-management/menu-catalog.schema.js +58 -0
- package/dist/core/business-mgt/menu-management/menu-config.schema.d.ts +301 -0
- package/dist/core/business-mgt/menu-management/menu-config.schema.js +169 -0
- package/dist/core/business-mgt/menu-management/menu-item-variant.schema.d.ts +143 -0
- package/dist/core/business-mgt/menu-management/menu-item-variant.schema.js +86 -0
- package/dist/core/business-mgt/menu-management/menu-pricing-rule.schema.d.ts +239 -0
- package/dist/core/business-mgt/menu-management/menu-pricing-rule.schema.js +117 -0
- package/dist/core/business-mgt/menu-management/menu-set.schema.d.ts +420 -0
- package/dist/core/business-mgt/menu-management/menu-set.schema.js +283 -0
- package/dist/core/business-mgt/menu-management/menu.order.schema.d.ts +654 -0
- package/dist/core/business-mgt/menu-management/menu.order.schema.js +204 -0
- package/dist/core/business-mgt/menu-management/modifier.schema.d.ts +585 -0
- package/dist/core/business-mgt/menu-management/modifier.schema.js +341 -0
- package/dist/core/business-mgt/menu.order.schema.d.ts +335 -0
- package/dist/core/business-mgt/menu.order.schema.js +149 -0
- package/dist/core/business-mgt/order.schema.d.ts +222 -0
- package/dist/core/business-mgt/order.schema.js +205 -0
- package/dist/core/business-mgt/pricing-rule.shared.schema.d.ts +56 -0
- package/dist/core/business-mgt/pricing-rule.shared.schema.js +68 -0
- package/dist/core/business-mgt/product-config.schema.d.ts +177 -0
- package/dist/core/business-mgt/product-config.schema.js +106 -0
- package/dist/core/business-mgt/product-management/index.d.ts +12 -0
- package/dist/core/business-mgt/product-management/index.js +28 -0
- package/dist/core/business-mgt/product-management/product-axis-binding.schema.d.ts +54 -0
- package/dist/core/business-mgt/product-management/product-axis-binding.schema.js +54 -0
- package/dist/core/business-mgt/product-management/product-config.schema.d.ts +1042 -0
- package/dist/core/business-mgt/product-management/product-config.schema.js +392 -0
- package/dist/core/business-mgt/product-management/product-display.schema.d.ts +548 -0
- package/dist/core/business-mgt/product-management/product-display.schema.js +80 -0
- package/dist/core/business-mgt/product-management/product-order.schema.d.ts +493 -0
- package/dist/core/business-mgt/product-management/product-order.schema.js +158 -0
- package/dist/core/business-mgt/product-management/product-pricing-rule.schema.d.ts +167 -0
- package/dist/core/business-mgt/product-management/product-pricing-rule.schema.js +68 -0
- package/dist/core/business-mgt/product-management/product-set.schema.d.ts +488 -0
- package/dist/core/business-mgt/product-management/product-set.schema.js +273 -0
- package/dist/core/business-mgt/product-management/product-variant-axis.schema.d.ts +156 -0
- package/dist/core/business-mgt/product-management/product-variant-axis.schema.js +98 -0
- package/dist/core/business-mgt/product-management/product-variant.schema.d.ts +219 -0
- package/dist/core/business-mgt/product-management/product-variant.schema.js +130 -0
- package/dist/core/business-mgt/product-order.schema.d.ts +326 -0
- package/dist/core/business-mgt/product-order.schema.js +153 -0
- package/dist/core/business-mgt/property-config.schema.d.ts +621 -0
- package/dist/core/business-mgt/property-config.schema.js +224 -0
- package/dist/core/business-mgt/property-inquiry.schema.d.ts +222 -0
- package/dist/core/business-mgt/property-inquiry.schema.js +112 -0
- package/dist/core/business-mgt/property-management/index.d.ts +6 -0
- package/dist/core/business-mgt/property-management/index.js +22 -0
- package/dist/core/business-mgt/property-management/property-config.schema.d.ts +1306 -0
- package/dist/core/business-mgt/property-management/property-config.schema.js +367 -0
- package/dist/core/business-mgt/property-management/property-inquiry.schema.d.ts +254 -0
- package/dist/core/business-mgt/property-management/property-inquiry.schema.js +131 -0
- package/dist/core/business-mgt/reservation-mgt/assignment/index.d.ts +3 -0
- package/dist/core/business-mgt/reservation-mgt/assignment/index.js +19 -0
- package/dist/core/business-mgt/reservation-mgt/assignment/reservation-rental-assignment.schema.d.ts +139 -0
- package/dist/core/business-mgt/reservation-mgt/assignment/reservation-rental-assignment.schema.js +90 -0
- package/dist/core/business-mgt/reservation-mgt/assignment/reservation-room-assignment.schema.d.ts +104 -0
- package/dist/core/business-mgt/reservation-mgt/assignment/reservation-room-assignment.schema.js +70 -0
- package/dist/core/business-mgt/reservation-mgt/assignment/reservation-table-assignment.schema.d.ts +104 -0
- package/dist/core/business-mgt/reservation-mgt/assignment/reservation-table-assignment.schema.js +72 -0
- package/dist/core/business-mgt/reservation-mgt/index.d.ts +14 -0
- package/dist/core/business-mgt/reservation-mgt/index.js +31 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-floor-plan-definition.schema.d.ts +180 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-floor-plan-definition.schema.js +75 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-maintenance-block.schema.d.ts +91 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-maintenance-block.schema.js +57 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-rental.schema.d.ts +334 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-rental.schema.js +179 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-room.schema.d.ts +195 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-room.schema.js +106 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-section.schema.d.ts +402 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-section.schema.js +198 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-settings.schema.d.ts +229 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-settings.schema.js +127 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-slot-query.schema.d.ts +382 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-slot-query.schema.js +322 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-table-layout.schema.d.ts +123 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-table-layout.schema.js +83 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-table.schema.d.ts +167 -0
- package/dist/core/business-mgt/reservation-mgt/reservation-table.schema.js +84 -0
- package/dist/core/business-mgt/reservation-mgt/reservation.schema.d.ts +0 -0
- package/dist/core/business-mgt/reservation-mgt/reservation.schema.js +153 -0
- package/dist/core/business-mgt/reservation-mgt/resource/index.d.ts +4 -0
- package/dist/core/business-mgt/reservation-mgt/resource/index.js +20 -0
- package/dist/core/business-mgt/reservation-mgt/resource/reservation-resource-category.schema.d.ts +157 -0
- package/dist/core/business-mgt/reservation-mgt/resource/reservation-resource-category.schema.js +76 -0
- package/dist/core/business-mgt/reservation-mgt/resource/reservation-resource-instance.schema.d.ts +137 -0
- package/dist/core/business-mgt/reservation-mgt/resource/reservation-resource-instance.schema.js +94 -0
- package/dist/core/business-mgt/reservation-mgt/resource/reservation-resource.schema.d.ts +713 -0
- package/dist/core/business-mgt/reservation-mgt/resource/reservation-resource.schema.js +363 -0
- package/dist/core/business-mgt/reservation-mgt/resource/resource-versioning.schema.d.ts +151 -0
- package/dist/core/business-mgt/reservation-mgt/resource/resource-versioning.schema.js +147 -0
- package/dist/core/business-mgt/reservation-resource.schema.d.ts +154 -0
- package/dist/core/business-mgt/reservation-resource.schema.js +100 -0
- package/dist/core/business-mgt/reservation.schema.d.ts +119 -0
- package/dist/core/business-mgt/reservation.schema.js +89 -0
- package/dist/core/business-mgt/service-appointment.schema.d.ts +105 -0
- package/dist/core/business-mgt/service-appointment.schema.js +69 -0
- package/dist/core/business-mgt/service-config.schema.d.ts +453 -0
- package/dist/core/business-mgt/service-config.schema.js +102 -0
- package/dist/core/business-mgt/service-management/appointment-additional-info.schema.d.ts +110 -0
- package/dist/core/business-mgt/service-management/appointment-additional-info.schema.js +78 -0
- package/dist/core/business-mgt/service-management/appointment-field-config.schema.d.ts +304 -0
- package/dist/core/business-mgt/service-management/appointment-field-config.schema.js +75 -0
- package/dist/core/business-mgt/service-management/business-service-config.schema.d.ts +1226 -0
- package/dist/core/business-mgt/service-management/business-service-config.schema.js +317 -0
- package/dist/core/business-mgt/service-management/index.d.ts +13 -0
- package/dist/core/business-mgt/service-management/index.js +29 -0
- package/dist/core/business-mgt/service-management/service-appointment.schema.d.ts +531 -0
- package/dist/core/business-mgt/service-management/service-appointment.schema.js +116 -0
- package/dist/core/business-mgt/service-management/service-person.schema.d.ts +122 -0
- package/dist/core/business-mgt/service-management/service-person.schema.js +66 -0
- package/dist/core/business-mgt/service-management/service-pricing-rule.schema.d.ts +221 -0
- package/dist/core/business-mgt/service-management/service-pricing-rule.schema.js +118 -0
- package/dist/core/business-mgt/service-management/service-provider.schema.d.ts +90 -0
- package/dist/core/business-mgt/service-management/service-provider.schema.js +54 -0
- package/dist/core/business-mgt/service-management/service-slot-query.schema.d.ts +90 -0
- package/dist/core/business-mgt/service-management/service-slot-query.schema.js +113 -0
- package/dist/core/business-mgt/service-management/service-time-off.schema.d.ts +121 -0
- package/dist/core/business-mgt/service-management/service-time-off.schema.js +95 -0
- package/dist/core/business-mgt/service-person.schema.d.ts +43 -0
- package/dist/core/business-mgt/service-person.schema.js +38 -0
- package/dist/core/business-mgt/tax-rule.schema.d.ts +161 -0
- package/dist/core/business-mgt/tax-rule.schema.js +90 -0
- package/dist/core/conversation/conversation-config.schema.d.ts +644 -0
- package/dist/core/conversation/conversation-config.schema.js +351 -0
- package/dist/core/conversation/conversation-message.schema.d.ts +307 -0
- package/dist/core/conversation/conversation-message.schema.js +275 -0
- package/dist/core/conversation/index.d.ts +12 -0
- package/dist/core/conversation/index.js +28 -0
- package/dist/core/conversation/outbound-call.schema.d.ts +209 -0
- package/dist/core/conversation/outbound-call.schema.js +116 -0
- package/dist/core/conversation/outbound-email.schema.d.ts +338 -0
- package/dist/core/conversation/outbound-email.schema.js +150 -0
- package/dist/core/conversation/outbound-sms.schema.d.ts +163 -0
- package/dist/core/conversation/outbound-sms.schema.js +85 -0
- package/dist/core/conversation/outbound-template.schema.d.ts +375 -0
- package/dist/core/conversation/outbound-template.schema.js +160 -0
- package/dist/core/conversation/translation-config.schema.d.ts +92 -0
- package/dist/core/conversation/translation-config.schema.js +88 -0
- package/dist/core/conversation/translation-conversation.schema.d.ts +469 -0
- package/dist/core/conversation/translation-conversation.schema.js +175 -0
- package/dist/core/index.d.ts +12 -0
- package/dist/core/index.js +30 -0
- package/dist/core/service-configuration/agent-config.schema.d.ts +236 -0
- package/dist/core/service-configuration/agent-config.schema.js +152 -0
- package/dist/core/service-configuration/base-agent-setup.d.ts +147 -0
- package/dist/core/service-configuration/base-agent-setup.js +123 -0
- package/dist/core/service-configuration/call-transfer-config.schema.d.ts +60 -0
- package/dist/core/service-configuration/call-transfer-config.schema.js +53 -0
- package/dist/core/service-configuration/deployment-config.schema.d.ts +522 -0
- package/dist/core/service-configuration/deployment-config.schema.js +271 -0
- package/dist/core/service-configuration/dynamic_setup/base-agent-setup.d.ts +130 -0
- package/dist/core/service-configuration/dynamic_setup/base-agent-setup.js +110 -0
- package/dist/core/service-configuration/dynamic_setup/index.d.ts +10 -0
- package/dist/core/service-configuration/dynamic_setup/index.js +26 -0
- package/dist/core/service-configuration/dynamic_setup/phone-agent-setup.d.ts +111 -0
- package/dist/core/service-configuration/dynamic_setup/phone-agent-setup.js +56 -0
- package/dist/core/service-configuration/dynamic_setup/web-agent-setup.d.ts +113 -0
- package/dist/core/service-configuration/dynamic_setup/web-agent-setup.js +55 -0
- package/dist/core/service-configuration/index.d.ts +17 -0
- package/dist/core/service-configuration/index.js +33 -0
- package/dist/core/service-configuration/instruction-config.schema.d.ts +183 -0
- package/dist/core/service-configuration/instruction-config.schema.js +139 -0
- package/dist/core/service-configuration/interaction-channels.schema.d.ts +469 -0
- package/dist/core/service-configuration/interaction-channels.schema.js +390 -0
- package/dist/core/service-configuration/knowledge.schema.d.ts +107 -0
- package/dist/core/service-configuration/knowledge.schema.js +106 -0
- package/dist/core/service-configuration/phone-config.schema.d.ts +206 -0
- package/dist/core/service-configuration/phone-config.schema.js +121 -0
- package/dist/core/service-configuration/phone-number.schema.d.ts +236 -0
- package/dist/core/service-configuration/phone-number.schema.js +211 -0
- package/dist/core/service-configuration/provisioning-config.d.ts +429 -0
- package/dist/core/service-configuration/provisioning-config.js +307 -0
- package/dist/core/service-configuration/support-llm.d.ts +95 -0
- package/dist/core/service-configuration/support-llm.js +76 -0
- package/dist/core/service-configuration/voice-language.schema.d.ts +200 -0
- package/dist/core/service-configuration/voice-language.schema.js +166 -0
- package/dist/core/type-definitions/account-definitions.d.ts +82 -0
- package/dist/core/type-definitions/account-definitions.js +88 -0
- package/dist/core/type-definitions/business-definitions.d.ts +394 -0
- package/dist/core/type-definitions/business-definitions.js +447 -0
- package/dist/core/type-definitions/conversation.type.definition.d.ts +223 -0
- package/dist/core/type-definitions/conversation.type.definition.js +236 -0
- package/dist/core/type-definitions/display-order.d.ts +154 -0
- package/dist/core/type-definitions/display-order.js +154 -0
- package/dist/core/type-definitions/dynamic-fields/field-definition.schema.d.ts +165 -0
- package/dist/core/type-definitions/dynamic-fields/field-definition.schema.js +97 -0
- package/dist/core/type-definitions/dynamic-fields/field-types.d.ts +49 -0
- package/dist/core/type-definitions/dynamic-fields/field-types.js +104 -0
- package/dist/core/type-definitions/dynamic-fields/index.d.ts +9 -0
- package/dist/core/type-definitions/dynamic-fields/index.js +25 -0
- package/dist/core/type-definitions/index.d.ts +10 -0
- package/dist/core/type-definitions/index.js +26 -0
- package/dist/core/type-definitions/knowledge-definitions.d.ts +30 -0
- package/dist/core/type-definitions/knowledge-definitions.js +37 -0
- package/dist/core/type-definitions/service-config.definitions.d.ts +112 -0
- package/dist/core/type-definitions/service-config.definitions.js +135 -0
- package/dist/core/validators/channel-validation.d.ts +19 -0
- package/dist/core/validators/channel-validation.js +40 -0
- package/dist/core/validators/index.d.ts +5 -0
- package/dist/core/validators/index.js +21 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +24 -0
- package/dist/request/index.d.ts +5 -0
- package/dist/request/index.js +21 -0
- package/dist/request/models/index.d.ts +6 -0
- package/dist/request/models/index.js +22 -0
- package/dist/request/models/paginated-quest.schema.d.ts +33 -0
- package/dist/request/models/paginated-quest.schema.js +35 -0
- package/dist/request/models/paginated-result.schema.d.ts +124 -0
- package/dist/request/models/paginated-result.schema.js +94 -0
- package/package.json +43 -0
|
@@ -0,0 +1,251 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
/**
|
|
3
|
+
* @fileoverview Organization-level appointment field configuration schema.
|
|
4
|
+
* @module business-mgt/appointment-field-config
|
|
5
|
+
*
|
|
6
|
+
* This schema represents the **Organization Level** in the dynamic fields hierarchy:
|
|
7
|
+
*
|
|
8
|
+
* ```
|
|
9
|
+
* Organization Level (AppointmentFieldConfigSchema) ← THIS SCHEMA
|
|
10
|
+
* │
|
|
11
|
+
* ▼ inherits via appointmentFieldConfigId
|
|
12
|
+
* Service Level (ServiceAppointmentFieldConfigSchema)
|
|
13
|
+
* │
|
|
14
|
+
* ▼ stores values
|
|
15
|
+
* Appointment Level (AppointmentAdditionalInfoSchema)
|
|
16
|
+
* ```
|
|
17
|
+
*
|
|
18
|
+
* Defines the base field library that can be reused across multiple services
|
|
19
|
+
* within an organization. Services can inherit fields from this configuration
|
|
20
|
+
* and optionally override specific properties or add service-specific fields.
|
|
21
|
+
*
|
|
22
|
+
* @see ServiceAppointmentFieldConfigSchema - Service-level field customization
|
|
23
|
+
* @see AppointmentAdditionalInfoSchema - Stores captured field values
|
|
24
|
+
*/
|
|
25
|
+
/**
|
|
26
|
+
* Organization-level appointment field configuration.
|
|
27
|
+
* Defines the base field library available to all services within an organization.
|
|
28
|
+
* Services reference this configuration via `appointmentFieldConfigId` and can
|
|
29
|
+
* selectively inherit, override, or extend the defined fields.
|
|
30
|
+
*/
|
|
31
|
+
export declare const AppointmentFieldConfigSchema: z.ZodObject<{
|
|
32
|
+
id: z.ZodString;
|
|
33
|
+
createdAt: z.ZodOptional<z.ZodNumber>;
|
|
34
|
+
updatedAt: z.ZodOptional<z.ZodNumber>;
|
|
35
|
+
fields: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
36
|
+
fieldKey: z.ZodString;
|
|
37
|
+
fieldType: z.ZodEnum<{
|
|
38
|
+
text: import("../type-definitions/dynamic-fields").DynamicFieldType.TEXT;
|
|
39
|
+
textarea: import("../type-definitions/dynamic-fields").DynamicFieldType.TEXTAREA;
|
|
40
|
+
number: import("../type-definitions/dynamic-fields").DynamicFieldType.NUMBER;
|
|
41
|
+
boolean: import("../type-definitions/dynamic-fields").DynamicFieldType.BOOLEAN;
|
|
42
|
+
date: import("../type-definitions/dynamic-fields").DynamicFieldType.DATE;
|
|
43
|
+
time: import("../type-definitions/dynamic-fields").DynamicFieldType.TIME;
|
|
44
|
+
datetime: import("../type-definitions/dynamic-fields").DynamicFieldType.DATETIME;
|
|
45
|
+
email: import("../type-definitions/dynamic-fields").DynamicFieldType.EMAIL;
|
|
46
|
+
phone: import("../type-definitions/dynamic-fields").DynamicFieldType.PHONE;
|
|
47
|
+
select: import("../type-definitions/dynamic-fields").DynamicFieldType.SELECT;
|
|
48
|
+
multiselect: import("../type-definitions/dynamic-fields").DynamicFieldType.MULTISELECT;
|
|
49
|
+
}>;
|
|
50
|
+
label: z.ZodString;
|
|
51
|
+
description: z.ZodOptional<z.ZodString>;
|
|
52
|
+
validation: z.ZodOptional<z.ZodObject<{
|
|
53
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
54
|
+
minLength: z.ZodOptional<z.ZodNumber>;
|
|
55
|
+
maxLength: z.ZodOptional<z.ZodNumber>;
|
|
56
|
+
min: z.ZodOptional<z.ZodNumber>;
|
|
57
|
+
max: z.ZodOptional<z.ZodNumber>;
|
|
58
|
+
pattern: z.ZodOptional<z.ZodString>;
|
|
59
|
+
patternMessage: z.ZodOptional<z.ZodString>;
|
|
60
|
+
}, z.core.$strip>>;
|
|
61
|
+
uiHints: z.ZodOptional<z.ZodObject<{
|
|
62
|
+
placeholder: z.ZodOptional<z.ZodString>;
|
|
63
|
+
helpText: z.ZodOptional<z.ZodString>;
|
|
64
|
+
displayOrder: z.ZodOptional<z.ZodNumber>;
|
|
65
|
+
width: z.ZodOptional<z.ZodEnum<{
|
|
66
|
+
full: "full";
|
|
67
|
+
half: "half";
|
|
68
|
+
third: "third";
|
|
69
|
+
}>>;
|
|
70
|
+
}, z.core.$strip>>;
|
|
71
|
+
options: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
72
|
+
value: z.ZodString;
|
|
73
|
+
label: z.ZodString;
|
|
74
|
+
displayOrder: z.ZodOptional<z.ZodNumber>;
|
|
75
|
+
}, z.core.$strip>>>;
|
|
76
|
+
defaultValue: z.ZodOptional<z.ZodAny>;
|
|
77
|
+
isActive: z.ZodOptional<z.ZodBoolean>;
|
|
78
|
+
condition: z.ZodOptional<z.ZodObject<{
|
|
79
|
+
dependsOn: z.ZodString;
|
|
80
|
+
operator: z.ZodEnum<{
|
|
81
|
+
equals: "equals";
|
|
82
|
+
notEquals: "notEquals";
|
|
83
|
+
contains: "contains";
|
|
84
|
+
isEmpty: "isEmpty";
|
|
85
|
+
isNotEmpty: "isNotEmpty";
|
|
86
|
+
greaterThan: "greaterThan";
|
|
87
|
+
lessThan: "lessThan";
|
|
88
|
+
}>;
|
|
89
|
+
value: z.ZodOptional<z.ZodAny>;
|
|
90
|
+
}, z.core.$strip>>;
|
|
91
|
+
groupKey: z.ZodOptional<z.ZodString>;
|
|
92
|
+
}, z.core.$strip>>>;
|
|
93
|
+
groups: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
94
|
+
groupKey: z.ZodString;
|
|
95
|
+
label: z.ZodString;
|
|
96
|
+
description: z.ZodOptional<z.ZodString>;
|
|
97
|
+
displayOrder: z.ZodOptional<z.ZodNumber>;
|
|
98
|
+
collapsible: z.ZodOptional<z.ZodBoolean>;
|
|
99
|
+
defaultCollapsed: z.ZodOptional<z.ZodBoolean>;
|
|
100
|
+
}, z.core.$strip>>>;
|
|
101
|
+
reuseDetails: z.ZodDefault<z.ZodBoolean>;
|
|
102
|
+
ensureEmail: z.ZodDefault<z.ZodBoolean>;
|
|
103
|
+
ensurePhone: z.ZodDefault<z.ZodBoolean>;
|
|
104
|
+
}, z.core.$strip>;
|
|
105
|
+
export type AppointmentFieldConfig = z.infer<typeof AppointmentFieldConfigSchema>;
|
|
106
|
+
export declare const CreateAppointmentFieldConfigSchema: z.ZodObject<{
|
|
107
|
+
id: z.ZodString;
|
|
108
|
+
fields: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
109
|
+
fieldKey: z.ZodString;
|
|
110
|
+
fieldType: z.ZodEnum<{
|
|
111
|
+
text: import("../type-definitions/dynamic-fields").DynamicFieldType.TEXT;
|
|
112
|
+
textarea: import("../type-definitions/dynamic-fields").DynamicFieldType.TEXTAREA;
|
|
113
|
+
number: import("../type-definitions/dynamic-fields").DynamicFieldType.NUMBER;
|
|
114
|
+
boolean: import("../type-definitions/dynamic-fields").DynamicFieldType.BOOLEAN;
|
|
115
|
+
date: import("../type-definitions/dynamic-fields").DynamicFieldType.DATE;
|
|
116
|
+
time: import("../type-definitions/dynamic-fields").DynamicFieldType.TIME;
|
|
117
|
+
datetime: import("../type-definitions/dynamic-fields").DynamicFieldType.DATETIME;
|
|
118
|
+
email: import("../type-definitions/dynamic-fields").DynamicFieldType.EMAIL;
|
|
119
|
+
phone: import("../type-definitions/dynamic-fields").DynamicFieldType.PHONE;
|
|
120
|
+
select: import("../type-definitions/dynamic-fields").DynamicFieldType.SELECT;
|
|
121
|
+
multiselect: import("../type-definitions/dynamic-fields").DynamicFieldType.MULTISELECT;
|
|
122
|
+
}>;
|
|
123
|
+
label: z.ZodString;
|
|
124
|
+
description: z.ZodOptional<z.ZodString>;
|
|
125
|
+
validation: z.ZodOptional<z.ZodObject<{
|
|
126
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
127
|
+
minLength: z.ZodOptional<z.ZodNumber>;
|
|
128
|
+
maxLength: z.ZodOptional<z.ZodNumber>;
|
|
129
|
+
min: z.ZodOptional<z.ZodNumber>;
|
|
130
|
+
max: z.ZodOptional<z.ZodNumber>;
|
|
131
|
+
pattern: z.ZodOptional<z.ZodString>;
|
|
132
|
+
patternMessage: z.ZodOptional<z.ZodString>;
|
|
133
|
+
}, z.core.$strip>>;
|
|
134
|
+
uiHints: z.ZodOptional<z.ZodObject<{
|
|
135
|
+
placeholder: z.ZodOptional<z.ZodString>;
|
|
136
|
+
helpText: z.ZodOptional<z.ZodString>;
|
|
137
|
+
displayOrder: z.ZodOptional<z.ZodNumber>;
|
|
138
|
+
width: z.ZodOptional<z.ZodEnum<{
|
|
139
|
+
full: "full";
|
|
140
|
+
half: "half";
|
|
141
|
+
third: "third";
|
|
142
|
+
}>>;
|
|
143
|
+
}, z.core.$strip>>;
|
|
144
|
+
options: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
145
|
+
value: z.ZodString;
|
|
146
|
+
label: z.ZodString;
|
|
147
|
+
displayOrder: z.ZodOptional<z.ZodNumber>;
|
|
148
|
+
}, z.core.$strip>>>;
|
|
149
|
+
defaultValue: z.ZodOptional<z.ZodAny>;
|
|
150
|
+
isActive: z.ZodOptional<z.ZodBoolean>;
|
|
151
|
+
condition: z.ZodOptional<z.ZodObject<{
|
|
152
|
+
dependsOn: z.ZodString;
|
|
153
|
+
operator: z.ZodEnum<{
|
|
154
|
+
equals: "equals";
|
|
155
|
+
notEquals: "notEquals";
|
|
156
|
+
contains: "contains";
|
|
157
|
+
isEmpty: "isEmpty";
|
|
158
|
+
isNotEmpty: "isNotEmpty";
|
|
159
|
+
greaterThan: "greaterThan";
|
|
160
|
+
lessThan: "lessThan";
|
|
161
|
+
}>;
|
|
162
|
+
value: z.ZodOptional<z.ZodAny>;
|
|
163
|
+
}, z.core.$strip>>;
|
|
164
|
+
groupKey: z.ZodOptional<z.ZodString>;
|
|
165
|
+
}, z.core.$strip>>>;
|
|
166
|
+
groups: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
167
|
+
groupKey: z.ZodString;
|
|
168
|
+
label: z.ZodString;
|
|
169
|
+
description: z.ZodOptional<z.ZodString>;
|
|
170
|
+
displayOrder: z.ZodOptional<z.ZodNumber>;
|
|
171
|
+
collapsible: z.ZodOptional<z.ZodBoolean>;
|
|
172
|
+
defaultCollapsed: z.ZodOptional<z.ZodBoolean>;
|
|
173
|
+
}, z.core.$strip>>>;
|
|
174
|
+
reuseDetails: z.ZodDefault<z.ZodBoolean>;
|
|
175
|
+
ensureEmail: z.ZodDefault<z.ZodBoolean>;
|
|
176
|
+
ensurePhone: z.ZodDefault<z.ZodBoolean>;
|
|
177
|
+
}, z.core.$strip>;
|
|
178
|
+
export type CreateAppointmentFieldConfig = z.infer<typeof CreateAppointmentFieldConfigSchema>;
|
|
179
|
+
export declare const UpdateAppointmentFieldConfigSchema: z.ZodObject<{
|
|
180
|
+
fields: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
181
|
+
fieldKey: z.ZodString;
|
|
182
|
+
fieldType: z.ZodEnum<{
|
|
183
|
+
text: import("../type-definitions/dynamic-fields").DynamicFieldType.TEXT;
|
|
184
|
+
textarea: import("../type-definitions/dynamic-fields").DynamicFieldType.TEXTAREA;
|
|
185
|
+
number: import("../type-definitions/dynamic-fields").DynamicFieldType.NUMBER;
|
|
186
|
+
boolean: import("../type-definitions/dynamic-fields").DynamicFieldType.BOOLEAN;
|
|
187
|
+
date: import("../type-definitions/dynamic-fields").DynamicFieldType.DATE;
|
|
188
|
+
time: import("../type-definitions/dynamic-fields").DynamicFieldType.TIME;
|
|
189
|
+
datetime: import("../type-definitions/dynamic-fields").DynamicFieldType.DATETIME;
|
|
190
|
+
email: import("../type-definitions/dynamic-fields").DynamicFieldType.EMAIL;
|
|
191
|
+
phone: import("../type-definitions/dynamic-fields").DynamicFieldType.PHONE;
|
|
192
|
+
select: import("../type-definitions/dynamic-fields").DynamicFieldType.SELECT;
|
|
193
|
+
multiselect: import("../type-definitions/dynamic-fields").DynamicFieldType.MULTISELECT;
|
|
194
|
+
}>;
|
|
195
|
+
label: z.ZodString;
|
|
196
|
+
description: z.ZodOptional<z.ZodString>;
|
|
197
|
+
validation: z.ZodOptional<z.ZodObject<{
|
|
198
|
+
required: z.ZodOptional<z.ZodBoolean>;
|
|
199
|
+
minLength: z.ZodOptional<z.ZodNumber>;
|
|
200
|
+
maxLength: z.ZodOptional<z.ZodNumber>;
|
|
201
|
+
min: z.ZodOptional<z.ZodNumber>;
|
|
202
|
+
max: z.ZodOptional<z.ZodNumber>;
|
|
203
|
+
pattern: z.ZodOptional<z.ZodString>;
|
|
204
|
+
patternMessage: z.ZodOptional<z.ZodString>;
|
|
205
|
+
}, z.core.$strip>>;
|
|
206
|
+
uiHints: z.ZodOptional<z.ZodObject<{
|
|
207
|
+
placeholder: z.ZodOptional<z.ZodString>;
|
|
208
|
+
helpText: z.ZodOptional<z.ZodString>;
|
|
209
|
+
displayOrder: z.ZodOptional<z.ZodNumber>;
|
|
210
|
+
width: z.ZodOptional<z.ZodEnum<{
|
|
211
|
+
full: "full";
|
|
212
|
+
half: "half";
|
|
213
|
+
third: "third";
|
|
214
|
+
}>>;
|
|
215
|
+
}, z.core.$strip>>;
|
|
216
|
+
options: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
217
|
+
value: z.ZodString;
|
|
218
|
+
label: z.ZodString;
|
|
219
|
+
displayOrder: z.ZodOptional<z.ZodNumber>;
|
|
220
|
+
}, z.core.$strip>>>;
|
|
221
|
+
defaultValue: z.ZodOptional<z.ZodAny>;
|
|
222
|
+
isActive: z.ZodOptional<z.ZodBoolean>;
|
|
223
|
+
condition: z.ZodOptional<z.ZodObject<{
|
|
224
|
+
dependsOn: z.ZodString;
|
|
225
|
+
operator: z.ZodEnum<{
|
|
226
|
+
equals: "equals";
|
|
227
|
+
notEquals: "notEquals";
|
|
228
|
+
contains: "contains";
|
|
229
|
+
isEmpty: "isEmpty";
|
|
230
|
+
isNotEmpty: "isNotEmpty";
|
|
231
|
+
greaterThan: "greaterThan";
|
|
232
|
+
lessThan: "lessThan";
|
|
233
|
+
}>;
|
|
234
|
+
value: z.ZodOptional<z.ZodAny>;
|
|
235
|
+
}, z.core.$strip>>;
|
|
236
|
+
groupKey: z.ZodOptional<z.ZodString>;
|
|
237
|
+
}, z.core.$strip>>>>;
|
|
238
|
+
groups: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
239
|
+
groupKey: z.ZodString;
|
|
240
|
+
label: z.ZodString;
|
|
241
|
+
description: z.ZodOptional<z.ZodString>;
|
|
242
|
+
displayOrder: z.ZodOptional<z.ZodNumber>;
|
|
243
|
+
collapsible: z.ZodOptional<z.ZodBoolean>;
|
|
244
|
+
defaultCollapsed: z.ZodOptional<z.ZodBoolean>;
|
|
245
|
+
}, z.core.$strip>>>>;
|
|
246
|
+
reuseDetails: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
247
|
+
ensureEmail: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
248
|
+
ensurePhone: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
249
|
+
id: z.ZodString;
|
|
250
|
+
}, z.core.$strip>;
|
|
251
|
+
export type UpdateAppointmentFieldConfig = z.infer<typeof UpdateAppointmentFieldConfigSchema>;
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UpdateAppointmentFieldConfigSchema = exports.CreateAppointmentFieldConfigSchema = exports.AppointmentFieldConfigSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const base_schema_1 = require("../base.schema");
|
|
6
|
+
const dynamic_fields_1 = require("../type-definitions/dynamic-fields");
|
|
7
|
+
/**
|
|
8
|
+
* @fileoverview Organization-level appointment field configuration schema.
|
|
9
|
+
* @module business-mgt/appointment-field-config
|
|
10
|
+
*
|
|
11
|
+
* This schema represents the **Organization Level** in the dynamic fields hierarchy:
|
|
12
|
+
*
|
|
13
|
+
* ```
|
|
14
|
+
* Organization Level (AppointmentFieldConfigSchema) ← THIS SCHEMA
|
|
15
|
+
* │
|
|
16
|
+
* ▼ inherits via appointmentFieldConfigId
|
|
17
|
+
* Service Level (ServiceAppointmentFieldConfigSchema)
|
|
18
|
+
* │
|
|
19
|
+
* ▼ stores values
|
|
20
|
+
* Appointment Level (AppointmentAdditionalInfoSchema)
|
|
21
|
+
* ```
|
|
22
|
+
*
|
|
23
|
+
* Defines the base field library that can be reused across multiple services
|
|
24
|
+
* within an organization. Services can inherit fields from this configuration
|
|
25
|
+
* and optionally override specific properties or add service-specific fields.
|
|
26
|
+
*
|
|
27
|
+
* @see ServiceAppointmentFieldConfigSchema - Service-level field customization
|
|
28
|
+
* @see AppointmentAdditionalInfoSchema - Stores captured field values
|
|
29
|
+
*/
|
|
30
|
+
/**
|
|
31
|
+
* Organization-level appointment field configuration.
|
|
32
|
+
* Defines the base field library available to all services within an organization.
|
|
33
|
+
* Services reference this configuration via `appointmentFieldConfigId` and can
|
|
34
|
+
* selectively inherit, override, or extend the defined fields.
|
|
35
|
+
*/
|
|
36
|
+
exports.AppointmentFieldConfigSchema = base_schema_1.BaseModelSchema.safeExtend({
|
|
37
|
+
fields: zod_1.z.array(dynamic_fields_1.FieldDefinitionSchema).default([]).describe("Array of field definitions available at the organization level. Each field has a unique fieldKey, fieldType (text, number, date, etc.), label, and optional validation/UI hints. Services can inherit these fields via inheritedFieldKeys."),
|
|
38
|
+
groups: zod_1.z.array(dynamic_fields_1.FieldGroupSchema).default([]).describe("Logical groupings for organizing fields into sections (e.g., 'Contact Information', 'Medical History'). Each group has a groupKey, label, and optional display settings like collapsible and displayOrder. Fields reference groups via their groupKey property."),
|
|
39
|
+
reuseDetails: zod_1.z.boolean().default(false).describe("When true, indicates that captured field data can be reused across appointments for the same customer. Enables pre-populating fields for returning customers to reduce redundant data entry."),
|
|
40
|
+
ensureEmail: zod_1.z.boolean().default(false).describe("When true, ensures an email field is always included in the field configuration, even if not explicitly defined. Useful for organizations that require email for all appointments."),
|
|
41
|
+
ensurePhone: zod_1.z.boolean().default(false).describe("When true, ensures a phone field is always included in the field configuration, even if not explicitly defined. Useful for organizations that require phone contact for all appointments."),
|
|
42
|
+
});
|
|
43
|
+
exports.CreateAppointmentFieldConfigSchema = exports.AppointmentFieldConfigSchema.omit({
|
|
44
|
+
createdAt: true,
|
|
45
|
+
updatedAt: true,
|
|
46
|
+
});
|
|
47
|
+
exports.UpdateAppointmentFieldConfigSchema = exports.CreateAppointmentFieldConfigSchema.partial().safeExtend({
|
|
48
|
+
id: zod_1.z.string(),
|
|
49
|
+
});
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import z from "zod";
|
|
2
|
+
/**
|
|
3
|
+
* @fileoverview Shared booking schema definitions used across services and reservations.
|
|
4
|
+
* @module business-mgt/bookings-shared
|
|
5
|
+
*/
|
|
6
|
+
/**
|
|
7
|
+
* Service deposit strategy options.
|
|
8
|
+
*
|
|
9
|
+
* @enum {string}
|
|
10
|
+
*/
|
|
11
|
+
export declare enum ServiceDepositStrategy {
|
|
12
|
+
NONE = "NONE",
|
|
13
|
+
FIXED = "FIXED",
|
|
14
|
+
PERCENTAGE = "PERCENTAGE"
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Reservation type options.
|
|
18
|
+
*
|
|
19
|
+
* @enum {string}
|
|
20
|
+
*/
|
|
21
|
+
export declare enum ReservationType {
|
|
22
|
+
Table = "TABLE",
|
|
23
|
+
Room = "ROOM",
|
|
24
|
+
Rental = "RENTAL",
|
|
25
|
+
Other = "OTHER"
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Service booking rules schema.
|
|
29
|
+
* Configures online booking availability, customer restrictions, and cancellation policies.
|
|
30
|
+
*
|
|
31
|
+
* @typedef {Object} ServiceBookingRules
|
|
32
|
+
* @property {boolean} onlineEnabled - Whether online booking is enabled
|
|
33
|
+
* @property {boolean} existingOnly - Whether only existing customers can book
|
|
34
|
+
* @property {boolean} requiresConsult - Whether a consultation is required before booking
|
|
35
|
+
* @property {number} maxDaysOut - Max days in advance this can be booked
|
|
36
|
+
* @property {number} minNoticeHours - Minimum booking notice in hours
|
|
37
|
+
* @property {number} lateCancelHours - Late cancellation threshold in hours
|
|
38
|
+
*/
|
|
39
|
+
export declare const ServiceBookingRulesSchema: z.ZodObject<{
|
|
40
|
+
onlineEnabled: z.ZodDefault<z.ZodBoolean>;
|
|
41
|
+
existingOnly: z.ZodDefault<z.ZodBoolean>;
|
|
42
|
+
requiresConsult: z.ZodDefault<z.ZodBoolean>;
|
|
43
|
+
maxDaysOut: z.ZodDefault<z.ZodNumber>;
|
|
44
|
+
minNoticeHours: z.ZodDefault<z.ZodNumber>;
|
|
45
|
+
lateCancelHours: z.ZodDefault<z.ZodNumber>;
|
|
46
|
+
}, z.core.$strip>;
|
|
47
|
+
export type ServiceBookingRules = z.infer<typeof ServiceBookingRulesSchema>;
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.ServiceBookingRulesSchema = exports.ReservationType = exports.ServiceDepositStrategy = void 0;
|
|
7
|
+
const zod_1 = __importDefault(require("zod"));
|
|
8
|
+
/**
|
|
9
|
+
* @fileoverview Shared booking schema definitions used across services and reservations.
|
|
10
|
+
* @module business-mgt/bookings-shared
|
|
11
|
+
*/
|
|
12
|
+
// ============================================================================
|
|
13
|
+
// ENUMS
|
|
14
|
+
// ============================================================================
|
|
15
|
+
/**
|
|
16
|
+
* Service deposit strategy options.
|
|
17
|
+
*
|
|
18
|
+
* @enum {string}
|
|
19
|
+
*/
|
|
20
|
+
var ServiceDepositStrategy;
|
|
21
|
+
(function (ServiceDepositStrategy) {
|
|
22
|
+
ServiceDepositStrategy["NONE"] = "NONE";
|
|
23
|
+
ServiceDepositStrategy["FIXED"] = "FIXED";
|
|
24
|
+
ServiceDepositStrategy["PERCENTAGE"] = "PERCENTAGE";
|
|
25
|
+
})(ServiceDepositStrategy || (exports.ServiceDepositStrategy = ServiceDepositStrategy = {}));
|
|
26
|
+
/**
|
|
27
|
+
* Reservation type options.
|
|
28
|
+
*
|
|
29
|
+
* @enum {string}
|
|
30
|
+
*/
|
|
31
|
+
var ReservationType;
|
|
32
|
+
(function (ReservationType) {
|
|
33
|
+
ReservationType["Table"] = "TABLE";
|
|
34
|
+
ReservationType["Room"] = "ROOM";
|
|
35
|
+
ReservationType["Rental"] = "RENTAL";
|
|
36
|
+
ReservationType["Other"] = "OTHER";
|
|
37
|
+
})(ReservationType || (exports.ReservationType = ReservationType = {}));
|
|
38
|
+
// ============================================================================
|
|
39
|
+
// SERVICE BOOKING RULES SCHEMA
|
|
40
|
+
// ============================================================================
|
|
41
|
+
/**
|
|
42
|
+
* Service booking rules schema.
|
|
43
|
+
* Configures online booking availability, customer restrictions, and cancellation policies.
|
|
44
|
+
*
|
|
45
|
+
* @typedef {Object} ServiceBookingRules
|
|
46
|
+
* @property {boolean} onlineEnabled - Whether online booking is enabled
|
|
47
|
+
* @property {boolean} existingOnly - Whether only existing customers can book
|
|
48
|
+
* @property {boolean} requiresConsult - Whether a consultation is required before booking
|
|
49
|
+
* @property {number} maxDaysOut - Max days in advance this can be booked
|
|
50
|
+
* @property {number} minNoticeHours - Minimum booking notice in hours
|
|
51
|
+
* @property {number} lateCancelHours - Late cancellation threshold in hours
|
|
52
|
+
*/
|
|
53
|
+
exports.ServiceBookingRulesSchema = zod_1.default.object({
|
|
54
|
+
onlineEnabled: zod_1.default.boolean().default(true).describe("Whether online booking is enabled"),
|
|
55
|
+
existingOnly: zod_1.default.boolean().default(false).describe("Whether only existing customers can book"),
|
|
56
|
+
requiresConsult: zod_1.default.boolean().default(false).describe("Whether a consultation is required before booking"),
|
|
57
|
+
maxDaysOut: zod_1.default.number().int().positive().default(30).describe("Max days in advance this can be booked"),
|
|
58
|
+
minNoticeHours: zod_1.default.number().int().nonnegative().default(0).describe("Minimum booking notice in hours"),
|
|
59
|
+
lateCancelHours: zod_1.default.number().int().nonnegative().default(24).describe("Late cancellation threshold in hours"),
|
|
60
|
+
});
|