Clicked item in Resource Allocation View

Hi,

I have Gantt in Resource Allocation View ( https://help.syncfusion.com/js/gantt/resource-allocation-view ). I also have rowSelected event on it:
(rowSelected)="rowSelected($event)"
now, when I click on some task in Gantt Chart, this rowSelected event is called, but in event I can not found taskId of clicked item. I can only find resourceId of clicked row.
I have been trying to find clicked task id in resource view even in other events and also in gantt model object, but I could not found it.

So I wonder how to get id of clicked task item in Resource Allocation View in Gantt Chart area?

https://puu.sh/Ac34W/6900915a70.png

Regards,
Marko


3 Replies

MM Manikandan Manikam Syncfusion Team April 30, 2018 10:40 AM UTC

Hi Marko,  

Thank you for contacting Syncfusion support. 
In resource view Gantt, rowSelected event contains the details about the resource and it’s allocated tasks details, so we can’t get the clicked taskbar details alone. 
But we can get the task details on mouse click action by using taskbarClick event, please find the code snippet for this below. 
[app.component.html] 
<ej-gantt id="GanttControl" 
(taskbarClick)="taskbarlClick($event)"> 

[app.component.ts] 
 
taskbarlClick(args){ 
   console.log("Clicked Item Id- " + args.data.taskId); 
} 

Please refer the following link to know more about taskbarClick event. 
Please let us know, if you require further assistance on this. 

Thanks, 
Manikandan M. 



MA Marko April 30, 2018 04:19 PM UTC

Hi,

that is it. Thank you, I obviously overlooked this one.

Regards,
Marko


JD Jayakumar Duraisamy Syncfusion Team May 1, 2018 04:06 AM UTC

Hi Marko, 
 
We are glad that your issue has been resolved. Please let us know, if you need any other assistance. 
 
Regards, 
Jayakumar D

Loader.
Up arrow icon