- Introduced `last_submitted_form` and `form_submission` properties in the `form` class to retain details of the most recently submitted form.
- Updated form submission logic to assign `booking_object` where applicable.
- Enhanced response in `formRoute.php` to include booking data when available.
Introduced endpoints for fetching and setting department variables in `superuserDepartmentRoute`. Enhanced `getDepartmentOptions` to filter by specific positive variables. Updated SMS notifications and booking forms to utilize department variables for improved flexibility.
Commented out the transaction creation step for bookings to prevent unnecessary or redundant transactions. This ensures the booking process focuses solely on wash certificate completion and status updates without altering the transactional state.
Added support for including customer name, department name, and parsed services in `asArray()` method. Introduced functionality for creating transactions, linking bookings to orders, and properly handling related services. Improved department daily report handling and removed unnecessary fields.
Refactored notification methods to handle Slack, SMS, and email delivery logic more effectively. Introduced `sendBookingNotification` email functionality and a new template for booking notifications. Improved handling of booking data for emails and centralized logic for retrieving booking details.
Implemented functionality to split collected order invoices, ensuring proper validation and handling processor constraints. Added a notification system to inform departments about new bookings via Slack or SMS. Also, included minor enhancements such as a corrected Gateway API URL and improved form handling for wash certificate emails.
Replaced raw SQL with a consolidated object-based approach for adding bookings, enhancing maintainability and reducing redundancy. Adjusted form handling to include stricter type casting, additional property checks, and default fallbacks for wash certificate data. These changes improve code readability and error handling while ensuring consistent data processing.
Commented out unused cron tasks 'CheckUnfulfilledBookings' and 'SyncBookings' in the cron configuration. Also removed a debug print statement from the booking wash form to clean up the code.
Introduced a method to handle the sending of wash certificates via email for bookings with valid certificates. Updated the wash certificate generation process to trigger this new functionality automatically.
The `book_interior_wash_f` form was removed due to redundancy. Added functionality to handle wash certificate generation, including safety seal and operator data, and added a new form `complete_booking_f` to finalize bookings without certificates. Adjustments were made to several related components to ensure seamless integration.
Introduced `sendWashCertificateEmail` method to handle email dispatch, including necessary exception handling for MailerSend. Updated the wash booking form text to enhance clarity and ensure appropriate instructions in Danish.
Introduced support for a `data` property in bookings, extended form handling with additional validation and input fields, and added functionality for retrieving booking counts by date and status. Improved safety seal labeling and enhanced PDF generation comments.
This commit introduces changes to include branding information in departments. Updates were made to routes, forms, and objects to handle branding IDs and enforce validation. Additionally, a method call was added to track object changes when branding is updated.
Introduced a new branding functionality, including a `branding_o` object, `create_branding_f` form, and associated routes in `BrandingRoute`. Refactored the forms directory for better organization and added support for branding in departments. Extended validation, object handling, and response handling to accommodate this new feature.
Introduces a form for generating wash certificates associated with bookings, along with validations and access restrictions. Refactors booking management to integrate a new `bookings_new_o` class, enhancing structure and adding functionalities like caching and detailed error handling.
Introduce `BOOK_INTERIOR_WASH` functionality with new input fields, setup, and email confirmations in the booking process. Refactor form validation to include advanced field metadata, conditional display logic, and stricter validation requirements. Implement reusable methods for field requirement checks, sanitization, and dynamic metadata handling for better form management.
Implemented a new booking confirmation email template and its integration with email sending functionality. Updated form handling to trigger confirmation email after submission and enhanced error handling on department validation.
Introduced a new `customer_number` property across the form handling codebase, enabling forms to store and manage customer numbers where applicable. Updated methods to handle this property, including sanitization, validation, and saving processes. Added a `beforeSave` method to set `customer_number` during form submission.
Added support for defining and retrieving form field options, along with methods to manage field-specific configurations. Enhanced invoice draft generation to handle discounts, including the ability to calculate total discounts and display them as separate lines. These updates improve flexibility in forms and invoice processing.
Implemented a robust form management system with validation, sanitization, and database integration. Added reusable traits, classes, and methods to define, submit, and process forms. Introduced a "Book a Wash" form as an example implementation.