Our pure JavaScript Scheduler component


Post by bprescott_msd »

Should we be able to take our currently working horizontal mode scheduler control and just set the vertical mode flag, and not change anything else, and have it at least come up successfully? We removed the summary which the code indicated was not supported in vertical mode, but we are still getting other Javascript errors in the console that look to be much harder to track down.

Thanks.

BP

Post by mats »

Yes should just work, thought might be you're using some feature that's not supported. If you upload a simple test case we'll take a look.

Post by bprescott_msd »

Unfortunately our code is very complicated and we would not be able to post a test case here that you could look at and get working.

We are reading in a bunch of records, only some of which are being shown on the scheduler at any one time. Or in other words, we are only displaying one day on the scheduler, but we read in appointments from more than just the day displayed in the scheduler. This works fine on the horizontal view, but when we switch to vertical, an extra call that you are doing in your Javascript for vertical mode is causing an error. There is an event map that you are generating (VerticalEventMapper I think, forgive me but I do not have the code right in front of me), and a record id that is in our large data set is not in showing up as a key in this map.

Do you have any suggestions as to how we could diagnose this issue? Also, do you offer any kind of paid remote support, where you could remote into our machine so you could see exactly how we are doing things?

Thanks.

BP

Post by mats »

We do offer remote debugging service yes, under our Professional Services. https://bryntum.com/services

Please email sales@bryntum.com if interested.

Post by bprescott_msd »

For all of these lines below, we are using the non minified version of the 2.2.4 js file that we downloaded from the customer zone.

When we switch to vertical mode, the first javascript crash is in the VerticalEventMapper init, line 94041. The variable me.resourceColumns is undefined, because above when it sets that equal to scheduler.timeAxisColumn.resourceColumns on line 94029, that is also undefined, even though scheduler.timeAxisColumn does exist and looks to have valid data in it.

I have tried to manipulate the creation of the scheduler, which is somewhat complicated, by commenting out certain things, and have had no luck yet, so perhaps there is something wrong with the way that I am building my data. To do this, I basically build up an array of objects and then set the scheduler's events to that array.

Post by sergey.maltsev »

Hi, bprescott_msd!

Please provide your code that we can check.
Better if you make a sample app based on one of our examples and attach zipped file(s) here.

Post by mats »

@bprescott_msd Are you 'switching' during runtime (not supported) or configuring your Scheduler to be mode : 'vertical'?

Post by bprescott_msd »

We have it set up to switch at runtime, but we have tried to set it up to be vertical by default. By doing this, we do get a different error. When creating the scheduler in vertical mode from the beginning, some of the data shows up correctly, but it does have a javascript error on line 94317 in the onEventStoreChange function:
 const eventDatas = Object.values(me.eventMap[record.id]);
The problem is that the record.id of the data has a value of 1439, but that value does not show up as a key in the me.eventMap object.

Post by mats »

Could you please post the full stack of the error message?

Post by mats »

+ can you please share the config of your Scheduler at least?

Post Reply