Skip to content
This repository has been archived by the owner on Jun 25, 2022. It is now read-only.

Commit

Permalink
feat(back-end): allow only the administrator to register other employees
Browse files Browse the repository at this point in the history
  • Loading branch information
CarlosPavajeau committed May 28, 2021
1 parent c52c8d2 commit 6f5e0ba
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions Kaizen/Controllers/EmployeesController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ public async Task<ActionResult<EmployeeViewModel>> PutEmployee(string id, Employ
}

[HttpPost]
[Authorize(Roles = "Administrator")]
public async Task<ActionResult<EmployeeViewModel>> PostEmployee(EmployeeInputModel employeeModel)
{
EmployeeCharge employeeCharge = await _employeesRepository.GetAllEmployeeCharges()
Expand Down

0 comments on commit 6f5e0ba

Please sign in to comment.