【问题标题】:problem with jqgridjqgrid的问题
【发布时间】:2010-09-23 17:47:41
【问题描述】:

我的 jqgrid 似乎没有重新加载.. 谁能帮我解决这个问题?..

 $(function(){
    $last_name = $("#search_last_name").val();
    $first_name = $("#search_first_name").val(); 
 });
 $("#search").click(function(){
    jQuery("#list2").jqGrid('setGridParam',{url:"http://localhost/bcb/index.php/bcb_c/grid"});
    jQuery("#list2").trigger("reloadGrid");
});

$("#list2").jqGrid({
    url:'http://localhost/bcb/index.php/bcb_c/grid',
    datatype: "json",
    colNames:['id','First Name','Middle Name', 'Last Name', 'Address'],
    colModel:[
        {name: 'id', index:'id', width:20},
        {name:'first_name',index:'first_name', width:120},
        {name:'middle_name',index:'middle_name', width:120},
        {name:'last_name',index:'last_name', width:120},
        {name:'address', index:'address', width:120}
    ],
    rowNum:10,
    rowList:[10,20,30],
    loadonce: true,
    postData: {pass1: $last_name, pass2: $first_name},
    pager: jQuery('#pager2'),
    width: '550',
    imgpath: gridimgpath,
    scrollrows: true,
    viewrecords: true,
    sortorder: "desc"                 
});

【问题讨论】:

    标签: reload jqgrid-php


    【解决方案1】:

    你应该使用

     pager: '#pager2',   
    

     loadonce: false,   
    

    希望对你有所帮助。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-04-13
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2015-03-20
      • 2015-06-04
      相关资源
      最近更新 更多