|
@@ -129,10 +129,6 @@ public class UploadWorkerTOGreeServiceImpl implements UploadWorkerTOGreeService
|
|
|
WorkUploadInfo req = new WorkUploadInfo();
|
|
|
WorkerCertificateInfo workerCertificateInfo = new WorkerCertificateInfo();
|
|
|
|
|
|
- // 看要同步的师傅的证件上否已全部更新 只有全部更新才可以执行
|
|
|
- if (checkWaitCert(item)){
|
|
|
- continue;
|
|
|
- }
|
|
|
|
|
|
// 获取师傅信息 需要同步的师傅必须在平台系统中存在
|
|
|
if (!workersMap.containsKey(item.getWorkerId())){
|
|
@@ -169,6 +165,11 @@ public class UploadWorkerTOGreeServiceImpl implements UploadWorkerTOGreeService
|
|
|
// 按网点同步
|
|
|
for (WorkerBrandAccount dot: workerBrandAccount){
|
|
|
|
|
|
+ // 看要同步的师傅的证件上否已更新到总部 只有更新到总部才可以执行
|
|
|
+ if (checkWaitCert(item, dot)){
|
|
|
+ continue;
|
|
|
+ }
|
|
|
+
|
|
|
// 必填参数 省份-城市-区县-乡镇 找一个即可
|
|
|
if (getaddres(item, req, dot)) {
|
|
|
continue;
|
|
@@ -273,11 +274,11 @@ public class UploadWorkerTOGreeServiceImpl implements UploadWorkerTOGreeService
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- private boolean checkWaitCert(OutWorkerUpload item) {
|
|
|
+ private boolean checkWaitCert(OutWorkerUpload item, WorkerBrandAccount dot) {
|
|
|
//先看保险
|
|
|
WebsitWorker wws = websitWorkerService.lambdaQuery()
|
|
|
.eq(WebsitWorker::getWorkerId, item.getWorkerId())
|
|
|
- .eq(WebsitWorker::getWebsitId, item.getWebsitId()).one();
|
|
|
+ .eq(WebsitWorker::getWebsitId, dot.getWebsitId()).one();
|
|
|
// 若未更新保险不同步
|
|
|
if (wws != null) {
|
|
|
if (StringUtils.isEmpty(wws.getOutInsureCert())){
|
|
@@ -2083,7 +2084,7 @@ public class UploadWorkerTOGreeServiceImpl implements UploadWorkerTOGreeService
|
|
|
private List<OutWorkerUpload> getWorkerUploadstest() {
|
|
|
// 同步标志-synStatus(0:待同步;1:已同步;99:同步失败)
|
|
|
List<OutWorkerUpload> recs = outWorkerUploadService.lambdaQuery()
|
|
|
- .eq(OutWorkerUpload::getSynReqId,46).list();
|
|
|
+ .eq(OutWorkerUpload::getSynReqId,7).list();
|
|
|
return recs;
|
|
|
}
|
|
|
}
|