Our pure JavaScript Scheduler component


Post by harriskmt »

Hello,

I'm trying to offer the user the ability to turn dependencies on or off on demand. However, I'm having a hard time achieving this from the scheduler component instance. I've used the Task editor customization Vue 3 + Vite 4 example and have zipped the changed files below. I would appreciate any help you can provide.

Attachments
taskeditor_example_changes.zip
(3.01 KiB) Downloaded 10 times

Post by marcio »

Hey harriskmt,

Thanks for reaching out and welcome to our forums.

To disable/enable the dependencies, you can use

// disable
schedulerPro.features.dependencies.disabled = true;
// enable
schedulerPro.features.dependencies.disabled = false;

Where schedulerPro is the SchedulerPro instance (that you can check how to access here https://bryntum.com/products/schedulerpro/docs/guide/SchedulerPro/integration/vue/guide#bryntum-scheduler-pro-api-instance).

You can live it test running those snippets in the console on this demo https://bryntum.com/products/schedulerpro/examples/dependencies/.

Best regards,
Márcio


Post by harriskmt »

Hello,

Apologies for the late reply. I tried your method, but it didn't work and threw the following error:

Uncaught (in promise) TypeError: can't assign to property "disabled" on false: not an object.

I tested it with the example you provided, and it works fine, but that example is in plain JavaScript. Could you please provide a working Vue example so I can see what I might be doing wrong?


Post by ghulam.ghous »

Hi there,

I have compiled an example in vue-3 + vite. Please check here:

taskeditor.zip
(274.7 KiB) Downloaded 10 times
Screen Recording 2024-08-05 at 2.28.25 PM.zip
(3.35 MiB) Downloaded 7 times

Please let us know, is this does not solve your problem.

Regards,
Ghous


Post by harriskmt »

Thank you, it solved my problem :)


Post by ghulam.ghous »

Glad to hear that. Happy coding :)


Post Reply