API módosítása
This commit is contained in:
@@ -43,6 +43,29 @@ namespace WorkFlowCheck.BL.Services
|
||||
|
||||
return retVal;
|
||||
}
|
||||
public async Task<CheckPointDTO> GetCheckPointAsync(int id)
|
||||
{
|
||||
var retVal = new CheckPointDTO();
|
||||
|
||||
try
|
||||
{
|
||||
var res = await _dbContext.CheckPoints
|
||||
.Include(i => i.CheckListTemplateRows)
|
||||
.Where(w => w.Id == id)
|
||||
.AsNoTracking()
|
||||
.FirstOrDefaultAsync();
|
||||
if (res != null)
|
||||
{
|
||||
retVal = _mapper.Map<CheckPointDTO>(res);
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Log.Error(ex.Message);
|
||||
}
|
||||
|
||||
return retVal;
|
||||
}
|
||||
public async Task<List<LocationDTO>> GetAllLocationAsync()
|
||||
{
|
||||
var retVal = new List<LocationDTO>();
|
||||
|
||||
Reference in New Issue
Block a user