ligerui加载数据(服务器)

2020-05-20 社会 65阅读
function searchbtn_click() {
    if (window.winfilter) {
        window.winfilter.show();
    }
    else {
        var filtercontainer = $("").width(500).height(200).hide();
        window.filter = filtercontainer.ligerFilter({ fields: fields });
        window.winfilter = $.ligerDialog.open({
            width: 540, height: 288,
            target: filtercontainer, isResize: true, top: 50,
            buttons: [
                {
                    text: "确定", onclick: function (item, dialog) {
                        var group = window.filter.getData();
                        searchjson = JSON.stringify(group);
                        gridRefresh();
                        dialog.hide();
                    }
                },
                { text: "取消", onclick: function (item, dialog) { dialog.hide(); } }
            ]
        });
    }
};
function gridRefresh() {
    if (grid) {
        var gridparms = [];
        grid.options.parms[1].value = searchjson;
        gridparms.push({ name: "funcid", value: "getprimary" });
        gridparms.push({ name: "searchjson", value: searchjson });
        gridparms.push({ name: "page", value: 1 });
        gridparms.push({ name: "pagesize", value: grid.options.pageSize });
        grid.loadServerData(gridparms);
    }
}
声明:你问我答网所有作品(图文、音视频)均由用户自行上传分享,仅供网友学习交流。若您的权利被侵害,请联系fangmu6661024@163.com