Our pure JavaScript Scheduler component


Post by lianpelser »

Hi,

Scheduler Pro Version = 6.1.2
OS = Fedora Linux 41
Browser = Firefox Version 133.0.3 /Chrome Version 133.0.6914.0

We pass duration and endDate to events. This endDate is the latest time the event should complete.

An event is a "work order" in our case. These work orders are linked to a production order, and the production order has an endDate which is the latest time it should complete. A production order might have more than one work order linked to it, and each of these will then depend on each other.

Lets say production order PO0001 has an endDate of 30 Jan 2024 17:00:00, and it has three work orders linked to it: WO0001, WO0002, and WO0003. Each work order will then also have an endDate of 30 Jan 2024 17:00:00 because of the parent production order's endDate.

This means that the WO0003 event should finish by 30 Jan 2024 17:00:00, and the others should be scheduled before that (even though it's endDate is the same date).

The problem is that if the WO0003 event is dependent on another event (WO0002) , it gets 'pushed' forward in the schedule, and does not schedule at the correct time. Instead, the scheduler ensures that WO0001 is done by 30 Jan 2024 17:00:00, and the other two are scheduled for after that.

We need to ensure that the events are scheduled backward in the dependency chain from the 'latest date/time' for the last event, and then backwards to the first event in the chain.

example of two work order events where WO0002 DEPENDS on WO0001 to be done first:

work_order_events:  
Array(6) [ {…}, {…}, {…}, {…}, {…}, {…} ] ​ 0: Object { id: "WO_ID2", resourceId: 2, name: "WO0001", … } ​​​ duration: 360 ​​ durationUnit: "minute" ​​ endDate: "2025-01-30T17:00:00.000Z" ​​​ id: "WO_ID2" ​​ name: "WO0001" ​​ resourceId: 2 ​ 1: Object { id: "WO_ID3", resourceId: 2, name: "WO0002", … } ​​​ duration: 180 ​​ durationUnit: "minute" ​​ endDate: "2025-01-30T17:00:00.000Z" ​​ id: "WO_ID3" ​​ name: "WO0002" ​​ resourceId: 2

The reason I cannot provide separate endDate to each event is that the work orders are dynamically generated, and are scheduled at "workstations" (the resources), which have dynamic working and non-working times.

I know SchedulerPro does not support "direction: 'Backward'" for events like Gantt does, but I would like to know if there is something else I can do to determine/change the endDate of the events earlier in the dependency chain of events?

Is there some way i can only provide the duration and endDate for the last event in the chain, and only the duration for the other events in the chain? Is there some other SchedulerPro method/magic that I can use to simplify this for me?

There is a full test case attached:

  • Extract

  • Navigate to src

  • Place schedulerpro files in src/pages/schedulerpro/

  • Place schedulerpro files in src/bundles/schedulerpro/

  • run 'npm install'

  • run 'npm run build'

  • run 'npm start'

I added some test data in data.json (in the format we send it to the scheduler).

Please let me know if you have any suggestions, questions or if I need to clear something up.

Kind regards,

Lian

Attachments
runnable_test_case_2.zip
(10.77 KiB) Downloaded 3 times

Post by alex.l »

Hi,

Yes, your logic sounds like a not SchedulerPro, but simple backward directed project functionality for Gantt.
You could try to emulate it, but it won't be working fully as backward directed project. Are you noticed about constraints? https://bryntum.com/products/schedulerpro/docs/guide/engine/schedulerpro_events_scheduling#event-constraint-effect-on-the-scheduling Did you try to set finish-no-later-than for your tasks? Did you try to manage it with dependencies+constraints?

All the best,
Alex Lazarev

How to ask for help? Please read our Support Policy

We do not write the code in bounds of forum support. If you need help with development, contact us via bryntum.com/services


Post by lianpelser »

Hi Alex,

I have tried all combinations of different dependencies, dependency types, and constraints but none of them really worked. Luckily I found an interim solution that is fine for now:

  • Create all events
  • Find event at the end of the dependency chain
  • Start ->
    -- Get working window
    -- Snap event backward
    -- Find predecessor
    -- Move backwards in the dependency chain and repeat
  • End <-

I think it would have been beneficial if the same " direction: 'Backwards' " functionality in Gantt was also in SchedulerPro, but for now the issue is resolved, thanks!

Lian


Post by alex.l »

Hi Lian,

Thanks for sharing your solution! Another option might be using Gantt's ProjectModel class in SchedulerPro, but for sure if you have licenses for both.
I talked with team about that. That's rarely requested feature, you are the first who asked, so I am afraid for now we can't put it on the roadmap, but there is an option to get Paid Feature (50% off from our Professional Services rate) or Professional Services to make it personally for you. Check bryntum.com/services if you're interested.

All the best,
Alex Lazarev

How to ask for help? Please read our Support Policy

We do not write the code in bounds of forum support. If you need help with development, contact us via bryntum.com/services


Post by lianpelser »

Hi Alex,

Thank you, we will definitely remember that for in the future if it is needed. I appreciate the help!

Have a good weekend!

Lian


Post Reply