GrafeasGroup / blossom

The website. The app. The everything.
6 stars 3 forks source link

Add `isnull` filter options to API enpoints #201

Closed TimJentzsch closed 3 years ago

TimJentzsch commented 3 years ago

Add the option to filter if a given property is null/None. This can be accomplished by adding the isnull option to the filter_fields: https://stackoverflow.com/a/63125753

This would be useful for example to determine the claimed posts of a user (submission?claimed_by=<user_id>&archived=False&completed_by__isnull=True) or the posts currently available in the queue (submission?claimed_by__is_null=False&archived=False&completed_by__isnull=True).

Then we don't need #187 anymore.