CardUseLogRepositoryEloquent.php 902 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php
  2. namespace App\Repositories\Eloquent;
  3. use App\Contracts\Repositories\CardUseLogRepository;
  4. use App\Models\CardUseLog;
  5. use App\Repositories\Criteria\CardUseLogCriteria;
  6. use App\Repositories\Presenters\CardUseLogPresenter;
  7. class CardUseLogRepositoryEloquent extends BaseRepository implements CardUseLogRepository
  8. {
  9. /**
  10. * Boot up the repository, pushing criteria.
  11. *
  12. * @throws \Prettus\Repository\Exceptions\RepositoryException
  13. */
  14. public function boot()
  15. {
  16. $this->pushCriteria(app(CardUseLogCriteria::class));
  17. $this->setPresenter(CardUseLogPresenter::class);
  18. }
  19. public function model()
  20. {
  21. // TODO: Implement model() method.
  22. return CardUseLog::class;
  23. }
  24. public function validator()
  25. {
  26. return null;
  27. }
  28. public function searchPage($limit = null)
  29. {
  30. return $this->paginate($limit);
  31. }
  32. }