修复数据突然查询不到的bug
This commit is contained in:
parent
a367f19002
commit
e7884bd855
|
@ -149,11 +149,8 @@ public class RouteCacheService {
|
|||
// Fetch, invalidate, and update the cache in an optimized manner if possible
|
||||
List<Long> routeIds = routeCacheManage.getRouteIdsByEmployeeNo(userId, null, null);
|
||||
if (routeIds == null || routeIds.size() <= 2) {
|
||||
preloadUserRoutes(userId);
|
||||
routeIds = routeCacheManage.getRouteIdsByEmployeeNo(userId, null, null);
|
||||
if (routeIds == null) {
|
||||
routeIds = new ArrayList<>();
|
||||
}
|
||||
List<RouteOrder> routeOrders = preloadUserRoutes(userId);
|
||||
routeIds = routeOrders.stream().map(RouteOrder::getRouteId).toList();
|
||||
}
|
||||
if (!routeIds.contains(routeId)) {
|
||||
List<Long> newRouteIds = new ArrayList<>(routeIds);
|
||||
|
|
Loading…
Reference in New Issue