Page 1 of 1

[ANGULAR] zoom bug

Posted: Wed Sep 28, 2022 4:46 pm
by eugenem

Strange behavior that looks like a bug. I've implemented a monthly view using following code. The idea is to show the whole month on one screen.

    
presets: [ { id: 'month', base: 'dayAndWeek', tickHeight: 20, } ], this.schedulerPro.instance.zoomTo({ preset: 'month', startDate: startDate, // first day of requested month endDate: endDate // first day of next month });

It works well except for October 2022 and October 2023. October 2021 does work fine.

When it fails, I don't see that timeline is updated, and events are also shown for the previous month. But if I do any layout update (scrollbar, splitter, browser size), it shows proper info. It only happens in vertical mode.

I've tried to trigger some refresh for scheduler, but didn't find any function for it.


Re: [ANGULAR] zoom bug

Posted: Wed Sep 28, 2022 4:53 pm
by marcio

Hello eugenem,

Could you please share what your configuration looks like?? You mentioned that's happening in vertical mode, so we would need a better context about that. If you could assemble a sample with the behavior that you described would be very nice to help you with that.


Re: [ANGULAR] zoom bug

Posted: Sun Oct 02, 2022 4:58 pm
by eugenem

hmm, it's complex to reproduce.

But I saw another thing: when there are events in October, it works fine. Only if there are no events at all, it fails to update the vertical axis.


Re: [ANGULAR] zoom bug

Posted: Mon Oct 03, 2022 2:17 pm
by alex.l

Hi eugenem,

I can't reproduce that. Please attach a test case and clear steps to reproduce.
Do you see that problem here https://bryntum.com/examples/examples-scheduler/vertical/ ?

Try to upgrade your app if you used not recent version.


Re: [ANGULAR] zoom bug

Posted: Tue Oct 11, 2022 12:58 pm
by eugenem

cannot reproduce at your demo

now I see another issue: events from the previous month are shown at the current one when I go over months (in case the current month has no events of itself)

look, I think the simplest way is to refresh the scheduler manually in a few ms. how do I do this?


Re: [ANGULAR] zoom bug

Posted: Tue Oct 11, 2022 3:53 pm
by alex.l

Try this https://bryntum.com/docs/scheduler-pro/api/SchedulerPro/view/SchedulerPro#function-refreshRows
But it will be very appreciated if you'll make a test case to reproduce this problem, it sounds like an important problem, we need to figure out what's wrong.


Re: [ANGULAR] zoom bug

Posted: Mon Oct 24, 2022 1:14 pm
by eugenem

ok, i did it like this:

    this.schedulerPro.instance.zoomTo({ preset: this.zoom_level, startDate: startDate, endDate: endDate });
    
setTimeout(() => { //this.schedulerPro.instance.renderContents(); this.schedulerPro.instance.refreshRows(); }, 50);

Re: [ANGULAR] zoom bug

Posted: Mon Oct 24, 2022 5:14 pm
by alex.l

Glad to hear, but if you'll have time in future and opportunity to make a test case, we would be happy to check that deeply. In case it's a bug in our code, it needs to be fixed.