public async Task <ActionResult <bool> > DeleteProductOption(Guid id, Guid optionId) { try { var productOption = await _productOptionsService.GetProductOption(id, optionId); if (productOption == null) { return(NotFound()); } var result = await _productOptionsService.DeleteProductOption(id, optionId); return(Ok(result)); } catch (Exception ex) { _logger.LogError(ex.Message); return(StatusCode(500, new ApiResponse { Result = 1, Message = ex.Message })); } }
public void DeleteOption(Guid Id) { _productOptionsService.DeleteProductOption(Id); }