Fixed uncapitalized i in Id for all Controllers

This commit is contained in:
Nicolai Ort 2020-07-14 18:10:57 +02:00
parent 959c43ca1e
commit f0cf54513f
7 changed files with 14 additions and 14 deletions

View File

@ -69,7 +69,7 @@ namespace ScrumTaskboard.Controllers
public async Task<IActionResult> PutCategory(int id, ScrumCategory category)
{
// The category's ID must not be changed
if (id != category.id)
if (id != category.Id)
{
return BadRequest();
}
@ -106,7 +106,7 @@ namespace ScrumTaskboard.Controllers
await _context.SaveChangesAsync();
// The new user story has been created and can be called up using the GetUserstory method
return CreatedAtAction("GetCategory", new { id = category.id }, category);
return CreatedAtAction("GetCategory", new { id = category.Id }, category);
}
// DELETE: api/category/1

View File

@ -64,7 +64,7 @@ namespace ScrumTaskboard.Controllers
public async Task<IActionResult> PutProject(int id, ScrumProject projects)
{
// The project's ID must not be changed
if (id != projects.id)
if (id != projects.Id)
{
return BadRequest();
}
@ -101,7 +101,7 @@ namespace ScrumTaskboard.Controllers
await _context.SaveChangesAsync();
// The new project has been created and can be called up using the GetProject method
return CreatedAtAction("GetProject", new { id = projects.id }, projects);
return CreatedAtAction("GetProject", new { id = projects.Id }, projects);
}
// DELETE: api/Project/5

View File

@ -72,7 +72,7 @@ namespace ScrumTaskboard.Controllers
public async Task<IActionResult> PutSprint(int id, ScrumSprint sprint)
{
// The sprint's ID must not be changed
if (id != sprint.id)
if (id != sprint.Id)
{
return BadRequest();
}
@ -109,7 +109,7 @@ namespace ScrumTaskboard.Controllers
await _context.SaveChangesAsync();
// The new sprint has been created and can be called up using the GetSprint method
return CreatedAtAction("GetSprint", new { id = sprint.id }, sprint);
return CreatedAtAction("GetSprint", new { id = sprint.Id }, sprint);
}
// DELETE: api/Sprint/5

View File

@ -59,7 +59,7 @@ namespace ScrumTaskboard.Controllers
public async Task<IActionResult> PutStatus(int id, ScrumStatus userstory)
{
// The status' ID must not be changed
if (id != userstory.id)
if (id != userstory.Id)
{
return BadRequest();
}
@ -96,7 +96,7 @@ namespace ScrumTaskboard.Controllers
await _context.SaveChangesAsync();
// The new status has been created and can be called up using the GetStatus method
return CreatedAtAction("GetStatus", new { id = userstory.id }, userstory);
return CreatedAtAction("GetStatus", new { id = userstory.Id }, userstory);
}
// DELETE: api/status/1

View File

@ -81,7 +81,7 @@ namespace ScrumTaskboard.Controllers
public async Task<IActionResult> PutTask(int id, ScrumTask task)
{
// The task's ID must not be changed
if (id != task.id)
if (id != task.Id)
{
return BadRequest();
}
@ -118,7 +118,7 @@ namespace ScrumTaskboard.Controllers
await _context.SaveChangesAsync();
// The new task has been created and can be called up using the GetTask method
return CreatedAtAction("GetTask", new { id = task.id }, task);
return CreatedAtAction("GetTask", new { id = task.Id }, task);
}
// DELETE: api/tasks/5

View File

@ -58,7 +58,7 @@ namespace ScrumTaskboard.Controllers
public async Task<IActionResult> PutUser(int id, ScrumUser sprint)
{
// The user's ID must not be changed
if (id != sprint.id)
if (id != sprint.Id)
{
return BadRequest();
}
@ -95,7 +95,7 @@ namespace ScrumTaskboard.Controllers
await _context.SaveChangesAsync();
// The new user has been created and can be called up using the GetUser method
return CreatedAtAction("GetUser", new { id = sprint.id }, sprint);
return CreatedAtAction("GetUser", new { id = sprint.Id }, sprint);
}
// DELETE: api/User/5

View File

@ -85,7 +85,7 @@ namespace ScrumTaskboard.Controllers
public async Task<IActionResult> PutUserstory(int id, ScrumUserstory userstory)
{
// The userstory's ID must not be changed
if (id != userstory.id)
if (id != userstory.Id)
{
return BadRequest();
}
@ -122,7 +122,7 @@ namespace ScrumTaskboard.Controllers
await _context.SaveChangesAsync();
// The new userstory has been created and can be called up using the GetUserstory method
return CreatedAtAction("GetUserstory", new { id = userstory.id }, userstory);
return CreatedAtAction("GetUserstory", new { id = userstory.Id }, userstory);
}
// DELETE: api/userstories/1