跳至内容
菜单
此问题已终结
2 回复
4813 查看

Hi,

is there a way to group by a field in a search view in a case insensitive way?

i.e. grouping "leo" and "Leo" together.

Thanks!

形象
丢弃
最佳答案

AFAIK you have to redefine ``read_group`` to fit your needs.

 

 

形象
丢弃
编写者 最佳答案

Nicolas is right: to do that I have to change read_group. It is a big method with no hooks, so the solution for now has been to copy all of it in my module and add a few lines similar to those the handle dates in the original code.

Date handling in the original is somewhat similar: dates from the same month are grouped together, while I wanted to group together string fields that are equal ignoring case.

That has been refactored in trunk to be hookable.

Thanks!

形象
丢弃
相关帖文 回复 查看 活动
0
5月 24
1767
1
7月 21
2747
0
4月 16
4298
1
5月 15
3961
0
1月 25
2465