Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_Related Related Topics sp_TopicIcon
Master/Detail freezes after add - edit cancellation
09/07/2012
06:15
Avatar
stevansremac
New Member
Members
Forum Posts: 1
Member Since:
09/07/2012
sp_UserOfflineSmall Offline

Problem: master grid on onSelectRow displays detail grid correctly (#Mail) until I select add/edit in detail grid…

After that row in #Mail stays selected and frozen

After that selecting rows in master grid

generate error  in JqGrid.src.js ( row 3249) im detail grid

this.p is undefined

setCaption : function (newcap){

return this.each(function(){
this.p.caption=newcap;
$("span.ui-jqgrid-title,span.ui-jqgrid-title-rtl",this.grid.cDiv).html(newcap);
$(this.grid.cDiv).show();
});
HELP PLEASE!!!

used script:

<script  type="text/javascript" src="script/jquery-1.7.2.min.js"></script>
<link rel="stylesheet" type="text/css" media="screen" href="script/jquery-ui-1.8.21.custom.css" />
<link rel="stylesheet" type="text/css" media="screen" href="script/ui.jqgrid.css" />
<script src="script/grid.locale-sr-latin.js" type="text/javascript"></script>
<script src="script/jquery.jqGrid.src.js" type="text/javascript"></script>

js:

$(document).ready(function()
{

jQuery("#list2″).jqGrid({
url:'load.php?q=2',
datatype: "json",
colNames:['id','STATUS','IME','PREZIME','GODISTE','ADRESA','GRAD','OPŠTINA','ZEMLJA','POL','BROJ DECE','OZNAKA POREKLA','TIP ÄŒLANSTVA'],

colModel:[
{name:'id', key:true, index:'id', width:35},
{name:'statusi',index:'statusi', width:60,editable:true,hidden: true , editrules: {edithidden:true}, searchoptions: {searchhidden: true}},
{name:'ime',index:'ime', width:70,editable:true,search: true},
{name:'prezime',index:'prezime', width:115, align:"center",editable: true},
{name:'DatumRodjenja',index:'DatumRodjenja', width:58, align:"center",editable:true,searchtype:"number"},
{name:'Adresa',index:'Adresa', width:180,align:"center",editable:true},
{name:'Grad',index:'Grad', width:80,align:"center",editable:true},
{name:'Opstina',index:'Opstina', width:80,align:"center",editable:true},
{name:'Zemlja',index:'Zemlja', width:80,align:"center",editable:true},
{name:'Pol',index:'Pol', width:30,align:"center",editable:true},
{name:'brojDece',index:'brojDece', width:70,align:"center",editable:true},
{name:'OznakaPorekla',index:'OznakaPorekla', width:120,align:"center",editable:true},
{name:'TipClanstva',index:'TipClanstva', width:100,align:"center",editable:true}
],
      height: 'auto',
      rowNum:20,
      rowList:[5,10,20,30,40,50,60,70,80,90,100],
      pager: '#pager2',
      sortname: 'id',
      viewrecords: true,
      sortorder: "desc",
      multiselect: false,
      gridview: true,
      jsonReader: {repeatitems: false,id:"0″},
    onSelectRow: function(ids)
    {
    jQuery("#Mail").jqGrid('setGridParam',{url:"subgrid2.php?q=5&id="+ids,page:1});    
     jQuery("#Mail").jqGrid('setCaption',"MAIL: ").trigger('reloadGrid');
   },
   editurl:"someurl.php",   
  caption:"fsd" });
  jQuery("#list2″).jqGrid('filterToolbar',{stringResult: true,searchOnEnter : false});
 

 
//MAIL
jQuery("#Mail").jqGrid({
  height: 'auto',
  pager: '#pagerMail',
  url:'subgrid2.php?q=2&id=',
  editurl:"someurl.php",
  datatype: "json",
  colNames:['ClanID','Mail','Napomena'],
    colModel:[
    {name:'ClanId',index:'ClanId', width:60,hidden: true },
    {name:'Mail',index:'Mail', width:155,editable:true,formatter:'email'},
    {name:'Napomena',index:'Napomena', width:180,editable:true},
    ],

    height:'auto',
    rowNum:1,
    rowList:[5,10,20],
    sortname: 'Mail',
    viewrecords: true,
    sortorder: 'asc',
    multiselect: false,
    rowList: [],        // disable page size dropdown
    pgbuttons: false,     // disable page control like next, back button
    pgtext: null,
    caption:"Mail"
})

jQuery("#Mail").jqGrid('navGrid','#pagerMail', {}, //options
{beforeShowForm: function(formid)
{
 jQuery("#Mail").setGridParam({editurl:"myurlhere.php?q=edit"});
}}, // edit options
{
    beforeShowForm: function(formid) {

  mid = jQuery("#list2″).getGridParam("selrow");
    if (mid != null )
    jQuery("#Mail").setGridParam({editurl:"myurlhere.php?q=add&ClanId="+mid});

}}, // add options
{    
beforeShowForm: function(formid)
{
  mid = jQuery("#list2″).getGridParam("selrow");
  if (mid != null )
      jQuery("#Mail").setGridParam({editurl:"myurlhere.php?q=del&ID="+mid});
}}, // del options
{} // search options
 );
 

});

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
57 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.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information