feat: allow editing meetings with past start date - WPB-27922 - #5210
feat: allow editing meetings with past start date - WPB-27922#5210caldrian wants to merge 4 commits into
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
The view model can initialize startDate outside the startDateRange for non-recurring meetings older than 24h, creating an inconsistent DatePicker binding and risking backend-rejected submissions.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
Updates the meeting editing flow in WireCallingUI to align with the backend’s new validation rules by allowing edited meetings to start up to 24 hours in the past, and adjusting how recurring meetings choose an editable occurrence within that window.
Changes:
- Updated
startDateRangein edit mode to allow selecting start times up to 24 hours ago. - Adjusted recurring-meeting occurrence selection to pick the first occurrence within the last 24 hours (instead of always advancing to a future one).
- Expanded presentation-layer tests to cover the 24-hour window behavior for recurring/non-recurring edit scenarios.
File summaries
| File | Description |
|---|---|
| WireCalling/Sources/WireCallingUI/Views/WireMeetings/MeetingForm/MeetingFormViewModel.swift | Applies the new 24-hour edit window and updates recurring occurrence selection logic. |
| WireCalling/Tests/WireCallingTests/WireMeetings/PresentationTests/MeetingFormViewModelTests.swift | Updates/adds tests to validate the new edit-window behavior and recurring occurrence handling. |
Review details
- Files reviewed: 2/2 changed files
- Comments generated: 2
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Test Results0 tests 0 ✅ 0s ⏱️ Results for commit aa2f72a. ♻️ This comment has been updated with latest results. Summary: workflow run #34375792450 |
…-editing-ongoing-meetings-WPB-27922
There was a problem hiding this comment.
🟡 Changes recommended
A submit-path bug can leave stale error flags set and the new user-facing localization keys are only added for English, which can break the alert text in other supported locales.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Review details
- Files reviewed: 4/4 changed files
- Comments generated: 2
- Review effort level: Lite
There was a problem hiding this comment.
🟡 Changes recommended
The new start-date picker range can allow selecting dates earlier than the documented 24-hour limit, which conflicts with the PR’s stated behavior.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Review details
- Files reviewed: 4/4 changed files
- Comments generated: 1
- Review effort level: Lite
| var startDatePickerRange: PartialRangeFrom<Date> { | ||
| guard mode.isEdit else { return startDateRange } | ||
| return min(startDate, startDateRange.lowerBound)... | ||
| } |
Issue
Allow editing meetings with start times up to 24 hours in the past, matching the backend’s updated validation.
Recurring meetings within this window now retain their original start and end times instead of advancing to a future occurrence. Older recurring meetings use the first occurrence within the allowed window. The edit date picker uses the same 24-hour limit.
Testing
Create a meeting. Once the meeting is ongoing, try to edit it.
Checklist
[WPB-XXX].UI accessibility checklist
If your PR includes UI changes, please utilize this checklist: