Is there a 'normal click' equivalent of the onContextMenu ev

onContextMenu is great because it passes the eventId if you clicked an event, and null if you clicked the scheduler. But I couldn’t find the same type of event for a normal click.

The regular ‘onClick’ only works for if you click an event.

Also, would there be a way of detecting the time and unit that was clicked?

Thanks

Hello,

The easiest way would be to change the source code, open dhtmlxscheduler.js, locate !scheduler.callEvent("onClick",
Full line in uncompressed version:

if ((id && !scheduler.callEvent("onClick",[id,e])) ||scheduler.config.readonly) return;

Simply delete ‘id’ check:

if (!scheduler.callEvent("onClick",[id,e]) ||scheduler.config.readonly) return;

Unfortunately that’s tricky and there is no easy way to do it for now.

Kind regards,
Ilya