Adding attributes for Read methods
This commit is contained in:
@@ -23,7 +23,7 @@ namespace WD7UVN_HFT_2023241.Endpoint
|
||||
}
|
||||
|
||||
[HttpGet("{id}")]
|
||||
public Customer ReadCustomer(int id)
|
||||
public Customer ReadCustomer([FromQuery] int id)
|
||||
{
|
||||
return LogicServices.CRUDOperations.ReadCustomer(id);
|
||||
}
|
||||
|
||||
@@ -23,7 +23,7 @@ namespace WD7UVN_HFT_2023241.Endpoint
|
||||
}
|
||||
|
||||
[HttpGet("{id}")]
|
||||
public Employee ReadEmployee(int id)
|
||||
public Employee ReadEmployee([FromQuery] int id)
|
||||
{
|
||||
return LogicServices.CRUDOperations.ReadEmployee(id);
|
||||
}
|
||||
|
||||
@@ -23,7 +23,7 @@ namespace WD7UVN_HFT_2023241.Endpoint
|
||||
}
|
||||
|
||||
[HttpGet("{id}")]
|
||||
public MaintainerTeam ReadMaintainerTeam(int id)
|
||||
public MaintainerTeam ReadMaintainerTeam([FromQuery] int id)
|
||||
{
|
||||
return LogicServices.CRUDOperations.ReadMaintainerTeam(id);
|
||||
}
|
||||
|
||||
@@ -23,7 +23,7 @@ namespace WD7UVN_HFT_2023241.Endpoint
|
||||
}
|
||||
|
||||
[HttpGet("{id}")]
|
||||
public Service ReadService(int id)
|
||||
public Service ReadService([FromQuery] int id)
|
||||
{
|
||||
return LogicServices.CRUDOperations.ReadService(id);
|
||||
}
|
||||
|
||||
@@ -17,7 +17,7 @@ namespace WD7UVN_HFT_2023241.Endpoint
|
||||
}
|
||||
|
||||
[HttpGet("{id}")]
|
||||
public IQueryable<Employee> GetSubordinates(int id)
|
||||
public IQueryable<Employee> GetSubordinates([FromQuery] int id)
|
||||
{
|
||||
return LogicServices.GetSubordinates(id);
|
||||
}
|
||||
|
||||
@@ -17,7 +17,7 @@ namespace WD7UVN_HFT_2023241.Endpoint
|
||||
}
|
||||
|
||||
[HttpGet("{id}")]
|
||||
public IQueryable<Customer> WhoUsesService(int id)
|
||||
public IQueryable<Customer> WhoUsesService([FromQuery] int id)
|
||||
{
|
||||
return LogicServices.WhoUsesService(id);
|
||||
}
|
||||
|
||||
@@ -17,7 +17,7 @@ namespace WD7UVN_HFT_2023241.Endpoint
|
||||
}
|
||||
|
||||
[HttpGet("{id}")]
|
||||
public IQueryable<Employee> WhoWorksInMaintainerTeam(int id)
|
||||
public IQueryable<Employee> WhoWorksInMaintainerTeam([FromQuery] int id)
|
||||
{
|
||||
return LogicServices.WhoWorksInMaintainerTeam(id);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user