/// <summary> /// 更新数据 /// </summary> /// <param name="entity">欲更新的实体数据</param> /// <returns>更新结果</returns> public JsonResult Update(Persons entity) { OperateStatus status; personsModel.Update(entity, out status); return JsonForStatus(status); }
/// <summary> /// 删除数据 /// </summary> /// <param name="entity">欲删除的实体数据</param> /// <returns>删除结果</returns> public JsonResult Delete(Persons entity) { OperateStatus status; personsModel.Delete(entity.Id, out status); return JsonForStatus(status); }