public async Task <IActionResult> AddNewBatch([FromBody] BatchNew newBatch) { _batchService.AddNewBatch(newBatch); var result = await _unitOfWork.SaveAsync(); if (result > 0) { return(Ok(result)); } return(StatusCode(500, "Unable to add new batch.")); }