Filtering with float fields
Alejandro Fernández <[email protected]>
| Newsgroups | gmane.comp.cms.jahia.template |
|---|---|
| Organization | mediadvanced |
| Message-ID | <200604241827482.SM01876@rewind> |
Hi,
I am trying to apply a filter to a container in a field defined as Float. I
have only found how to add a RangeClause to a ContainerFilterBean in the
case of string and date, but not Float.
I am working with Jahia 4.0.5. and this is the source code for the
filtering:
myContainerFilter = new ContainerFilterBean("aFloatField", true,
jParams.getEntryLoadRequest()); // with the field name
// Adding equality comparison with selected values
myContainerFilter.addRangeClause(">","<",valueFrom,valueTo);
This filtering always returns 0 element found, because only String values
are allowed for the fields valueFrom and valueTo.
Thank you for your helping.
Cheers.
Alex.