This commit is contained in:
@@ -313,7 +313,7 @@ namespace AyaNova.Api.Controllers
|
|||||||
return StatusCode(403, new ApiNotAuthorizedResponse());
|
return StatusCode(403, new ApiNotAuthorizedResponse());
|
||||||
// if (!ModelState.IsValid)
|
// if (!ModelState.IsValid)
|
||||||
// return BadRequest(new ApiErrorResponse(ModelState));
|
// return BadRequest(new ApiErrorResponse(ModelState));
|
||||||
var o = await ct.Part.AsNoTracking().Select(x => x.UnitOfMeasure).Distinct().OrderBy(x => x).ToListAsync();
|
var o = await ct.Part.AsNoTracking().Select(x => x.UnitOfMeasure).Where(x => x != null).Distinct().OrderBy(x => x).ToListAsync();
|
||||||
if (o == null) return NotFound(new ApiErrorResponse(ApiErrorCode.NOT_FOUND));
|
if (o == null) return NotFound(new ApiErrorResponse(ApiErrorCode.NOT_FOUND));
|
||||||
return Ok(ApiOkResponse.Response(o));
|
return Ok(ApiOkResponse.Response(o));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -182,7 +182,7 @@ namespace AyaNova.Biz
|
|||||||
//
|
//
|
||||||
internal async Task<List<string>> GetPriorUnitsAsync()
|
internal async Task<List<string>> GetPriorUnitsAsync()
|
||||||
{
|
{
|
||||||
return await ct.ServiceRate.AsNoTracking().Select(x => x.Unit).Distinct().OrderBy(x => x).ToListAsync();
|
return await ct.ServiceRate.AsNoTracking().Select(x => x.Unit).Where(x => x != null).Distinct().OrderBy(x => x).ToListAsync();
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|||||||
@@ -182,7 +182,7 @@ namespace AyaNova.Biz
|
|||||||
//
|
//
|
||||||
internal async Task<List<string>> GetPriorUnitsAsync()
|
internal async Task<List<string>> GetPriorUnitsAsync()
|
||||||
{
|
{
|
||||||
return await ct.TravelRate.AsNoTracking().Select(x => x.Unit).Distinct().OrderBy(x => x).ToListAsync();
|
return await ct.TravelRate.AsNoTracking().Select(x => x.Unit).Where(x => x != null).Distinct().OrderBy(x => x).ToListAsync();
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|||||||
Reference in New Issue
Block a user