Commit 6f9443f5 by huangZW

111

parent 68820e56
......@@ -132,7 +132,16 @@ public class StoreController extends WebBaseController{
}
}
if(CollectionUtils.isNotEmpty(resultList)){
resultList = resultList.stream().sorted(Comparator.comparing(StoreVO::getBindFlag).thenComparing(StoreVO::getCreateTime)).collect(Collectors.toList());
Map<Integer,StoreVO> map = com.gic.commons.util.CollectionUtil.toMap(resultList, "clerkType");
if(map.containsKey(1)){
//店长
resultList = resultList.stream().sorted(Comparator.comparing(StoreVO::getBindFlag).thenComparing(StoreVO::getClerkType).reversed().thenComparing(StoreVO::getCreateTime).reversed()).collect(Collectors.toList());
}else{
//店员
resultList = resultList.stream().sorted(Comparator.comparing(StoreVO::getBindFlag).thenComparing(StoreVO::getCreateTime)).collect(Collectors.toList());
}
}
return resultResponse(HaoBanErrCode.ERR_1,resultList);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment