Make sure we're getting only active expenses
This commit is contained in:
parent
ac7a5a65e5
commit
2dd3dd5814
@ -8,9 +8,6 @@ use Illuminate\Support\Collection;
|
||||
use Prettus\Repository\Contracts\CacheableInterface;
|
||||
use Prettus\Repository\Traits\CacheableRepository;
|
||||
|
||||
/**
|
||||
* Class ExpenseRepository
|
||||
*/
|
||||
class ExpenseRepository extends Repository implements CacheableInterface
|
||||
{
|
||||
use CacheableRepository;
|
||||
@ -35,6 +32,7 @@ class ExpenseRepository extends Repository implements CacheableInterface
|
||||
{
|
||||
$where = [
|
||||
'type' => $type,
|
||||
'active' => true,
|
||||
['airline_id', '=', null],
|
||||
];
|
||||
|
||||
@ -59,6 +57,7 @@ class ExpenseRepository extends Repository implements CacheableInterface
|
||||
if ($airline_id) {
|
||||
$where = [
|
||||
'type' => $type,
|
||||
'active' => true,
|
||||
'airline_id' => $airline_id,
|
||||
];
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user