UserHomeController.php 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. <?php
  2. namespace App\Generated\Controllers\V1_1;
  3. use App\Generated\V1_1\Messages\UserHome\GetLikeMeListMessage;
  4. use App\Generated\V1_1\Messages\UserHome\GetVisitorListMessage;
  5. use App\Generated\V1_1\Messages\UserHome\RemindComplementCardMessage;
  6. use App\Http\Controllers\Controller;
  7. use App\Http\Services\V1_1\UserHomeService;
  8. use App\Generated\V1_1\Messages\UserHome\GetMyLikeListMessage;
  9. use DB;
  10. use App\Generated\V1_1\Messages\UserHome\GetPopularityMessage;
  11. class UserHomeController extends Controller
  12. {
  13. public $handler;
  14. public function __construct(UserHomeService $handler)
  15. {
  16. $this->handler = $handler;
  17. }
  18. public function getPopularity(GetPopularityMessage $message)
  19. {
  20. $message->validateInput();
  21. $this->handler->getPopularity($message);
  22. $message->validateOutput();
  23. return $message->getResponse();
  24. }
  25. public function remindComplementCard(RemindComplementCardMessage $message)
  26. {
  27. $message->validateInput();
  28. $this->handler->remindComplementCard($message);
  29. $message->validateOutput();
  30. return $message->getResponse();
  31. }
  32. public function getVisitorList(GetVisitorListMessage $message)
  33. {
  34. $message->validateInput();
  35. $this->handler->getVisitorList($message);
  36. $message->validateOutput();
  37. return $message->getResponse();
  38. }
  39. public function getMyLikeList(GetMyLikeListMessage $message)
  40. {
  41. $message->validateInput();
  42. $this->handler->getMyLikeList($message);
  43. $message->validateOutput();
  44. return $message->getResponse();
  45. }
  46. public function getLikeMeList(GetLikeMeListMessage $message)
  47. {
  48. $message->validateInput();
  49. $this->handler->getLikeMeList($message);
  50. $message->validateOutput();
  51. return $message->getResponse();
  52. }
  53. }