getModelFilter(); $query = $this->query(); if($this->withRelationships){ $query->with($this->withRelationships); } if ($filter) { $query->filter(request()->input(), $filter)->whereIn('need_pay', [Oldmen::PAY_NOTICE, Oldmen::PAY_ARREAR]); } return $query; } }