I have this data which i'm dragging
<tbody cdkDropList [cdkDropListData]="ListData">
<tr *ngFor="let list of ListData" cdkDrag>
...
</tr>
</tbody>
i want to drag a particular row and drop in second container
<li *ngFor="let user of userData; index as i;">
<div cdkDropList [cdkDropListData]="UserList" (cdkDropListDropped)="drop($event,user.Id)" cdkDropListSortingDisabled>
..
</li>
i want to get the dragged item data in drop function
drop(event: CdkDragDrop<string[]>,Id) {
event.previousContainer.data[event.previousIndex];
}
tried the above code but this is picking the current drag data
any solution
thanks