Our state of the art Gantt chart


Post by Qwerty »

Hi there,

We've found an issue with the combination of column sorting and undo/redo.

Steps to Reproduce

  1. Go to the undo/redo example here: https://www.bryntum.com/examples/gantt/undoredo/
  2. Sort by the name column. Note that the undo button remains disabled
  3. In the browser console, run the following:
    gantt.project.taskStore.changes.modified.map(t => ({ name: t.name, changes: JSON.stringify(t.meta.modified)}))

You'll notice that there are in fact changes.

We're using the hasChanges and noChanges events on the ProjectModel to enable and disable our save button, which means after sorting a column the save button becomes enabled but the user is not able to undo their changes.

Could you please advise on some workarounds?

Thanks.


Post by Qwerty »

An additional somewhat related issue can be seen by creating a link/dependency and then undoing the change.

  1. Go to the undo/redo example here: https://www.bryntum.com/examples/gantt/undoredo/
  2. Create a link between the "Unit tests" task and the "UI unit tests / individual screens"
  3. Undo
  4. In the browser console, run the following:
    gantt.project.taskStore.changes.modified.map(t => ({ name: t.name, changes: JSON.stringify(t.meta.modified)}))
    

I would expect there to be no changes to save, but there are in fact changes. This has the same effect as above -- causing the save button to become enabled.


Post by mats »

Both issues reproduced, thanks for perfectly clear instructions. We'll have a look at these shortly!

https://github.com/bryntum/support/issues/958
https://github.com/bryntum/support/issues/959


Post by Qwerty »

Thanks for the fast reply, mats!

We'll keep an eye on those issues and upgrade as soon as they're fixed.


Post by Qwerty »

Hi mats,

Another related issue to this can be seen when deleting a task, then undoing that deletion.

Steps to Reproduce

  1. Go to the undo/redo example here: https://www.bryntum.com/examples/gantt/undoredo/
  2. Delete the "Run tests" task
  3. Undo
  4. In the browser console, run the following:
    gantt.project.taskStore.changes
    

There are items in both the modifications array and the added array.

The item in the added array is the biggest issue because if the user now saves, a duplicate task will be created.


Post by Qwerty »

Additionally,

Do steps 1 - 4 as described above, then;

  1. Redo the deletion
  2. View the changes in the console using the snippet above.

The task should be in the deleted array. Instead, it's not, meaning the task will reappear when the page is loaded again.


Post by mats »

Please start new threads for additional issues, or the forum threads become a mess :)


Post by Qwerty »

Apologies mats,

We figured that these were symptoms of the same issue but we're more than happy to create additional threads.

Please see:


Post by Qwerty »

Hi there,

We see that these issues have been re-prioritized from 2.1.6 to 2.1.8. Are we able to get a rough idea on when 2.1.8 will be released including the fixes for these issues?

Thanks again.


Post by Maxim Gorkovsky »

Hello.
Issue #975 is already resolved and you can try it out in latest nightly build. 958 and 959 should hit next release too, which should be out in about 2 weeks.


Post Reply