map的遍历
//针对于时间冲突的服务,按相近原则分配(从小到大排序)
Map<String, Double> distance1 = MapUtils.sortByValueAscending(distance);
for (Map.Entry<String, Double> entry : distance1.entrySet()) {
SvsService service = svsServiceRepository.findByIdAndStatus(entry.getKey(), "1");
service.setTeamId(owTeams.get(j).getId());
svsServiceRepository.save(service);
serviceList2.add(j,service);
}
entry.getKey():Map的K值
entry.getVaule():Map的V值