Subversion Repositories SmartDukaan

Rev

Rev 27259 | Rev 27261 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 27259 Rev 27260
Line 275... Line 275...
275
			List<AuthUser> authUsers = authRepository.selectAllAuthUserByIds(
275
			List<AuthUser> authUsers = authRepository.selectAllAuthUserByIds(
276
					positions.stream().map(x -> x.getAuthUserId()).collect(Collectors.toList()));
276
					positions.stream().map(x -> x.getAuthUserId()).collect(Collectors.toList()));
277
			authUsers = authUsers.stream().filter(x -> x.isActive()).collect(Collectors.toList());
277
			authUsers = authUsers.stream().filter(x -> x.isActive()).collect(Collectors.toList());
278
			if (authUsers.size() > 0) {
278
			if (authUsers.size() > 0) {
279
				Random rand = new Random();
279
				Random rand = new Random();
280
				authUserId = authUsers.get(rand.nextInt(authUsers.size())).getId();
280
				authUserId = authUsers.get(0).getId();
281
			}
281
			}
282
		}
282
		}
283
		return authUserId;
283
		return authUserId;
284
 
284
 
285
	}
285
	}