There is an object with arrays:
{
"array_1": [
{item:"#1"},{item:"#2"},{item:"#3"},
],
"array_2": [
{item:"#4"},{item:"#5"},{item:"#6"},
],
}
SortableJS perfectly modifies arrays on drag-n-drop. However, I'm trying to send information about the new item's position to the server and can't find the relocated object. The Object I try to build using "onEnd" event:
{item:"#1", list:"array2"}
There is a reference to the DOM element in the SortableJS custom event; a new index of the item is also there; BUT! nothing about the new group - array where the item was moved to.
The ideal solution: find a direct reference to an item (object) and array, editable from the Angular component. Plan "B" is to find the "new group" index to which the item was moved to.