1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-09 20:52:56 +01:00

Merge pull request #8913 from gescarra/patch-1

Add "uninvoiced" Task Filter
This commit is contained in:
David Bomba 2023-10-28 15:12:38 +11:00 committed by GitHub
commit a25167ed90
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -60,6 +60,7 @@ class TaskFilters extends QueryFilters
* Statuses we need to handle
* - all
* - invoiced
* - uninvoiced
*
* @param string $value The invoice status as seen by the client
* @return Builder
@ -80,6 +81,10 @@ class TaskFilters extends QueryFilters
$this->builder->whereNotNull('invoice_id');
}
if (in_array('uninvoiced', $status_parameters)) {
$this->builder->whereNull('invoice_id');
}
return $this->builder;
}