You are not logged in.

Announcement

 Téléchargez la dernière version stable de GLPI      -     Et vous, que pouvez vous faire pour le projet GLPI ? :  Contribuer
 Download last stable version of GLPI                      -     What can you do for GLPI ? :  Contribute

#1 2023-08-18 10:33:46

entwan
Member
Registered: 2023-08-18
Posts: 5

Search issue on ticket

Hi,

I'm trying to search on ticket using the api, i want to filter with a specific date.

But in my filters the result does not account for the first filter of date but only the second one.

I'm trying that :

is_deleted=0&as_map=0&

criteria[0][link]=AND&criteria[0][field]=5&criteria[0][searchtype]=equals&criteria[0][value]=2&
criteria[0][link]=AND&criteria[0][field]=155&criteria[0][searchtype]=morethan&criteria[0][value]=2023-08-19&
criteria[0][link]=AND&criteria[0][field]=155&criteria[0][searchtype]=lessthan&criteria[0][value]=2023-08-20

So i take the technician 5 ans i want his tickets from 2023-08-19, like that i have all tickets less than 2023-08-20 but not more that 2023-08-19.
If i switch both date filter i have only morethan 2023-08-19 but not less than 20. I can't get a specific date ?

Thanks if you have advices big_smile

Offline

#2 2023-08-18 10:47:41

entwan
Member
Registered: 2023-08-18
Posts: 5

Re: Search issue on ticket

ok my bad i just havnt increment my criteria

is_deleted=0&as_map=0&

criteria[0][link]=AND&criteria[0][field]=5&criteria[0][searchtype]=equals&criteria[0][value]=2&
criteria[1][link]=AND&criteria[1][field]=155&criteria[1][searchtype]=morethan&criteria[1][value]=2023-08-19&
criteria[2][link]=AND&criteria[2][field]=155&criteria[2][searchtype]=lessthan&criteria[2][value]=2023-08-20

that works

Offline

Board footer

Powered by FluxBB