I have some json and want to filter out stuff older than the last hour… But I don’t know how to do it with the rejectattr; my code is below:
{% set tsFrom = as_timestamp(now()) - 3600 %}
{{ value_json.results|rejectattr('submissionDate', 'lt', tsFrom)|map(attribute='harvesterId')|unique|list|count }}
The submissionDate is formatted as: “submissionDate”:“2021-07-27T14:21:54.7079623Z”