|
|
@@ -90,6 +90,8 @@ public class GLPPWXGQueryAddServiceImpl implements GLPPWXGQueryAddService {
|
|
|
InsureWorkerCommercialFileService insureWorkerCommercialFileService;
|
|
|
@Resource
|
|
|
OrderDetailFileService orderDetailFileService;
|
|
|
+ @Resource
|
|
|
+ OrderInstallDetailCodeService orderInstallDetailCodeService;
|
|
|
|
|
|
|
|
|
@Override
|
|
|
@@ -491,6 +493,32 @@ public class GLPPWXGQueryAddServiceImpl implements GLPPWXGQueryAddService {
|
|
|
updateMXFile(odfilesUpList, 0);
|
|
|
}
|
|
|
|
|
|
+ @Override
|
|
|
+ public void extractedTMSYFile(){
|
|
|
+ List<OrderInstallDetailCode> odfiles = new ArrayList<>();
|
|
|
+ List<OrderInstallDetailCode> odfilesUpList = new ArrayList<>();
|
|
|
+
|
|
|
+ odfiles = orderInstallDetailCodeService.lambdaQuery()
|
|
|
+ .eq(OrderInstallDetailCode::getOutZjljProcess,0)
|
|
|
+ .isNotNull(OrderInstallDetailCode::getOutPicture).list();
|
|
|
+
|
|
|
+ for (OrderInstallDetailCode item :odfiles){
|
|
|
+ try{
|
|
|
+ // 生成图片
|
|
|
+ processSYTMFileInfo(item);
|
|
|
+ odfilesUpList.add(item);
|
|
|
+
|
|
|
+ updateSYTMFile(odfilesUpList, 10);
|
|
|
+ } catch (Exception ex) {
|
|
|
+ ex.printStackTrace();
|
|
|
+ updateSYTMFile(odfilesUpList, 0);
|
|
|
+ log.info("生成商户到平台采集条码图信息失败order_install_detail_code.id= {}",item.getId());
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ updateSYTMFile(odfilesUpList, 0);
|
|
|
+ }
|
|
|
+
|
|
|
|
|
|
private void updateWorkerCertInfo(List<WorkerCert> workerCertUpList, int i) {
|
|
|
if (workerCertUpList.size() > i) {
|
|
|
@@ -520,6 +548,13 @@ public class GLPPWXGQueryAddServiceImpl implements GLPPWXGQueryAddService {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ private void updateSYTMFile(List<OrderInstallDetailCode> iwcfilesUpList, int i) {
|
|
|
+ if (iwcfilesUpList.size() > i) {
|
|
|
+ orderInstallDetailCodeService.updateBatchById(iwcfilesUpList);
|
|
|
+ iwcfilesUpList.clear();
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
private void upWebsitWorker(List<WebsitWorker> websitWorkerUp) {
|
|
|
if (websitWorkerUp.size()>0){
|
|
|
websitWorkerService.saveOrUpdateBatch(websitWorkerUp);
|
|
|
@@ -1191,6 +1226,22 @@ public class GLPPWXGQueryAddServiceImpl implements GLPPWXGQueryAddService {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ private void processSYTMFileInfo(OrderInstallDetailCode iwcfile) throws IOException {
|
|
|
+ if (StringUtils.isNotEmpty(iwcfile.getOutPicture())){
|
|
|
+ String id = putCert(iwcfile.getOutPicture());
|
|
|
+ if (StringUtils.isNotEmpty(id)){
|
|
|
+ iwcfile.setPath(id);
|
|
|
+ iwcfile.setGreeImageId(iwcfile.getOutPicture());
|
|
|
+ iwcfile.setOutZjljProcess(1);
|
|
|
+ iwcfile.setCreateTime(new Date());
|
|
|
+ new File(id).delete();
|
|
|
+ }
|
|
|
+
|
|
|
+ } else {
|
|
|
+ iwcfile.setOutZjljProcess(1);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
private void setAdd(WangdianWxgVos wvos, String workerId, String workerName, ZJInfo zj, WorkerCert add) throws ParseException {
|
|
|
add.setId(publicService.getUUID());
|
|
|
add.setWorkerId(workerId);
|