Our pure JavaScript Scheduler component


Post by Oleg »

Good day. Hello.
I want to ask if it would be possible to create a raised line after clicking on the timeline for a specified time, which would be an indicator of the cross-section of time in a given place and which would remain there even when scrolling in a horizontal direction, and its height would be the entire area of the list of resources, see the picture.

Thanks in advance for the answers

Last edited by Oleg on Wed Jun 07, 2023 7:41 am, edited 1 time in total.

Post by Oleg »

illustrative picture

Attachments
Capture.JPG
Capture.JPG (73.31 KiB) Viewed 101 times

Post by tasnim »

Hi,

Please check these docs
https://bryntum.com/products/schedulerpro/docs/api/Scheduler/feature/TimeRanges
https://bryntum.com/products/schedulerpro/docs/api/SchedulerPro/view/SchedulerPro#event-scheduleClick
https://bryntum.com/products/schedulerpro/docs/api/Scheduler/view/mixin/TimelineDateMapper#function-getDateFromCoordinate

And here is a simple code snippet to achieve it

// listening to scheduleClick
scheduler.on('scheduleClick', (e) => {
    const { source, date } = e;
    // Add timerange to timeRangeStore
    source.timeRangeStore.add({
        startDate    : date,
        duration     : 0,
        durationUnit : 'day'
    });
});

Post Reply