Это собственный фасад
Код: Выделить всё
class PersonService
{
use BaseService
public function list()
{
return $this->resetPage();
}
}
Код: Выделить всё
protected function resetPage()
{
return [
'total'=>1,
'current_page'=>1,
'perpage'=>1,
'data'=>[]
];
}
Код: Выделить всё
public function index(Request $request): JsonResponse
{
$result = PersonService::list();
return $this->success();
}
Код: Выделить всё
Using $this when not in object context
Подробнее здесь: https://stackoverflow.com/questions/785 ... ait-method