public ActionResult OnChangeState(int id) { var result = ProductTypeService.ChangeState(id); SetFlashMessage(result == Result.Ok ? "Thay đổi trạng thái Loại sản phẩm thành công." : "Loại sản phẩm không tồn tại trên hệ thống."); return(RedirectToAction("Index")); }