aboutsummaryrefslogtreecommitdiff
path: root/src/DevHive.Web/Controllers/TechnologyController.cs
diff options
context:
space:
mode:
authortranstrike <transtrike@gmail.com>2021-01-14 09:34:08 +0200
committertranstrike <transtrike@gmail.com>2021-01-14 09:34:08 +0200
commitfac00296772803663f76fe89d68bee3d1b406078 (patch)
tree8ad22561aa4ab79e622be23dbc9ba0daf9d5d6fe /src/DevHive.Web/Controllers/TechnologyController.cs
parent2948a92492141f4d807449191901f499530d8465 (diff)
downloadDevHive-fac00296772803663f76fe89d68bee3d1b406078.tar
DevHive-fac00296772803663f76fe89d68bee3d1b406078.tar.gz
DevHive-fac00296772803663f76fe89d68bee3d1b406078.zip
Fixed Language & Technology Update methods
Diffstat (limited to 'src/DevHive.Web/Controllers/TechnologyController.cs')
-rw-r--r--src/DevHive.Web/Controllers/TechnologyController.cs12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/DevHive.Web/Controllers/TechnologyController.cs b/src/DevHive.Web/Controllers/TechnologyController.cs
index 905a71d..964bafc 100644
--- a/src/DevHive.Web/Controllers/TechnologyController.cs
+++ b/src/DevHive.Web/Controllers/TechnologyController.cs
@@ -36,20 +36,20 @@ namespace DevHive.Web.Controllers
}
[HttpGet]
- public async Task<IActionResult> GetById(Guid id)
+ public async Task<IActionResult> GetById(Guid technologyId)
{
- TechnologyServiceModel technologyServiceModel = await this._technologyService.GetTechnologyById(id);
+ TechnologyServiceModel technologyServiceModel = await this._technologyService.GetTechnologyById(technologyId);
TechnologyWebModel technologyWebModel = this._technologyMapper.Map<TechnologyWebModel>(technologyServiceModel);
return new OkObjectResult(technologyWebModel);
}
[HttpPut]
- public async Task<IActionResult> Update(Guid id, [FromBody] UpdateTechnologyWebModel updateModel)
+ public async Task<IActionResult> Update(Guid technologyId, [FromBody] UpdateTechnologyWebModel updateModel)
{
UpdateTechnologyServiceModel updateTechnologyWebModel = this._technologyMapper.Map<UpdateTechnologyServiceModel>(updateModel);
- bool result = await this._technologyService.UpdateTechnology(updateTechnologyWebModel);
+ bool result = await this._technologyService.UpdateTechnology(technologyId, updateTechnologyWebModel);
if (!result)
return new BadRequestObjectResult("Could not update Technology");
@@ -58,9 +58,9 @@ namespace DevHive.Web.Controllers
}
[HttpDelete]
- public async Task<IActionResult> Delete(Guid id)
+ public async Task<IActionResult> Delete(Guid technologyId)
{
- bool result = await this._technologyService.DeleteTechnology(id);
+ bool result = await this._technologyService.DeleteTechnology(technologyId);
if (!result)
return new BadRequestObjectResult("Could not delete Technology");