Siirry sisältöön
Menu
Sinun on rekisteröidyttävä, jotta voit olla vuorovaikutuksessa yhteisön kanssa.
Tämä kysymys on merkitty
2 Vastaukset
4852 Näkymät

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!

Avatar
Hylkää
Paras vastaus

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

 

 

Avatar
Hylkää
Tekijä Paras vastaus

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!

Avatar
Hylkää
Aiheeseen liittyviä artikkeleita Vastaukset Näkymät Toimenpide
0
syysk. 25
1855
1
heinäk. 21
2796
0
huhtik. 16
4365
1
toukok. 15
3988
0
tammik. 25
2617