public void Delete(int idDriver) { UserAccess userAccess = getItem(idDriver); list.Remove(userAccess); userAccess.Delete(); }
/// <summary> /// 逻辑删除 /// </summary> /// <param name="id"></param> /// <returns></returns> public static int Delete(int id) { var currt = OperatorProvider.Instance.Current; var model = new Sys_User { Id = id, SUModifyTime = DateTime.Now, SUModifyUser = currt.UserId, SUIsEnabled = 0, SUDeleteMark = 1 }; return(UserAccess.Delete(model)); }
/// <summary> /// 删除用户,返回信息 /// </summary> /// <returns>0:失败,1:成功,2:不能删除当前登录用户</returns> public int DeleteUser(UserInfo user) { if (user.UserId == UserContext.CurrentUser.UserId) { return(-1); } if (ua.Delete(user)) { return(1); } else { return(0); } }
public int Delete(int id) { return(userAccess.Delete(id)); }
public bool Delete(int id) { return(dataAccess.Delete(id)); }