Details
-
Feature
-
Status: Approved (View Workflow)
-
Minor
-
Resolution: Fixed
-
None
-
None
Description
Current Situation
- General Notes: The calculation of schedule start time periods generally follows a two-step process:
- Step 1 Preliminary calculation of the matching dates based on working calendars and schedule restrictions.
- Step 2 Calculation of the start time periods for the dates obtained in Step 1, with additional consideration for non-working calendars, as non-working days can be treated differently, including:
- suppress execution (default)
- ignore non-working day
- before non-working day
- after non-working day
- Daily Plan and Schedule Show Preview
- Step 1 Note: both use a common component, FrequencyResolver.
- Daily Plan A new instance of FrequencyResolver is created for each day, using a 1-Day date range.
- Schedule Show Preview A single instance is created for the full date range (Year or Month).
- FrequencyResolver Depending on the chosen date range, the FrequencyResolver performs calculations differently, for example:
- with a year range, it is easier to calculate the workday number of a specific date since previous days have already been computed.
- with daily calculations, the component must calculate backwards or forwards for each task in order to evaluate missing days.
- Step 2 Note: This step is not normalized, and start times will be calculated based on the specific implementation.
- Daily Plan Calculation for a single day.
- Schedule Show Preview Calculation for a range of dates.
- Step 1 Note: both use a common component, FrequencyResolver.
- Conclusion
- The different ways of handling and parameterizing the process can cause discrepancies between the results from Daily Plan and Schedule Show Preview.
Desired Behaviour
- The Schedule Show Preview function should mirror Daily Plan's functionality to minimize discrepancies between the Preview and the generated Schedule start time periods.
Maintaner Notes
- Schedule Show Preview
- Step 1, Step 2 Operates now like Daily Plan d.h. using 1-Day date range
- Note Step 2 The implementations for Daily Plan and Schedule Show Preview are still not standardized, but Schedule Show Preview has been adjusted to match Step 2 of Daily Plan.
Test Instructions
- Note: The tests should focus on the Schedule Show Preview (Calendar Show Preview and Daily Plan remain unaffected).
- Test various Schedules with different configurations (e.g., Weekdays, Every, with/without the non-working calendar etc.).
- Validate that the correct days are displayed across timeframes (e.g., current year, next year).
- Performance Tests Note: The preview now performs ~365 calculations internally instead of a single yearly calculation, increasing workload.
- Expected result: Response times must remain unchanged, with immediate display of preview dates.