|
@@ -10,7 +10,7 @@ using OnlineMetodist.API.Services;
|
|
|
|
|
|
namespace OnlineMetodist.API.Controllers
|
|
|
{
|
|
|
- [Route("api/[controller]/[action]")]
|
|
|
+ [Route("[controller]/[action]")]
|
|
|
[ApiController]
|
|
|
[Authorize(Roles = "Администратор")]
|
|
|
public class AdministratorController : ControllerBase
|
|
@@ -111,8 +111,8 @@ namespace OnlineMetodist.API.Controllers
|
|
|
return StatusCode(500, "Internal server error");
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
[HttpPut]
|
|
|
- [Route("SetAdministrator")]
|
|
|
[Authorize(Roles = "Администратор")]
|
|
|
public async Task<IActionResult> SetAdministrator(Guid idEmploeyy)
|
|
|
{
|
|
@@ -136,7 +136,6 @@ namespace OnlineMetodist.API.Controllers
|
|
|
}
|
|
|
|
|
|
[HttpDelete]
|
|
|
- [Route("DeleteAdministrator")]
|
|
|
[Authorize(Roles = "Администратор")]
|
|
|
public async Task<IActionResult> DeleteAdministrator(Guid idEmploeyy)
|
|
|
{
|
|
@@ -160,7 +159,6 @@ namespace OnlineMetodist.API.Controllers
|
|
|
}
|
|
|
|
|
|
[HttpPut]
|
|
|
- [Route("SetDelegateNMC")]
|
|
|
[Authorize(Roles = "Администратор")]
|
|
|
public async Task<IActionResult> SetDelegateNMC(Guid idEmploeyy)
|
|
|
{
|
|
@@ -184,7 +182,6 @@ namespace OnlineMetodist.API.Controllers
|
|
|
}
|
|
|
|
|
|
[HttpDelete]
|
|
|
- [Route("DeleteDelegateNMC")]
|
|
|
[Authorize(Roles = "Администратор")]
|
|
|
public async Task<IActionResult> DeleteDelegateNMC(Guid idEmploeyy)
|
|
|
{
|
|
@@ -208,7 +205,6 @@ namespace OnlineMetodist.API.Controllers
|
|
|
}
|
|
|
|
|
|
[HttpPut]
|
|
|
- [Route("SetHeadOfCorpuse")]
|
|
|
[Authorize(Roles = "Администратор")]
|
|
|
public async Task<IActionResult> SetHeadOfCorpuse(Guid idEmploeyy)
|
|
|
{
|
|
@@ -232,7 +228,6 @@ namespace OnlineMetodist.API.Controllers
|
|
|
}
|
|
|
|
|
|
[HttpDelete]
|
|
|
- [Route("DeleteHeadOfCorpuse")]
|
|
|
[Authorize(Roles = "Администратор")]
|
|
|
public async Task<IActionResult> DeleteHeadOfCorpuse(Guid idEmploeyy)
|
|
|
{
|