Skip to content

feat(validation): make opening times optional when appointment only is selected#101

Merged
james-cross merged 1 commit intostagingfrom
feature/appointment-only-opening-times-optional
Jan 27, 2026
Merged

feat(validation): make opening times optional when appointment only is selected#101
james-cross merged 1 commit intostagingfrom
feature/appointment-only-opening-times-optional

Conversation

@james-cross
Copy link
Contributor

Summary

Updates the address validation in organisation schema to make opening times optional when "Appointment Only" is selected, matching the existing behaviour for services.

Changes

  • Updated AddressSchema refinement to check for IsAppointmentOnly in addition to IsOpen247
  • Opening times are now only required when both IsOpen247 and IsAppointmentOnly are false

Test plan

  • Save an organisation with an appointment-only location that has no opening times - should succeed
  • Save an organisation with a location that is neither 24/7 nor appointment-only without opening times - should fail validation

@james-cross james-cross merged commit c6f508c into staging Jan 27, 2026
1 check passed
@james-cross james-cross deleted the feature/appointment-only-opening-times-optional branch February 10, 2026 09:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant