Skip to content

Commit c22f307

Browse files
committed
fix recurring shift form
1 parent 91c2234 commit c22f307

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/shiftings/shifts/forms/recurring.py

+3-4
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,14 @@ class RecurringShiftForm(forms.ModelForm):
1313
ordinal = forms.IntegerField(label=_('Ordinal'), min_value=1, max_value=31)
1414
auto_create_days = forms.IntegerField(label=RecurringShift.auto_create_days.field.verbose_name,
1515
help_text=RecurringShift.auto_create_days.field.help_text,
16-
initial=RecurringShift.auto_create_days.field.default,
1716
min_value=settings.AUTO_CREATE_DAYS_MIN,
1817
max_value=settings.AUTO_CREATE_DAYS_MAX)
1918

2019
class Meta:
2120
model = RecurringShift
22-
fields = ['name', 'organization', 'time_frame_field', 'week_day_field', 'month_field',
23-
'first_occurrence', 'color', 'template', 'weekend_handling_field', 'weekend_warning',
24-
'holiday_handling_field', 'holiday_warning']
21+
fields = ['name', 'organization', 'time_frame_field', 'ordinal', 'week_day_field', 'month_field',
22+
'first_occurrence', 'auto_create_days', 'color', 'template', 'weekend_handling_field',
23+
'weekend_warning', 'holiday_handling_field', 'holiday_warning']
2524

2625
def __init__(self, *args: Any, **kwargs) -> None:
2726
super().__init__(*args, **kwargs)

0 commit comments

Comments
 (0)