|
@@ -11,16 +11,11 @@ import com.gree.mall.manager.bean.es.*;
|
|
import com.gree.mall.manager.bean.listvo.param.WorkOrderZfireParam;
|
|
import com.gree.mall.manager.bean.listvo.param.WorkOrderZfireParam;
|
|
import com.gree.mall.manager.bean.listvo.workorder.OrderBaseVO;
|
|
import com.gree.mall.manager.bean.listvo.workorder.OrderBaseVO;
|
|
import com.gree.mall.manager.enums.MaterialExamineStatusEnum;
|
|
import com.gree.mall.manager.enums.MaterialExamineStatusEnum;
|
|
-import com.gree.mall.manager.es.OrderBaseEsRepository;
|
|
|
|
-import com.gree.mall.manager.es.OrderWorkerEsRepository;
|
|
|
|
-import com.gree.mall.manager.es.SettlementOrderEsRepository;
|
|
|
|
|
|
+import com.gree.mall.manager.es.*;
|
|
import com.gree.mall.manager.exception.RemoteServiceException;
|
|
import com.gree.mall.manager.exception.RemoteServiceException;
|
|
import com.gree.mall.manager.logic.common.CommonLogic;
|
|
import com.gree.mall.manager.logic.common.CommonLogic;
|
|
import com.gree.mall.manager.plus.entity.*;
|
|
import com.gree.mall.manager.plus.entity.*;
|
|
-import com.gree.mall.manager.plus.service.PgOrderBaseService;
|
|
|
|
-import com.gree.mall.manager.plus.service.PgOrderWorkerService;
|
|
|
|
-import com.gree.mall.manager.plus.service.SettlementOrderService;
|
|
|
|
-import com.gree.mall.manager.plus.service.WorkerOrderService;
|
|
|
|
|
|
+import com.gree.mall.manager.plus.service.*;
|
|
import com.gree.mall.manager.utils.CommonUtils;
|
|
import com.gree.mall.manager.utils.CommonUtils;
|
|
import com.gree.mall.manager.utils.StringUtil;
|
|
import com.gree.mall.manager.utils.StringUtil;
|
|
import com.gree.mall.manager.zfire.bean.QueryParamBean;
|
|
import com.gree.mall.manager.zfire.bean.QueryParamBean;
|
|
@@ -69,7 +64,13 @@ public class OrderBaseEsLogic {
|
|
|
|
|
|
private final CommonLogic commonLogic;
|
|
private final CommonLogic commonLogic;
|
|
private final OrderBaseEsRepository orderBaseEsRepository;
|
|
private final OrderBaseEsRepository orderBaseEsRepository;
|
|
|
|
+ private final OrderBase2022EsRepository orderBase2022EsRepository;
|
|
|
|
+ private final OrderBase2023EsRepository orderBase2023EsRepository;
|
|
|
|
+ private final OrderBase2024EsRepository orderBase2024EsRepository;
|
|
private final PgOrderBaseService pgOrderBaseService;
|
|
private final PgOrderBaseService pgOrderBaseService;
|
|
|
|
+ private final PgOrderBase2022Service pgOrderBase2022Service;
|
|
|
|
+ private final PgOrderBase2023Service pgOrderBase2023Service;
|
|
|
|
+ private final PgOrderBase2024Service pgOrderBase2024Service;
|
|
private final SettlementOrderService settlementOrderService;
|
|
private final SettlementOrderService settlementOrderService;
|
|
private final SettlementOrderEsRepository settlementOrderEsRepository;
|
|
private final SettlementOrderEsRepository settlementOrderEsRepository;
|
|
private final OrderWorkerEsRepository orderWorkerEsRepository;
|
|
private final OrderWorkerEsRepository orderWorkerEsRepository;
|
|
@@ -721,6 +722,32 @@ public class OrderBaseEsLogic {
|
|
|
|
|
|
|
|
|
|
orderBaseEsRepository.saveAll(orderBaseEsDates);
|
|
orderBaseEsRepository.saveAll(orderBaseEsDates);
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+ List<PgOrderBase2022> list2022 = pgOrderBase2022Service.lambdaQuery()
|
|
|
|
+ .gt(PgOrderBase2022::getUpdateTime,DateUtil.offsetMinute(new Date(),-5))
|
|
|
|
+ .list();
|
|
|
|
+
|
|
|
|
+ List<OrderBaseEs2022Date> orderBaseEsDates2022 = BeanUtil.copyToList(list2022, OrderBaseEs2022Date.class);
|
|
|
|
+
|
|
|
|
+ orderBase2022EsRepository.saveAll(orderBaseEsDates2022);
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+ List<PgOrderBase2023> list2023 = pgOrderBase2023Service.lambdaQuery()
|
|
|
|
+ .gt(PgOrderBase2023::getUpdateTime,DateUtil.offsetMinute(new Date(),-5))
|
|
|
|
+ .list();
|
|
|
|
+
|
|
|
|
+ List<OrderBaseEs2023Date> orderBaseEsDates2023 = BeanUtil.copyToList(list2023, OrderBaseEs2023Date.class);
|
|
|
|
+
|
|
|
|
+ orderBase2023EsRepository.saveAll(orderBaseEsDates2023);
|
|
|
|
+
|
|
|
|
+ List<PgOrderBase2024> list2024 = pgOrderBase2024Service.lambdaQuery()
|
|
|
|
+ .gt(PgOrderBase2024::getUpdateTime,DateUtil.offsetMinute(new Date(),-5))
|
|
|
|
+ .list();
|
|
|
|
+
|
|
|
|
+ List<OrderBaseEs2024Date> orderBaseEsDates2024 = BeanUtil.copyToList(list2024, OrderBaseEs2024Date.class);
|
|
|
|
+
|
|
|
|
+ orderBase2024EsRepository.saveAll(orderBaseEsDates2024);
|
|
}
|
|
}
|
|
|
|
|
|
public void esSync1() {
|
|
public void esSync1() {
|