@@ -179,7 +179,7 @@ export class RecurrenceForm {
179179
180180 setReadOnly ( value : boolean ) : void {
181181 this . _readOnly = value ;
182- this . updateWeekDaysButtons ( ) ;
182+ // this.updateWeekDaysButtons();
183183 }
184184
185185 createRecurrenceFormGroup ( ) : GroupItem {
@@ -346,6 +346,7 @@ export class RecurrenceForm {
346346 this . weekDayItems . forEach ( ( item ) => {
347347 const buttonContainer = $ ( '<div>' ) . appendTo ( $container ) ;
348348
349+ this . _weekDayButtons [ item . key ] ?. dispose ( ) ;
349350 this . _weekDayButtons [ item . key ] = this . scheduler . createComponent ( buttonContainer , Button , {
350351 text : item . text ,
351352 disabled : this . _readOnly ,
@@ -367,6 +368,7 @@ export class RecurrenceForm {
367368 this . recurrenceRule . byDay . push ( item . key ) ;
368369 }
369370
371+ // todo: update state only of the current button and remove this.updateWeekDaysButtons
370372 this . updateWeekDaysButtons ( ) ;
371373 } ,
372374 } ) ;
@@ -603,6 +605,7 @@ export class RecurrenceForm {
603605 const dayOfMonthGroup = `${ recurrencePatternGroupPath } .${ EDITOR_NAMES . recurrenceDayOfMonthEditor } ` ;
604606 const dayOfYearGroup = `${ recurrencePatternGroupPath } .${ GROUP_NAMES . recurrenceDayOfYearGroup } ` ;
605607
608+ this . dxForm . beginUpdate ( ) ;
606609 this . dxForm . itemOption ( daysOfWeekGroup , 'visible' , false ) ;
607610 this . dxForm . itemOption ( dayOfMonthGroup , 'visible' , false ) ;
608611 this . dxForm . itemOption ( dayOfYearGroup , 'visible' , false ) ;
@@ -621,7 +624,7 @@ export class RecurrenceForm {
621624 break ;
622625 }
623626
624- this . updateWeekDaysButtons ( ) ;
627+ this . dxForm . endUpdate ( ) ;
625628 }
626629
627630 private updateWeekDaysButtons ( ) : void {
@@ -630,7 +633,7 @@ export class RecurrenceForm {
630633
631634 button . option ( 'stylingMode' , isSelected ? 'contained' : 'outlined' ) ;
632635 button . option ( 'type' , isSelected ? 'default' : 'normal' ) ;
633- button . option ( 'disabled' , this . _readOnly ) ;
636+ // button.option('disabled', this._readOnly);
634637 } ) ;
635638 }
636639}
0 commit comments