- Introduced a new 'subscription_rewards' relation in both the customer and subscription history schemas to link them with subscription rewards.
- Updated the 'expiresAt' field in the subscription schema to be required, ensuring better data integrity.
- Adjusted the default value for 'maxOrdersPerMonth' in the subscription setting schema from 30 to 20, and removed unused fields to streamline the model.
- Updated TypeScript definitions to reflect these changes, ensuring type safety and consistency across the application.
- Changed 'clients' to 'invited' and 'masters' to 'invitedBy' in the customer schema to better reflect their purpose in the data model.
- Updated TypeScript definitions to include the new relation fields, ensuring type safety and consistency across the application.
- Introduced a new 'days' integer field in the subscription price schema, marked as required to enhance subscription duration tracking.
- Removed unused 'description', 'trialPeriodDays', and 'trialEnabled' fields from the subscription setting schema to streamline the data model.
- Updated TypeScript definitions to reflect these changes, ensuring type safety and consistency across the application.
- Deleted the 'referralCode', 'subscription', 'referralCount', and 'referredBy' fields from the subscription schema to streamline the data model.
- Updated TypeScript definitions to reflect these changes, ensuring type safety and consistency across the application.
- Introduced a one-to-one relation for 'subscription' in the customer schema to link customers with their subscriptions.
- Added new TypeScript interfaces for subscription-related entities, including Subscription, SubscriptionHistory, SubscriptionPrice, and SubscriptionSetting, ensuring type safety and consistency across the application.
- Introduced a new 'bannedUntil' datetime field in the customer schema to track when a customer is banned until.
- Updated TypeScript definitions to include the new 'bannedUntil' attribute, ensuring type safety and consistency across the application.
- Introduced new fields 'price' and 'description' in the service schema to enhance service details.
- Updated TypeScript definitions to include these new attributes, ensuring type safety and consistency across the application.
- Added maxLength constraints to 'name' and 'phone' attributes in customer and service schemas.
- Marked 'name' as required in both schemas.
- Updated TypeScript definitions to reflect these changes.
* feat: refactor order and slot lifecycles to use datetime fields for time validation
* refactor: remove time fields from order and slot schemas to streamline data structure
* fix: correct time validation logic in order and slot lifecycles to ensure proper datetime comparisons
* fix: update order lifecycle validation to exclude only 'cancelled' state
* fix: add validation to ensure order times fall within the specified slot boundaries
* feat: integrate dayjs for improved datetime handling in order lifecycles
Нельзя завершить запись до её наступления
* fix: enhance datetime validation in order and slot lifecycles to ensure accurate comparisons
* fix: standardize error messages in order and slot lifecycles for better clarity