Thursday 15 August 2013

jquery - Double click the datagird in jeasyui popup not opened in Firefox -



jquery - Double click the datagird in jeasyui popup not opened in Firefox -

i using jquery easyui datagird (http://www.jeasyui.com/demo/main/index.php?plugin=datagrid&theme=default&dir=ltr&pitem=) website. when double click each records popup should opened in ie, chrome, safari except firefox?

clicking event function fired, info populating place having issue.

first, can load info here: function loadmaildetails(rowindex){ var t = $('#test'); t.datagrid('clearselections'); t.datagrid('selectrow',rowindex); var row = $('#test').datagrid('getselected'); if (row){ var folderid=$('#sourcefolderid').val(); var isarchive=$('#archiving').val(); var loading=fromload; if(isarchive=="no") { jquery.ajax({ type:'post', data:'id=' +row.id+'&folderid='+folderid+"&loading="+loading+"&ummid="+row.ummid, url:'/'+productname+'/inbox/getemaildetail', success:function(data,textstatus){ maildetails(data,row); }, async:false , cache: false }); } else { jquery.ajax({ type:'post', data:'id=' +row.id+'&folderid='+folderid+'&ummid='+row.ummid, url:'/'+productname+'/inbox/getarchiveemailmessage', success:function(data,textstatus){ maildetails(data,row); }, async:false , cache: false }); } } } here can open popup (issue happened here) if(fromautomatch==false) { jquery.ajax({ type:'post', url:'/'+productname+'/inbox/openmailpopupdialog', success:function(data,textstatus){ $('body').append(data); }, async: false }); var folderid=$('#sourcefolderid').val(); var isarchive=$('#archiving').val(); var selectednode = $('#jquerytree').tree('getselected') var selectedtext = selectednode.text; var tempdrafts = false; if(selectedtext.indexof("drafts") >=0){ tempdrafts = true; } var loading=fromload; if (rowdata){ if(isarchive=="no"){ jquery.ajax({ type:'post', data:'id=' +rowdata.id+'&folderid='+folderid+"&isdraft="+tempdrafts+"&loading="+loading, url:'/'+productname+'/inbox/getemaildetail', success:function(data,textstatus){ mailpopup(data); } }); }else{ jquery.ajax({ type:'post', data:'id=' +rowdata.id+'&folderid='+folderid, url:'/'+productname+'/inbox/getarchiveemailmessage', success:function(data,textstatus){ mailpopup(data); } }); } } } }, onrowcontextmenu:function(e,rowindex,rowdata){ e.preventdefault(); $('#test').datagrid('selectrow',rowindex); var noofrows = $('#test').datagrid('getselections').length; var selectednode = $('#jquerytree').tree('getselected') var selectedtext = selectednode.text; var tempnode = $('#jquerytree').tree('getparent',selectednode.target); var parenttext = tempnode.text; if(selectedtext.indexof("drafts") >= 0 || selectedtext.indexof("outbox") >= 0 || selectedtext.indexof("sent items") >= 0 || selectedtext.indexof("deleted items") >= 0 || selectedtext.indexof("failed items") >= 0 || parenttext.indexof("drafts") >= 0 || parenttext.indexof("outbox") >= 0 || parenttext.indexof("sent items") >= 0 || parenttext.indexof("deleted items") >= 0 || parenttext.indexof("failed items") >= 0){ $('#archiveemailrightclickid').css('display','none'); } if(noofrows==1) { if(rowdata.read==true) { $('#markasread').css('display','none'); $('#markasreadid').css('display','none'); $('#markasunread').css('display','block'); $('#markasunreadid').css('display','block'); } else { $('#markasread').css('display','block'); $('#markasreadid').css('display','block'); $('#markasunread').css('display','none'); $('#markasunreadid').css('display','none'); } } else { $('#markasread').css('display','block'); $('#markasunread').css('display','block'); $('#markasreadid').css('display','block'); $('#markasunreadid').css('display','block'); } var selectedaccordion = $('#accordionpanel').accordion('getselected'); var selectedindex if (selectedaccordion){ selectedindex = $('#accordionpanel').accordion('getpanelindex', selectedaccordion); } if(selectedindex == 1){ $('#gridcontextmenu').menu().menu('show',{ left: e.pagex, top: e.pagey }); }else if(selectedindex == 2){ $('#gridcontextarchivemenu').menu().menu('show',{ left: e.pagex, top: e.pagey }); } }, // , rowstyler:function(index,row){ if ((row.read == false || row.read == "false" || row.read == "[false]") && (row.emailsource == "2" || row.emailsource == 2 || row.emailsource == "[2]")){ homecoming 'font-weight:bold;background-color:#a7cdf0;'; }else if ((row.read == false || row.read == "false" || row.read == "[false]") && (row.emailsource != "2" || row.emailsource != 2 || row.emailsource != "[2]")){ homecoming 'font-weight:bold;'; }else if ((row.read == true || row.read == "true" || row.read == "[true]") && (row.emailsource == "2" || row.emailsource == 2 || row.emailsource == "[2]")){ homecoming 'background-color:#a7cdf0;'; } }, onclickrow:function(rowindex,rowdata){ additionaldata = rowdata; loadmaildetails(rowindex) }, ondblclickcell :function(rowindex, field, value){ if(field=="automatch") fromautomatch=true; else fromautomatch=false; }, onbeforeload:function(){ var rows = $('#test').datagrid('getselections'); if(rows){ $('#test').datagrid('clearselections'); $('#test').datagrid('clearchecked'); } } }); }

try surround code in onclickrow settimeout( [your code], 0);.

jquery datagrid jquery-easyui

No comments:

Post a Comment