Our pure JavaScript Scheduler component


Post by kirsten »

I want to limit the frequencies that users can choose from to "None", "Daily", and "Weekly". I figured out how to do this by adding the following config to eventEditFeature, like so:

eventEditFeature: {
        recurrenceCombo: {
          store: {
            filters: {
              filterBy: (rec) => {
                return ['none', 'DAILY', 'WEEKLY'].includes(rec.value)
              },
            },
          },
        },
}

But I also want to limit the items that appear in the dropdown of the "recurrence editor" popup. I see the docs here https://www.bryntum.com/products/scheduler/docs/api/Scheduler/view/recurrence/RecurrenceEditor, but I cannot figure out where / how in my config to customize the RecurrenceEditor config. (I'm using BryntumSchedulerProProps for my react component)


Post by Animal »

I commend your usage of the documentation to dig down to reconfigure the desired item.

If you want to similarly mutate the items in the recurrence editor, it is a little more difficult because that Panel is set as private, and its items are not documented in the way that the items of the base event editor are.

But it is possible. https://codepen.io/Animal-Nige/pen/BabewQB?editors=0010illustrates how.

Being undocumented, there will of course be no typings, so you will have to overcome the objections of typescript.

The names of the items can be gleaned from the data-ref of the fields in the panel:

Screenshot 2024-02-22 at 07.52.51.png
Screenshot 2024-02-22 at 07.52.51.png (313.18 KiB) Viewed 83 times

Post by Animal »

We do have a ticket to improve this situation: https://github.com/bryntum/support/issues/8656


Post by kirsten »

Thanks so much for the response! I will look into your suggestion and try that. (And thanks for opening the ticket!)


Post Reply