PostService.php 613 B

123456789101112131415161718192021222324252627282930
  1. <?php
  2. /*
  3. * This file is part of the Jiannei/lumen-api-starter.
  4. *
  5. * (c) Jiannei <longjian.huang@foxmail.com>
  6. *
  7. * This source file is subject to the MIT license that is bundled
  8. * with this source code in the file LICENSE.
  9. */
  10. namespace App\Services;
  11. use App\Contracts\Repositories\PostRepository;
  12. use App\Repositories\Presenters\PostPresenter;
  13. class PostService
  14. {
  15. private $repository;
  16. public function __construct(PostRepository $repository)
  17. {
  18. $this->repository = $repository;
  19. }
  20. public function handleSearchList()
  21. {
  22. return $this->repository->searchPage();
  23. }
  24. }