fix(employee): missing permission check
This commit is contained in:
parent
d09ff6cff1
commit
d2d9181493
1 changed files with 6 additions and 1 deletions
|
|
@ -739,7 +739,12 @@ export class EmployeeFileController extends Controller {
|
|||
@Get("file-in-country-notice/{noticeId}")
|
||||
@Security("keycloak")
|
||||
@Tags("Employee In Country Notice")
|
||||
async getNotice(@Path() employeeId: string, @Path() noticeId: string) {
|
||||
async getNotice(
|
||||
@Request() req: RequestWithUser,
|
||||
@Path() employeeId: string,
|
||||
@Path() noticeId: string,
|
||||
) {
|
||||
await this.checkPermission(req.user, employeeId);
|
||||
return await getFile(fileLocation.employee.inCountryNotice(employeeId, noticeId));
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue