The CreatorCon Call for Content is officially open! Get started here.

Date field - list filter condition

balu3
Kilo Guru

Hi All,

How can I place a filter condition on a list to have a date field value on next 30 days, or next 60 days.

find_real_file.png

Say for example, I want to list all the KB articles that expire in next 30 days. How can I achieve this?

There seems to be an option 'relative' instead of 'on'. This adds a query javascript:gs.daysAgo(-30).

Further condition restricts to 'on or after / on or before / after / before / on'. Selecting one of this is actually changing the condition operator on the daysAgo function. Like 'on or after 30 days from now' seems to result in the query >=javascript:gs.daysAgo(-30).

None of these would result in my requirement, unless I add and condition such that

'valid_to on or before 30 days from now' and 'valid_to on or after 0 days from now'.

I'd like to know if there is a better/cleaner approach, as this would look bad when used in any module links.

Thanks in Advance

Balu

9 REPLIES 9

Rajesh Mushke
Mega Sage

Hey balu25int



Can you try like this,



Validto ==> Between




Thanks,
Rajashekhar Mushke
Rising star : 2022 - 2024
Community Leader -2018
Connect me on LinkedIn : Rajashekhar Mushke

Hi Rajesh,



'Between' is fine if there are options to select in the condition.


Say 'Between Today and Next 30 days".



If there was an option like Next 30 days, then I think 'on' would have been sufficient.



Is there any way to add an option like Next 30 days or so to the condition?




Thanks


Balu


Rajesh Mushke
Mega Sage

you can also try like updated ==> before ==> Lat month, it will pulls the last 30 days records


find_real_file.png




Thanks,
Rajashekhar Mushke
Rising star : 2022 - 2024
Community Leader -2018
Connect me on LinkedIn : Rajashekhar Mushke

Hi Rajesh,



I need the report for next 30 days. I'm not able to find this option.



Thanks


Balu