public HttpStatusCode DeleteAttributeGroup(int attributeGroupId) { var response = _attributeGroupRepository.DeleteAttributeGroup(attributeGroupId); switch (response) { case HttpStatusCode.OK: return(HttpStatusCode.OK); case HttpStatusCode.InternalServerError: return(HttpStatusCode.InternalServerError); default: return(HttpStatusCode.NotFound); } }
public IActionResult DeleteAttributeGroup(int attrGroupId) { var deletedAttrGroup = _attrGroupRepo.DeleteAttributeGroup(attrGroupId); return(RedirectToAction(nameof(Index))); }