jqgrid v4.4.5 rtl水平问题 [英] jqgrid v4.4.5 rtl horizontal problem

查看:126
本文介绍了jqgrid v4.4.5 rtl水平问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用jqgrid v4.4.5和jquery v1.9.1。当我调整jqgrid的大小并且水平滚动条出现时,它可以在IE和Firefox上运行。但在Chrome中无效,列被截断,宽度计算错误。



我该如何解决这个问题?



I use jqgrid v4.4.5 and jquery v1.9.1. When I resize jqgrid and the horizontal scrollbar appears it work on IE and Firefox. but in Chrome not work ,columns truncated and wrong width calculation.

How can i solve this?

<script>

        $(function () {
            $("#UsersGrid").jqGrid({
                direction:"rtl",
                url: 'jqGridHandler.ashx',
                datatype: 'json',
                height: 250,
                colNames: ['UserID', 'UserName', 'FirstName', 'MiddleName', 'LastName', 'EmailID'],
                colModel: [
                        { name: 'UserID', index: 'UserID', width: 100, sortable: true },
                        { name: 'UserName', width: 100, sortable: true },
                        { name: 'FirstName', width: 100, sortable: true },
                        { name: 'MiddleName', width: 100, sortable: true },
                        { name: 'LastName', width: 100, sortable: true },
                        { name: 'EmailID', width: 150, sortable: true }
                ],
                rowNum: 10,
                rowList: [10, 20, 30],
                pager: '#UsersGridPager',
                sortname: 'UserID',
                viewrecords: true,
                sortorder: 'asc',
                caption: 'JSON Example'
            });

            $("#UsersGrid").jqGrid('navGrid', '#UsersGridPager', { edit: false, add: false, del: false });
        });
    </script>

推荐答案

function ( ){


#UsersGrid)。jqGrid( {
方向: rtl
url:' jqGridHandler.ashx'
datatype:' json'
height: 250
colNames:[ UserID'' UserName' FirstName'' MiddleName'' LastName'' EmailID'],
colModel:[
{name:' UserID ',index:' UserID',width: 100 ,可排序: true },
{name:' < span class =code-string> UserName',width: 100 ,sortable: true },
{name:' FirstName',width: 100 ,可排序: true },
{name:' MiddleName',width: 100 ,sortable: true },
{name:' LastName',width: 100 ,可排序:< span class =code-keyword> true
},
{name:' EmailID' ,width: 150 ,可排序: true }
],
rowNum: 10
rowList:[ 10 20 30 ],
寻呼机:' #UsersGridPager'
sortname:' UserID'
viewreco rds: true
sortorder:' asc '
标题:' JSON示例'
}) ;
("#UsersGrid").jqGrid({ direction:"rtl", url: 'jqGridHandler.ashx', datatype: 'json', height: 250, colNames: ['UserID', 'UserName', 'FirstName', 'MiddleName', 'LastName', 'EmailID'], colModel: [ { name: 'UserID', index: 'UserID', width: 100, sortable: true }, { name: 'UserName', width: 100, sortable: true }, { name: 'FirstName', width: 100, sortable: true }, { name: 'MiddleName', width: 100, sortable: true }, { name: 'LastName', width: 100, sortable: true }, { name: 'EmailID', width: 150, sortable: true } ], rowNum: 10, rowList: [10, 20, 30], pager: '#UsersGridPager', sortname: 'UserID', viewrecords: true, sortorder: 'asc', caption: 'JSON Example' });


#UsersGrid)。jqGrid(< span class =code-string>' navGrid'' #UsersGridPager',{edit: false ,添加: false ,del: false });
});
< / script>
("#UsersGrid").jqGrid('navGrid', '#UsersGridPager', { edit: false, add: false, del: false }); }); </script>


这篇关于jqgrid v4.4.5 rtl水平问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆