|
@@ -850,12 +850,13 @@ public class WorkerLogic {
|
|
|
List<String> policyIds = policyOrders.stream().map(PolicyOrder::getPolicyId).collect(Collectors.toList());
|
|
|
|
|
|
|
|
|
+ boolean notEmpty = CollectionUtil.isNotEmpty(policyOrderList);
|
|
|
+
|
|
|
Page<Policy> page = policyService.lambdaQuery()
|
|
|
.notIn(CollectionUtil.isEmpty(policyOrderList) && CollectionUtil.isNotEmpty(policyOrders), Policy::getId, policyIds)
|
|
|
- .ge(CollectionUtil.isNotEmpty(policyOrderList), Policy::getEndTime, policyOrderList.get(0).getEndTime())
|
|
|
.eq(Policy::getIsBuy, IsYesNoEnum.YES.getKey())
|
|
|
.le(Policy::getPolicyStartTime, new Date())
|
|
|
- .ge(Policy::getEndTime, new Date())
|
|
|
+ .ge(Policy::getEndTime, notEmpty?policyOrderList.get(0).getEndTime():new Date())
|
|
|
.in(Policy::getId, policyWebsits.stream().map(PolicyWebsit::getPolicyId).collect(Collectors.toList()))
|
|
|
.orderByAsc(Policy::getEndTime)
|
|
|
.page(new Page<>(pageNum, pageSize));
|