Filtering Asset Link data

37 مرّة مشاهدة
التخطي إلى أول رسالة غير مقروءة

Michael Dixon

غير مقروءة،
22‏/02‏/2021، 9:32:35 م22‏/2‏/2021
إلى Accelo Developers
I am trying to filter Asset Link data as per https://api.accelo.com/docs/#list-asset-links by using the date filters, but it looks like this isn't working.

The API doco says I can use standard date filters using "date_start" and "date_end", but the fields in the object are actually called "start_date" and "end_date".  This is the first problem as the date filtering doco mentions that the standard should be "<date_field>_before" and "<date_field>_after".

I have tried both "date_start" and "start_date" when constructing the date filter, but neither seems to work anyway.  i.e.:

_filters=start_date_after(1575032400)
_filters=date_start_after(1575032400)

Regardless of syntax I still get *all* asset link records.

Has anyone managed to successfully filter asset links via the API?

Nick Clark

غير مقروءة،
07‏/03‏/2021، 8:10:03 م7‏/3‏/2021
إلى Accelo Developers
Hi Michael, 

I've been informed that this is a bug however there is a workaround you can use today, and I can confirm this has worked in my testing. Could you please try the following request:
{{url}}/api/v0/assets/links?_filters=date_date_start_after(1614657465)
 
The double use of date is required but should give you the information you require.

Regards,
Nick 
الرد على الكل
رد على الكاتب
إعادة توجيه
0 رسالة جديدة