public static List<UserVO> listUsersByAccount(long accountId) { return s_userDao.listByAccount(accountId); }
final List<UserVO> usersInAccount = _userDao.listByAccount(account.getId());
private boolean updateUserAccount(final Account account, final Domain domain, final CloudianUser existingUser) { if (account == null || domain == null || !isEnabled()) { return false; } final CloudianClient client = getClient(); if (existingUser != null) { final User accountUser = userDao.listByAccount(account.getId()).get(0); final String fullName = String.format("%s %s (%s)", accountUser.getFirstname(), accountUser.getLastname(), account.getAccountName()); if (!existingUser.getActive() || !existingUser.getFullName().equals(fullName) || !existingUser.getEmailAddr().equals(accountUser.getEmail())) { existingUser.setActive(true); existingUser.setFullName(fullName); existingUser.setEmailAddr(accountUser.getEmail()); return client.updateUser(existingUser); } return true; } return false; }
List<UserVO> userVOs = _userDao.listByAccount(owner.getAccountId()); if (!userVOs.isEmpty()) { userId = userVOs.get(0).getId();
private boolean addUserAccount(final Account account, final Domain domain) { if (account == null || domain == null || !isEnabled()) { return false; } final User accountUser = userDao.listByAccount(account.getId()).get(0); final CloudianClient client = getClient(); final String fullName = String.format("%s %s (%s)", accountUser.getFirstname(), accountUser.getLastname(), account.getAccountName()); final CloudianUser user = new CloudianUser(); user.setUserId(account.getUuid()); user.setGroupId(domain.getUuid()); user.setFullName(fullName); user.setEmailAddr(accountUser.getEmail()); user.setUserType(CloudianUser.USER); user.setActive(true); return client.addUser(user); }
List<UserVO> users = _userDao.listByAccount(accountId); for (UserVO user : users) { if (!_userDao.remove(user.getId())) {
final List<UserVO> userVOs = _userDao.listByAccount(owner.getAccountId()); if (!userVOs.isEmpty()) { userId = userVOs.get(0).getId();
List<UserVO> userVOs = _userDao.listByAccount(owner.getAccountId()); if (!userVOs.isEmpty()) { userId = userVOs.get(0).getId();
List<UserVO> userVOs = _userDao.listByAccount(owner.getAccountId()); if (!userVOs.isEmpty()) { userId = userVOs.get(0).getId();
List<UserVO> allUsersByAccount = _userDao.listByAccount(user.getAccountId()); for (UserVO oneUser : allUsersByAccount) { if (oneUser.getState().equals(State.enabled)) {
List<UserVO> userVOs = _userDao.listByAccount(owner.getAccountId()); if (!userVOs.isEmpty()) { userId = userVOs.get(0).getId();