This commit is contained in:
@@ -313,7 +313,7 @@ namespace AyaNova.Api.Controllers
|
||||
return StatusCode(403, new ApiNotAuthorizedResponse());
|
||||
// if (!ModelState.IsValid)
|
||||
// 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));
|
||||
return Ok(ApiOkResponse.Response(o));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user