Our pure JavaScript Scheduler component


Post by aleksandr.shevchenko »

Bug with update columns:
1 Open template "https://www.bryntum.com/examples/scheduler/timeresolution/"
2 Update columns after scheduler create
capture1.PNG
capture1.PNG (116.81 KiB) Viewed 2294 times

Post by aleksandr.shevchenko »

Can you propose temporary solution to fix this?

Post by saki »

Columns cannot be changed like that. During configuration, it is an array of objects each defining the column properties. At runtime, `columns` is a Store and must be treated like that. See the documentation for more information on columns.

Post by aleksandr.shevchenko »

In ExtJs Scheduler we have solution some like this.
What are the options to update the all columns data? Add/remove columns not a best solution.

Thanks

Post by mats »

Please use the Store API as Saki said.
scheduler.columns.removeAll()

Post by aleksandr.shevchenko »

If use "scheduler.columns.removeAll()" and "scheduler.columns.add(newColumns)", to update columns, and change grid width:
columns.PNG
columns.PNG (179.65 KiB) Viewed 2150 times
Cause:
columns2.PNG
columns2.PNG (23.82 KiB) Viewed 2150 times

Post by mats »

Confirmed, it's a bug: https://github.com/bryntum/support/issues/437

Use remove(store.getRange()) instead for now.

Post by aleksandr.shevchenko »

The result is the same
columns3.PNG
columns3.PNG (122.42 KiB) Viewed 2142 times

Post by mats »

You should do:
scheduler.subGrids.locked.columns.remove(scheduler.subGrids.locked.columns.getRange())

Post by aleksandr.shevchenko »

Thanks

Post Reply