Hi,
Sorry for my english, i use Google Translate.
I have 6 dataviews initialized by a loop. Drag-and-drop is OK but how to find the container from and to?
Thanks for your help.
for (i = 1 ; i <= nb_equipements ; i++)
{
nom_container[i] = “turbo_” + i;
data_turbo[i] = new dhtmlXDataView({
container: nom_container[i],
type:{
template:"<span class='dhx_strong'>Commande n° #Commande#</span>Client : #Client# <br><span class='dhx_light'>#Info#</span><span class='dhx_light'> --</span> <span class='dhx_light'>#Duree#</span>",
height:40,
width: 170
},
select: true,
drag:true
});
data_turbo[i].attachEvent("onBeforeDrop", function (id,context,ev)
{
//item deplace
var context = dhtmlx.DragControl.getContext();
var item = context.from.get(context.source[0]);
var commande = item.Commande; //numero de la commande
var client = item.Client; // client
var duree = item.Duree //duree
//dataview to
//......
//dataview from
return true;
});
}