public IActionResult DeleteColor(DeleteColorModel deleteModel) { try { if (ModelState.IsValid) { bool isDeleted = iColor.DeleteColor(DBHelper.ParseInt64(deleteModel.colorId)); if (isDeleted) { return(Ok(ResponseHelper.Success(MessageConstants.ColorDeleted))); } else { return(Ok(ResponseHelper.Error(MessageConstants.DataNotFound))); } } else { return(Ok(ResponseHelper.Error(MessageConstants.CompulsoryData))); } } catch (Exception ex) { LogHelper.ExceptionLog(ex.Message + " ::::: " + ex.StackTrace); return(Ok(ResponseHelper.Error(ex.Message))); } }