improvement: appointments history component added to patients feature.
This commit is contained in:
@@ -37,6 +37,16 @@ export class PatientsController {
|
||||
return this.patientsService.findAll(query);
|
||||
}
|
||||
|
||||
@Get(':id/appointments')
|
||||
@ApiOperation({
|
||||
summary:
|
||||
'List this patient\'s appointments for the current clinic (requires TAB_PATIENTS_READ; not gated by appointments permission)',
|
||||
})
|
||||
listAppointments(@Param('id') id: string, @Req() req: { user: { id: string; organizationId?: string } }) {
|
||||
const organizationId = this.patientsService.getOrganizationIdFromUser(req.user);
|
||||
return this.patientsService.listAppointments(id, organizationId, req.user.id);
|
||||
}
|
||||
|
||||
@Get(':id')
|
||||
@ApiOperation({ summary: 'Get one patient by id' })
|
||||
findOne(@Param('id') id: string) {
|
||||
|
||||
Reference in New Issue
Block a user