This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers\Mobile\ConectaCidadao\ExameLaboratorial;
|
||||
|
||||
use App\Http\Controllers\Controller;
|
||||
use App\Services\Mobile\ConectaCidadao\ExameLaboratorial\AgendamentoExameService;
|
||||
use Illuminate\Http\Response;
|
||||
|
||||
class AgendamentoExameController extends Controller
|
||||
{
|
||||
public function elegibilidade()
|
||||
{
|
||||
return response()->json(AgendamentoExameService::elegibilidade(), Response::HTTP_OK);
|
||||
}
|
||||
|
||||
public function unidadesColeta()
|
||||
{
|
||||
return response()->json(AgendamentoExameService::unidadesColeta(), Response::HTTP_OK);
|
||||
}
|
||||
|
||||
public function exames()
|
||||
{
|
||||
return response()->json(AgendamentoExameService::exames(), Response::HTTP_OK);
|
||||
}
|
||||
|
||||
public function jornadas()
|
||||
{
|
||||
return response()->json(AgendamentoExameService::jornadas(), Response::HTTP_OK);
|
||||
}
|
||||
|
||||
public function agendar()
|
||||
{
|
||||
return response()->json(AgendamentoExameService::agendar(), Response::HTTP_CREATED);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers\Mobile\ConectaCidadao\ExameLaboratorial;
|
||||
|
||||
use App\Http\Controllers\Controller;
|
||||
use App\Services\Mobile\ConectaCidadao\ExameLaboratorial\LaudoService;
|
||||
use Illuminate\Http\Response;
|
||||
|
||||
class LaudoController extends Controller
|
||||
{
|
||||
public function laudos()
|
||||
{
|
||||
return response()->json(LaudoService::laudos(), Response::HTTP_OK);
|
||||
}
|
||||
|
||||
public function download(int $laudoId)
|
||||
{
|
||||
$laudo = LaudoService::download($laudoId);
|
||||
|
||||
return response()->download($laudo['caminho'], $laudo['nome']);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user