Forum
23:58
13/11/2010
Hi,
I'm trying to reproduce the Drag And Drop rows between grids example that you have in the Demo page... However it is not working, when I try to drag a row from one grid to another it doesn't even change the mouse cursor!
Here's my Javascript Code:
jQuery("#gridEquipos").jqGrid({
url:urlPagina+"&idGrid=gridEquipos",
datatype: "json",
mtype:'GET',
colNames:['ID Equipo','Nombre Equipo'],
colModel:[
{name:'id_equipo',index:'id_equipo', width:60},
{name:'nombre_equipo',index:'nombre_equipo', width:250},
],
rowNum:10,
rowList:[10,20,30],
pager: '#pagerEquipos',
sortname: 'id_equipo',
viewrecords: true,
sortorder: "desc",
caption: "Lista Total de Equipos",
height:200,
editurl:urlEditPagina
});
jQuery("#gridEquipos").jqGrid('navGrid','#pagerEquipos',{edit:false, add:false, del:false},
{},//edit
{},//add
{},//delete
{}//search
);
//EQUIPOS DEL TORNEO
jQuery("#gridEquiposTorneo").jqGrid({
url:urlPagina+"&idGrid=gridEquiposTorneo",
datatype: "json",
mtype:'GET',
colNames:['ID Equipo','Nombre Equipo'],
colModel:[
{name:'id_equipo',index:'id_equipo', width:60},
{name:'nombre_equipo',index:'nombre_equipo', width:250},
],
rowNum:10,
rowList:[10,20,30],
pager: '#pagerEquiposTorneo',
sortname: 'id_equipo',
viewrecords: true,
sortorder: "desc",
caption: "Equipos del Torneo",
height:200,
editurl:urlEditPagina
});
jQuery("#gridEquiposTorneo").jqGrid('navGrid','#pagerEquiposTorneo',{edit:false, add:false, del:true},
{},//edit
{},//add
{delData:{idGrid:"gridEquiposTorneo"},
reloadAfterSubmit:true,
afterComplete : function(response, postdata){
$("#gridGrupos1").trigger("reloadGrid");
}
},//delete
{}//search
);
//CONECTAR CON ESTILO DRAG AND DROP LOS GRIDS DE EQUIPOS
jQuery("#gridEquiposTorneo").jqGrid('gridDnD',{connectWith:'#gridEquipos'});
And here it is what I have in the html page in the top:
<link rel="stylesheet" type="text/css" media="screen" href="assets/styles/jqueryUI/jquery-ui-1.8.6.custom.css" />
<link rel="stylesheet" type="text/css" media="screen" href="assets/styles/ui.jqgrid.css" />
<script src="/assets/scripts/i18n/grid.locale-es.js" type="text/javascript"></script>
<script src="/assets/scripts/jquery.jqGrid.min.js" type="text/javascript"></script>
am I missing something?
04:57
13/11/2010
Can anyone give me a hand with this?
I'm kind of new with jquery... In the example it is mentioned that this feature (drag and drop) uses jquery UI draggable and droppable... Is this something that I have to add besides what I already included???
I really want this feature to work with the jqGrid...
Thanks...
Most Users Ever Online: 715
Currently Online:
30 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66