Skip to content

Validation Error: "End time must be after start time" for valid cross-day schedules #57

@PublisherName

Description

@PublisherName

Description

When attempting to create an Event Schedule with the following values, an error is incorrectly triggered:

Provided Values

  • Start Date: 2025-01-01
  • Start Time: 23:55:30
  • End Date: 2025-01-26
  • End Time: 00:00:30

The current validation logic in validate_event_dates_and_time() considers only the time portion without accounting for the fact that end_date > start_date. This results in rejecting cross-day schedules where the end time is logically valid but occurs after midnight.


Expected Behavior

The validation logic should account for both the date and time. The following entry should be considered valid:

  • Start Date + Start Time: 2025-01-01 23:55:30
  • End Date + End Time: 2025-01-26 00:00:30

Steps to Reproduce

  1. Attempt to create an Event Schedule with the above values.
  2. Observe the validation error: The end time must be after the start time.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingenhancementNew feature or request

    Projects

    Status

    Completed

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions