- Introduced Writerside topics for multiple endpoints in the Bookings module, including user, admin, and public time booking routes.
- Added `Bookings_OpenAPIv1.json` specification defining API paths, schemas, and security configurations.
- Included endpoint details for operations like booking retrieval, updates, deletion, syncing, and timebookings.
- Implement Bird API client (`bird.php`) for handling HTTP requests to Bird services.
- Add routes for voice and flash call management (`birdVoiceFlashCallsRoute.php`, `birdNumbersRoute.php`).
- Introduce test cases for voice calls, flash calls, and numbers (`VoiceCallsApiTest.php`, `NumbersAndFlashCallsApiTest.php`).
- Include configuration management classes and APIs for enabling the Bird module and managing API keys (`bird_c.php`).
- Provide OpenAPI specifications for flash call endpoints (`bird-flash-calls.md`).
- Implement emergency operations to forcibly enable or disable MACHINE relays (`forceTurnOnMachineRelay`).
- Add OpenAPI specifications for `/modules/self-serve/lane/force/machine/enable` and `/modules/self-serve/lane/force/machine/disable`.
- Update route definitions and introduce validation for input parameters.
- Introduce a minimal, self-contained test to ensure the relay turns off when STOP is executed.
- Enhance `selfserve_lane_command_t` to handle relay shutdown based on department configuration.
- Include `isDepartmentSelfServeEnabled` method for testing override and I/O avoidance.
- Refactor header and footer to support Outlook Classic (MSO) rendering.
- Adjust logo sizing, alignment, and styles for improved consistency.
- Update inline styles for better cross-platform email rendering.
- Add `SelfserveLaneServicesEnumTest` to validate `selfserve_lane_services` cases.
- Update `index.php` to load self-serve module interfaces, traits, classes, helpers, and configs.
- Center Truck Wash logo in email header and adjust styling.
- Localize password reset error message in `authRoute.php` with Danish text.
- Add `.junie/guidelines.md` with comprehensive development instructions.
- Include `.aiassistant/rules/Creating and maintaining tests.md` and `.aiassistant/rules/Creating and securing routes.md`.
- Introduce `CACHE_SELFSERVE_LANE_KEY_ALLOWED_SERVICES` for lane service validation.
- Update `selfserve_lane_relay_controller_t` to enforce service-specific permissions for machine relay.
- Introduce `services` property to `department_selfserve_tasks_o` for task-specific functionalities.
- Add service validation and normalization via `selfserve_lane_services` enum.
- Extend `departmentSelfserveTasksRoute` to handle `services` input for add/edit operations.
- Create `selfserve_lane_services` enum to define and validate service types.
- Update welcome email template to conditionally include corporate ID.
- Remove unused base64 signature utility and clean up the email class.
- Comment out attachments array for potential future updates.
- Dynamically insert company name and corporate ID in welcome message.
- Replace signature image URLs with updated assets and ensure proper loading.
- Add utility for retrieving base64-encoded signatures to enhance flexibility.
- Update `subusersRoute` to support subuser authentication and permission checks dynamically.
- Add new permission nodes (`SELFSERVE_LIST`, `SELFSERVE_EDIT`, `SELFSERVE_DELETE`) in `subusers_permission_node_key`.
- Fix typos in vehicle permission constants and ensure proper resolution.
- Enhance `vehiclesRoute` with effective customer context and scoped permission checks.
- Localize new permission nodes with descriptions in Danish.
- Integrate `subusers_permission_node_key` for dynamic subuser-specific permission checks.
- Refactor authentication and permission logic to streamline checks for own vs. department-level access.
- Simplify error handling and enforce scoped permissions for vehicles, orders, and their attachments.
- Localize permission labels and descriptions to Danish for relevant modules.
- Add reusable helpers: `isOwnCustomerContext`, `resolveEffectiveCustomerNumber`, and `allowOwnOrDepartmentAccess` in `route_t` for streamlined permission checks.
- Replace inlined permission logic in `orderBookingRoute` with common helpers for creating, viewing, editing, and deleting bookings.
- Localize permission names, descriptions, and labels to Danish across relevant modules.
- Improve error handling and simplify context resolution for subuser and department-level permissions.
- Add `permission_node` DTO to link classic permissions with subuser-specific nodes.
- Extend `authentication` to support subuser resolution via tokens.
- Introduce route traits for permission evaluation with subuser context.
- Update `requirePermission` and `hasPermission` to handle subuser grants dynamically.
- Implement fallback mechanisms for customer number context in subuser permissions.
- Introduce a comprehensive permission system for subusers, including permission nodes and types with support for vehicles, bookings, orders, subusers, and self-serve modules.
- Implement `subusers_user`, `subuser_user_grant`, and `subusers_permission_node` classes for managing subuser permissions and grants.
- Extend `subuser_grants_o` with methods to retrieve permissions for subusers linked to customers.
- Add traits and enumerations to streamline permission handling across modules.
- Update subuser session handling to include token-based subuser lookups.
- Introduce `economic_invoice_booked` helper for normalizing booked invoice data.
- Add `getFromId` method to fetch booked invoice details by ID.
- Extend `economic` class with `getInvoiceBookedFromExternalId` for external ID-based retrieval.
- Update imports and economic helper class registrations to include booked invoice functionality.
- Introduce `periodLines` array for improved clarity and logic separation.
- Update total expression to include period label for better formatting.
- Move department lines and blanks to `periodLines` and merge into output at the end of each period.
- Swap `send_message` with `send_webhook_message` to fix departmental Slack notification issues.
- Adjust `COUNT_ONLY` in `renderDanishPeriodSummary` to exclude targets for raw count-focused alerts.
- Replace immutable/mutable `DateTime` conversions with safer handling in target and progress calculations.
- Update `getDailyTarget` to normalize timeframes and improve operating day computations.
- Refine department-specific target calculation logic for enhanced accuracy in multi-department setups.
- Simplify multi-period department progress calculations by restructuring logic to render by period first.
- Add support for daily target calculations and timeframe-based target adjustments in `goals_criteria`.
- Introduce `countOperatingDaysInTimeframe` and related helper methods for improved alert scheduling and progress tracking.
- Add cloning logic in `withDepartmentFilter` to avoid mutating original `goals_criteria` objects.
- Rename method parameter in `render` and refactor `renderDanishPeriodSummary` for enhanced readability and flexibility.
- Introduce helper methods for date range and criteria window adjustments to streamline department progress calculations.
- Replace `send_webhook_message` with `send_message` for improved Slack notification rendering using `goals_progress_alert_renderer`.
- Add methods for calculating and retrieving departmental progress and distribution in `goals_criteria`.
- Update `renderDanishPeriodSummary` and Slack cron logic to support departmental-specific summaries.
- Include departmental progress in serialized goal objects for better reporting.
- Update `drawCropOutLine` to accept a `crop` parameter for conditional cropping alongside outline rendering.
- Adjust crop outline coordinates for improved alignment.
- Introduce logic to calculate and apply crop dimensions when `crop` is enabled.
- Introduce `drawLine` method in `dynamicimages_image_t` for drawing lines with customizable styles (color, thickness, dash patterns).
- Update `drawCropOutLine` in `machine_1` to use a dynamic configuration for rendering top, left, right, and bottom crop outlines.
- Refactor crop outline logic for better readability and maintainability.
- Implement `drawCropOutLine` method for rendering horizontal crop outlines in machine images.
- Refactor `drawStepCounterOnButton` with dynamic font sizing and fallback handling for better text alignment.
- Add step counter rendering in top-right position for enhanced button visuals.
- Update `exampleRoute` debugging logic to integrate new `machine_1` functionality.
- Replace old debug assets with new button highlight state assets.
- Introduce `only_generate_current_step` property to conditionally skip non-relevant button highlights during rendering.
- Update button rendering methods to respect the `only_generate_current_step` flag for improved efficiency.
- Adjust logic in `drawHighlightedButtons` and related functions to check current step before drawing assets.
- Introduce `drawHighlightedStartButton` method for dynamic rendering of the start button with step indicators.
- Add new constants for `IMAGE_BUTTON_HIGHLIGHTED_GREEN`, `IMAGE_BUTTON_HIGHLIGHTED_GREY`, and `IMAGE_BUTTON_HIGHLIGHTED_COMPLETED`.
- Refactor `getHighlightedAssetName` to provide conditional asset selection based on step completion.
- Implement `drawStepThumb` for rendering step indicators on the washing thumb.
- Adjust highlighted button logic to dynamically incorporate step counts and completion states.
- Add new assets for highlighted button states (`completed`, `green`, `grey`).
- Adjust badge center calculations for improved alignment based on asset layout.
- Temporarily disable optical nudge calibration for badge centering.
- Add debug crosshair overlays to validate badge and text anchor points during rendering.
- Redesign badge positioning with dynamic calculations for better alignment.
- Implement optical centering and text-size adjustments based on badge dimensions.
- Improve font size optimization with iterative refinement and fallback handling.
- Add `normalizeColor` method in `dynamicimages_asset_t` for consistent color input handling across strings, arrays, and defaults.
- Update text overlay to use the new `normalizeColor` method, improving flexibility and robustness.
- Refactor `machine_1` button step counter to calculate font size dynamically and use RGBA colors.
- Adjust `drawStepCounterOnButton` to improve text alignment and styling.
- Introduce `addTextOverlay` method in `dynamicimages_asset_t` for adding customizable text overlays with alignment and styling options.
- Add `getFontPath` method in `dynamicimages_image_t` for resolving font paths under the shared assets directory.
- Refactor `machine_1` to use `drawStepCounterOnButton` for adding dynamic step counters to buttons.
- Rename and relocate `AlfaSlabOne-Regular.ttf` under `assets/fonts`.
- Introduce `drawHighlightedResetButton` method for dynamically rendering the reset button with text overlay.
- Add `IMAGE_BUTTON_HIGHLIGHTED_BLUE` constant and update asset usage for reset button rendering.
- Refine highlighted button positioning with per-row spacing adjustments and configurable highlight states.
- Add `getNextButtonStepCount` method for tracking button steps during rendering.
- Introduce `drawHighlightedButtons` method for drawing button grids based on configurable rows, columns, and spacing.
- Add new constants for button size, spacing, and grid dimensions.
- Update asset usage to include `machine_1_button_highlighted_transparent`.
- Replace `IMAGE_WASH_PROGRAMS` with `IMAGE_PROGRAMS_WHEEL` and add `IMAGE_BUTTON_HIGHLIGHTED`.
- Introduce `drawProgramWheel` and `drawThumb` methods for improved modularity.
- Adjust thumb properties (`$thumb_position`, `$thumb_size`) and refine positioning logic.
- Update asset loading to include the new `machine_1_button_highlighted_transparent` asset.
- Introduce `drawAssetCentered` method in `dynamicimages_image_t` for drawing assets visually centered on specified coordinates.
- Reset virtual canvas/page after image rotation in both `dynamicimages_asset_t` and `dynamicimages_image_t` to ensure consistent positioning.
- Update `machine_1` logic to use `drawAssetCentered` for improved thumb drawing and dynamic pivot alignment.
- Adjust thumb rotation calculations and positioning logic for better visual rendering.
- Introduce `resize` method in `dynamicimages_asset_t` for resizing assets in memory with or without aspect ratio preservation.
- Refine `machine_1` rendering logic to dynamically calculate and apply thumb width based on height.