public int getTotalRecords(UserCriteria conditions) { SqlConnectionFactory sqlConnection = new SqlConnectionFactory(); using (SqlConnection connection = sqlConnection.GetConnection()) { return(UsersDataLayer.GetInstance().GetTotalRecords(connection, conditions)); } }
public void TrackUserAction(UserLogInfo userLoginfo) { SqlConnectionFactory sqlConnection = new SqlConnectionFactory(); using (SqlConnection connection = sqlConnection.GetConnection()) { UsersDataLayer.GetInstance().TrackingUserBehavior(connection, userLoginfo); } }
public List <UserInfo> GetList(UserCriteria conditions) { SqlConnectionFactory sqlConnection = new SqlConnectionFactory(); using (SqlConnection connection = sqlConnection.GetConnection()) { List <UserInfo> ListUserInfo = UsersDataLayer.GetInstance().Getlist(connection, conditions); return(ListUserInfo); } }
public void UpdateUserGroup(string id, UserGroupInfo _userGroup) { SqlConnectionFactory sqlConnection = new SqlConnectionFactory(); UserInfo record = new UserInfo(); using (SqlConnection connection = sqlConnection.GetConnection()) { UserInfo data = UsersDataLayer.GetInstance().GetUser(connection, id); UserGroupDataLayer.GetInstance().UpdateUserGroup(connection, id, _userGroup); } }
public void ChangePassword(string _user, string pass) { SqlConnectionFactory sqlConnection = new SqlConnectionFactory(); UserInfo record = new UserInfo(); using (SqlConnection connection = sqlConnection.GetConnection()) { string applicationId = EncryptionUtils.GetApplicationId(); string applicationName = EncryptionUtils.GetApplicationName(); String password = EncryptionUtils.EncryptData(pass, applicationName, applicationId); UsersDataLayer.GetInstance().ChangePass(connection, _user, password); } }
public void DeleteUsers(string ids) { SqlConnectionFactory sqlConnection = new SqlConnectionFactory(); using (SqlConnection connection = sqlConnection.GetConnection()) { string[] IDsarray = ids.Split(','); foreach (string id in IDsarray) { UsersDataLayer.GetInstance().DeleteUser(connection, id); } } }