領収証発行サービス
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

50 lines
1.2KB

  1. <?php
  2. namespace App\Http\Controllers\Web\Custom\HelloTechno;
  3. use App\Codes\Custom;
  4. use App\Codes\UserRole;
  5. use App\Http\Controllers\Web\IParam;
  6. use App\Http\Controllers\Web\WebController;
  7. use App\Logic\ReceiptIssuingOrder\CreateManager;
  8. use App\Util\Custom\HelloTechno\API;
  9. use Illuminate\Http\JsonResponse;
  10. use Illuminate\Http\Request;
  11. use Illuminate\Support\Facades\Http;
  12. use Illuminate\Support\Facades\Log;
  13. class ParkingsController extends WebController
  14. {
  15. public function name(): string
  16. {
  17. return "[HelloTechno専用]駐車場情報取得";
  18. }
  19. public function description(): string
  20. {
  21. return "[HelloTechno専用]駐車場情報を取得する";
  22. }
  23. public function __construct(
  24. protected ParkingsParam $param,
  25. ) {
  26. $this->middleware('auth:sanctum');
  27. $this->roleAllow(UserRole::NORMAL_ADMIN);
  28. $this->customAllow = [Custom::HELLO_TECHNO];
  29. }
  30. protected function getParam(): IParam
  31. {
  32. return $this->param;
  33. }
  34. protected function run(Request $request): JsonResponse
  35. {
  36. $param = $this->param;
  37. $list = API::getParkings($param->customerCode, $param->parkingManagementCode);
  38. return $this->successResponse(['records' => $list]);
  39. }
  40. }