Hi Maxim and Alex,
Thank you by deep cloning the project data we were able to load the data in the scheduler on init.
But in our code there is a scenario where we use this.scheduler.destroy() to destroy the current instance and build a new one.
This destory method seems to fail to destory in the Latest versions but its working fine in the older version. we tried debugging but its something out of our context.
This where we encounter the issue.
1) when we load the screen / intialize it we gets the scheduler to load the data properly this is a OK situation.
2) when we select the number of records to be displayed.
We use a Batch process in Apex to do the processing again its the same data but with more records.
In this case we destory the current scheduler and recreate a new one . this is where the scheduler keeps loading.
On doing investigation we noticed that destroy() method doesnt get executed/ completed properly.
I reproduced the problem in your app. I need to check your source code to make sure you did all correct while re-creating the scheduler.
Could you please share it?
I tried to re-create the component with very basic code in our Salesforce examples:
tbar : [
{
type : 'button',
text : 'Destroy/Create',
onClick : (event) => {
scheduler.destroy();
me.createScheduler();
}
},
Thank you for sharing the code. I can't find a method where you destroy and create the SchedulerPro again.
I also don't see in what container you render it. No appendTo instruction, so how was it added and how was it destroyed? In what moment? Do you see this problem in our Salesforce example if you apply same approach of re-creating Scheduler as you used in your app?
Hi Alex ,
thanks for the reply
Reagrding the error not appearing in the org - Sorry we were testing something with a old scheduler version in the environment which i gave you, so it used to work fine . But i have updated the environment with the latest source so the problem still exists.
we tried to produce the issue in Bryntum salesforce examples.
Here are the results
It seems like after the console.log in the click method . the control never reaches the createScheduler.
Will that work if you remove Histogram and will render only Scheduler?
Do you have any errors in console? Did you try to step into t.destroy() and see what exactly is wrong there?
Does it possible to apply the code you used here to our Salesforce example and share with us, so we will have not minimized code for debugging on our side, it will help a lot to go faster.
Hi Alex , Sorry for the delay in answer.
We have turned the debug mode in the Bryntum example where the destroy method doesnt work . it would be easier to debug now.
We did try to step in the destroy method but the control seems to go into aura.prod.js files and we are not aware what exactly goes wrong .
Hello.
I've debugged this problem (you need to enable pause on caught exceptions) and I saw some old bug which was fixed in 5.2.8 https://github.com/bryntum/support/issues/5960
Upgrading to the latest release should help.