22 lines
495 B
PHP
22 lines
495 B
PHP
<?php
|
|
|
|
namespace App\Infrastructure\Http\Controllers\Web;
|
|
|
|
use App\Domain\Patient\Actions\GetDepartmentJournalPatientAction;
|
|
use Illuminate\Http\Request;
|
|
|
|
class PatientController
|
|
{
|
|
public function getDepartmentPatient(
|
|
Request $request,
|
|
GetDepartmentJournalPatientAction $patientAction
|
|
)
|
|
{
|
|
$departmentId = $request->query('departmentId');
|
|
|
|
$patients = $patientAction->execute((int) $departmentId);
|
|
|
|
return response()->json($patients);
|
|
}
|
|
}
|