I have the following code which allows item drag and drop between 2 listbox:
@Html.EJ().ListBox(inclusionId).Width("100%").Datasource(Model.Inclusions).ListBoxFields(incl => incl.Text("Label").Value("TypeOfInclusionId")).AllowDrag(true).AllowDrop(true).Enabled(true).EnablePersistence(true).ClientSideEvents(evt => evt.ItemDragStop("checkItem"))
@Html.EJ().ListBox(exclusionId).Width("100%").Datasource(Model.Exclusions).ListBoxFields(excl => excl.Text("Label").Value("TypeOfInclusionId")).AllowDrag(true).AllowDrop(true).Enabled(true).EnablePersistence(true).ClientSideEvents(evt => evt.ItemDragStop("checkItem"))
However, since I will have several listbox in my view, I need to restrict the drag and drop of an item. For example, allow drag and drop from the inclusion listbox to its 'paired' exclusion listbox and not to another inclusion listbox.
I have tried the ItemDragStop event, but this give me the event when the item of a listbox is dragged.
Is there any other way where I can do the above? Like allow drag and drop only between a set of inclusion and exclusion listbox?