* updated expressive version
This commit is contained in:
31
src/App/Handler/SolutionTimeIntervalHandler.php
Normal file
31
src/App/Handler/SolutionTimeIntervalHandler.php
Normal file
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
namespace App\Handler;
|
||||
|
||||
use ApiLibs\AbstractHandler\CrudHandler;
|
||||
use App\Service\SolutionTimeIntervalService;
|
||||
use Psr\Http\Message\ResponseInterface;
|
||||
use Psr\Http\Message\ServerRequestInterface;
|
||||
use Zend\Diactoros\Response\JsonResponse;
|
||||
|
||||
class SolutionTimeIntervalHandler extends CrudHandler
|
||||
{
|
||||
/** @var SolutionTimeIntervalService */
|
||||
private $solutionTimeIntervalService;
|
||||
|
||||
public function __construct(SolutionTimeIntervalService $facilityLocationService)
|
||||
{
|
||||
$this->solutionTimeIntervalService = $facilityLocationService;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return all faults accessible to the user
|
||||
*
|
||||
* @param ServerRequestInterface $request
|
||||
* @return ResponseInterface
|
||||
*/
|
||||
public function getList(ServerRequestInterface $request): ResponseInterface
|
||||
{
|
||||
return new JsonResponse($this->solutionTimeIntervalService->getList());
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user