From 997167fcbe20977ceb6c037ff0bcafd3fbc7663b Mon Sep 17 00:00:00 2001 From: Vadim Stepanov Date: Thu, 11 Jul 2024 13:21:12 +0100 Subject: [PATCH] Fix changing recurrence for weekday masked shifts (#4660) # What this PR does Fixes a bug when changing recurrence period for shifts with "Mask by weekdays" setting enabled breaks the schedule. https://github.com/grafana/oncall/assets/20116910/396359c5-4ba6-47d7-b003-fea9db709bea ## Which issue(s) this PR closes Related to https://github.com/grafana/support-escalations/issues/11374 ## Checklist - [ ] Unit, integration, and e2e (if applicable) tests updated - [x] Documentation added (or `pr:no public docs` PR label added if not required) - [x] Added the relevant release notes label (see labels prefixed w/ `release:`). These labels dictate how your PR will show up in the autogenerated release notes. --- grafana-plugin/src/containers/RotationForm/RotationForm.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/grafana-plugin/src/containers/RotationForm/RotationForm.tsx b/grafana-plugin/src/containers/RotationForm/RotationForm.tsx index b5b63239..27fdd8ba 100644 --- a/grafana-plugin/src/containers/RotationForm/RotationForm.tsx +++ b/grafana-plugin/src/containers/RotationForm/RotationForm.tsx @@ -337,7 +337,7 @@ export const RotationForm = observer((props: RotationFormProps) => { setShiftPeriodDefaultValue(undefined); setRecurrenceNum(value); - if (!isLimitShiftEnabled) { + if (!isLimitShiftEnabled && !isMaskedByWeekdays) { setShiftEnd( dayJSAddWithDSTFixed({ baseDate: rotationStart,