public ActionResult Disable(ProductTypeModel[] model) { foreach (var item in model) { var type = _productTypeService.Find(item.Id); _productTypeService.Disable(type); } return(AjaxForm().ReloadPage()); }
public virtual IHttpActionResult Disable(ProductTypeDisableRequest request) { var entity = new ProductType { Id = request.Id, }; var result = _productTypeService.Disable(request.Id); if (result > 0) { return(Succeed("禁用成功")); } else { return(Fail("禁用失败")); } }