带有 Group By 的 jQuery Table 插件

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/1576908/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-26 11:46:22  来源:igfitidea点击:

jQuery Table Plugin with Group By

jquerypluginsgroup-by

提问by k0ni

I need a jQuery Plugin that makes a Sortable and Groupable List of my Data. My Data is a Tasklist with a duedate, and i would like to have them grouped by date, and sortable. Is there a plugin that can handle that? I'm actually using dataTables, but it has some strange behavtheitroad and bugs...

我需要一个 jQuery 插件来制作我的数据的可排序和可分组列表。我的数据是一个有截止日期的任务列表,我希望它们按日期分组,并且可以排序。有没有可以处理的插件?我实际上在使用数据表,但它有一些奇怪的行为和错误......

Like:

喜欢:

16-10-2009
- Task 1
- Task 2
17-10-2009
- Task 4
18-10-2090
- Task 3

回答by Dan

Many jQuery plugins can provide you a smart solution:

许多 jQuery 插件可以为您提供智能解决方案:

Best for simple groups: http://www.trirand.com/blog/jqgrid/jqgrid.html

最适合简单团体:http: //www.trirand.com/blog/jqgrid/jqgrid.html

Easier: http://www.jankoatwarpspeed.com/examples/expandable-rows

更简单:http: //www.jankoatwarpspeed.com/examples/expandable-rows

My recommendation to complex groupings: http://www.hanpau.com/index.php?page=jqtreetable

我对复杂分组的建议:http: //www.hanpau.com/index.php?page= jqtreetable

Hope that helps :)

希望有帮助:)

回答by Bryan Larsen

The original question said they were using dataTables, which was probably why this answer wasn't offered:

最初的问题说他们正在使用 dataTables,这可能就是为什么没有提供这个答案的原因:

http://jquery-datatables-row-grouping.googlecode.com/svn/trunk/index.html

http://jquery-datatables-row-grouping.googlecode.com/svn/trunk/index.html

However, things have probably changed in the last couple of years, so it's quite likely that dataTables is the best answer today.

但是,在过去几年中情况可能发生了变化,因此 dataTables 很可能是今天的最佳答案。

回答by Vladimir Georgiev

Check out ShieldUI's Grid grouping functionality:

查看 ShieldUI 的网格分组功能:

http://demos.shieldui.com/web/grid-grouping/grouping

http://demos.shieldui.com/web/grid-grouping/grouping

It is a very flexible grid with a lot of customization options available.

这是一个非常灵活的网格,有很多可用的自定义选项。

回答by RameshVel

For table sorting, you can check out **tablesorter**

对于表格排序,您可以查看**tablesorter**