jQgrid - 在网格的最后移动第一列列(td)后出现问题 [英] jQgrid - Getting issue after moving first column column(td) at last of grid

查看:102
本文介绍了jQgrid - 在网格的最后移动第一列列(td)后出现问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有问题,jQgrid最后移动第一列(多选复选框),如下所示由oleg回答

I have issue with jQgrid moving first column(multiselect checkbox) at last as given in this answer by oleg.

问题:选择并删除行后
网格列与标题列不对齐。

Issue: after select and delete the row the grid column is mis-aligned with header column.

那么,我该如何管理呢?

So, how can i manage it??

推荐答案

旧答案,您参考的是很老(4。5年前)。 jqGrid现在有两个主要的分支:免费jqGrid ,我开发并提供相同的MIT / GNU GPLv2许可证与以前一样,商业Guriddo jqGrid JS可在价格下获得。我在免费的jqGrid中实现了许多新功能。

The old answer, which you reference is very old (4.5 years ago). There are now two main forks of jqGrid: free jqGrid, which I develop and provide under the same MIT / GNU GPLv2 licenses like it was before and the commercial Guriddo jqGrid JS available under the prices. I implemented many new features in free jqGrid.

重写多重选择功能的实现。 jqGrid的旧代码包含许多位于多选列cb必须存在且位于网格开头的位置。例如,免费的jqGrid有新选项 multiselectPosition:left。您可以使用 multiselectPosition:right来更改多选列的位置。另外,可以使用 remapColumnsByName (参见答案)或 remapColumns 更改cb列的位置(带有多选复选框的列)并将其放在任何地方在网格中。 jqGrid的主要代码不依赖于列的位置,并且支持列的任何位置。可以指定 multiselectPosition 的任何其他值,例如, multiselectPosition:none(参见功能列表,在免费的jqGrid 4.9.0中实现。它将创建具有多选功能的网格,而不包括任何多选列

The implementation of multiselect feature is rewritten. The old code of jqGrid contained many placed where the multiselect column "cb" must exist and to be at the beginning of the grid. For example, free jqGrid have new option multiselectPosition: "left". You can use multiselectPosition: "right" to change the position of multiselect column. Additionally one can use remapColumnsByName (see the answer) or remapColumns to change the position of "cb" column (the column with multiselect checkboxes) and place it on any place in the grid. The main code of jqGrid is not depend on the position of the column and any place of the column is supported. One can specify any other value of multiselectPosition, for example, multiselectPosition: "none" (see the feature list, implemented in free jqGrid 4.9.0). It will create grid with multiselect functionality whithout any multiselect column at all.

还有许多其他选项,例如 multiPageSelection :true ,这也非常实用(参见答案的>演示。此外,可以使用 hasMultiselectCheckBox 回调来指定只应在网格的某些特定行中创建 multiselect 复选框,而不是默认情况下在所有行中创建复选框。

There are many other option, like multiPageSelection: true, which can be very practical too (see the demo from the answer). Moreover one can use hasMultiselectCheckBox callback to specify that multiselect checkbox should be created only in some specific rows of the grid instead of the default creating the checkbox in all rows.

这篇关于jQgrid - 在网格的最后移动第一列列(td)后出现问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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