修正路由
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
<?php
|
||||
|
||||
namespace App\Controller;
|
||||
|
||||
use App\Constants\HttpEnumCode;
|
||||
use App\Request\PatientPathographyRequest;
|
||||
use App\Services\PatientPathographyService;
|
||||
use Psr\Http\Message\ResponseInterface;
|
||||
|
||||
/**
|
||||
* 家庭成员病情记录
|
||||
*/
|
||||
class PatientPathographyController extends AbstractController
|
||||
{
|
||||
/**
|
||||
* 检测家庭成员是否存在病情记录
|
||||
* @return ResponseInterface
|
||||
*/
|
||||
public function existFamilyPathography(): ResponseInterface
|
||||
{
|
||||
try {
|
||||
$request = $this->container->get(PatientPathographyRequest::class);
|
||||
$request->scene('existFamilyPathography')->validateResolved();
|
||||
|
||||
$PatientPathographyService = new PatientPathographyService();
|
||||
$data = $PatientPathographyService->existFamilyPathography();
|
||||
return $this->response->json($data);
|
||||
}catch (\Throwable $e){
|
||||
return $this->response->json(fail());
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user