JavaScript UI Libraries & Blazor Components Suite – Smart UI › Forums › Kanban › How to get task order number when drag within the same column?
Hello,
I’m already detecting the change trough the event
document.getElementById(‘kanban’).addEventListener(‘change’, function (event) { const detail = event.detail, oldValue = detail.oldValue, task = detail.task, value = detail.value;
But, how to know the exact row position of the task changed?
I try “value.index” or “value.row” but should be different…
What is the property?
Thanks
Hello Abilio,
Please have a look at the demo here: Codepen demo
Every time you drag a task, the console will log the new index of the task within its parent column (0 is the first index).
If you have any other questions, please do not hesitate to contact us again. Best regards, Ivan Peevski Smart UI Team https://www.htmlelements.com/
Hello Ivan,
Many thanks! The solution is exactly what I need.
Kind Regards,
Abilio