|
@@ -8,6 +8,7 @@ import io.swagger.annotations.Api;
|
|
|
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
import org.apache.commons.codec.digest.DigestUtils;
|
|
|
+import org.apache.commons.lang.StringUtils;
|
|
|
import org.springblade.archive.dto.*;
|
|
|
|
|
|
import org.springblade.archive.entity.ArchiveJiLinPush;
|
|
@@ -68,40 +69,40 @@ public class JinLinPushApiController {
|
|
|
|
|
|
@GetMapping("/test")
|
|
|
public void JinlinApiPush() throws JsonProcessingException {
|
|
|
- //获取发送get请求的校验码
|
|
|
- String query = "clientSecretKey="+PYCLIENTSECRETKEY;
|
|
|
- String querySignature = DigestUtils.md5Hex(query).toUpperCase();
|
|
|
- // 获取吉林项目合同段的地址
|
|
|
- String queryUrl = "https://hgqs.jtyst.jl.gov.cn:6100/dock/openapi/hqsws/hqsprojpact/query";
|
|
|
- HashMap<String,String> queryHeaders=new HashMap<>();
|
|
|
- queryHeaders.put("Content-Type", "application/json");
|
|
|
- queryHeaders.put("clientId",PYCLIENTID);
|
|
|
- queryHeaders.put("signature",querySignature);
|
|
|
- queryHeaders.put("systemId",PYSYSTEMID);
|
|
|
- String queryBody = HttpUtil.createGet(queryUrl).addHeaders(queryHeaders).execute().body();
|
|
|
- JSONObject jsonObject=JSONObject.parseObject(queryBody);
|
|
|
- //吉林蒲烟项目合同段信息
|
|
|
- List<PactAndProjDto> pactAndProjDtoList = JSONObject.parseArray(jsonObject.getString("data").toString(),PactAndProjDto.class);
|
|
|
-
|
|
|
- //重庆吉林蒲烟项目合同段信息(中间表)
|
|
|
- List<ArchiveJiLinPush>archiveJiLinPushList= iArchiveJiLinPushService.getArchiveJiLinPush(jlPyProjId);
|
|
|
-
|
|
|
- //中间项目合同中间集合
|
|
|
- List<JiLinQueryDto>dtos=new ArrayList<>();
|
|
|
- for (PactAndProjDto pactAndProjDto : pactAndProjDtoList) {
|
|
|
- for (ArchiveJiLinPush archiveJiLinPush : archiveJiLinPushList) {
|
|
|
- //吉林的合同段Id等于中间表吉林的合同段Id
|
|
|
- if(pactAndProjDto.getPactId().equals(archiveJiLinPush.getJlPactId())){
|
|
|
- //筛选出两边共同有的项目合同段 并设置好两边的项目ID 和合同段ID
|
|
|
- JiLinQueryDto jiLinQueryDto=new JiLinQueryDto();
|
|
|
- jiLinQueryDto.setCqContractId(archiveJiLinPush.getCqContractId());
|
|
|
- jiLinQueryDto.setCqProjectId(archiveJiLinPush.getCqProjectId());
|
|
|
- jiLinQueryDto.setJlProjectId(archiveJiLinPush.getJlProjectId());
|
|
|
- jiLinQueryDto.setJlPactId(archiveJiLinPush.getJlPactId());
|
|
|
- dtos.add(jiLinQueryDto);
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
+// //获取发送get请求的校验码
|
|
|
+// String query = "clientSecretKey="+HJCLIENTSECRETKEY;
|
|
|
+// String querySignature = DigestUtils.md5Hex(query).toUpperCase();
|
|
|
+// // 获取吉林项目合同段的地址
|
|
|
+// String queryUrl = "https://hgqs.jtyst.jl.gov.cn:6100/dock/openapi/hqsws/hqsprojpact/query";
|
|
|
+// HashMap<String,String> queryHeaders=new HashMap<>();
|
|
|
+// queryHeaders.put("Content-Type", "application/json");
|
|
|
+// queryHeaders.put("clientId",HJCLIENTID);
|
|
|
+// queryHeaders.put("signature",querySignature);
|
|
|
+// queryHeaders.put("systemId",HJSYSTEMID);
|
|
|
+// String queryBody = HttpUtil.createGet(queryUrl).addHeaders(queryHeaders).execute().body();
|
|
|
+// JSONObject jsonObject=JSONObject.parseObject(queryBody);
|
|
|
+// //吉林蒲烟项目合同段信息
|
|
|
+// List<PactAndProjDto> pactAndProjDtoList = JSONObject.parseArray(jsonObject.getString("data").toString(),PactAndProjDto.class);
|
|
|
+//
|
|
|
+// //重庆吉林蒲烟项目合同段信息(中间表)
|
|
|
+// List<ArchiveJiLinPush>archiveJiLinPushList= iArchiveJiLinPushService.getArchiveJiLinPush(jlHjProjId);
|
|
|
+//
|
|
|
+// //中间项目合同中间集合
|
|
|
+// List<JiLinQueryDto>dtos=new ArrayList<>();
|
|
|
+// for (PactAndProjDto pactAndProjDto : pactAndProjDtoList) {
|
|
|
+// for (ArchiveJiLinPush archiveJiLinPush : archiveJiLinPushList) {
|
|
|
+// //吉林的合同段Id等于中间表吉林的合同段Id
|
|
|
+// if(pactAndProjDto.getPactId().equals(archiveJiLinPush.getJlPactId())){
|
|
|
+// //筛选出两边共同有的项目合同段 并设置好两边的项目ID 和合同段ID
|
|
|
+// JiLinQueryDto jiLinQueryDto=new JiLinQueryDto();
|
|
|
+// jiLinQueryDto.setCqContractId(archiveJiLinPush.getCqContractId());
|
|
|
+// jiLinQueryDto.setCqProjectId(archiveJiLinPush.getCqProjectId());
|
|
|
+// jiLinQueryDto.setJlProjectId(archiveJiLinPush.getJlProjectId());
|
|
|
+// jiLinQueryDto.setJlPactId(archiveJiLinPush.getJlPactId());
|
|
|
+// dtos.add(jiLinQueryDto);
|
|
|
+// }
|
|
|
+// }
|
|
|
+// }
|
|
|
// //传入重庆的项目ID,和吉林需要的合同段集合 查出重庆的目录树
|
|
|
// Long projectId=cqHjProjectId;
|
|
|
// List<ArchiveTreeContractDTO> archiveTreeContractDtos = archiveTreeContractClient.getArchiveTreeContractDto(dtos,projectId);
|
|
@@ -148,129 +149,130 @@ public class JinLinPushApiController {
|
|
|
// System.out.println(tree);
|
|
|
// System.out.println(treeBody);
|
|
|
|
|
|
- //根据项目ID,合同段ID 查询出所有符合的档案数据
|
|
|
- List<JiLinArchiveAutoDto>archiveAutoDtos=iArchivesAutoService.getArchiveAutoDtoList(cqPyProjectId,dtos);
|
|
|
+// //根据项目ID,合同段ID 查询出所有符合的档案数据
|
|
|
+// List<JiLinArchiveAutoDto>archiveAutoDtos=iArchivesAutoService.getArchiveAutoDtoList(cqHjProjectId,dtos);
|
|
|
+//
|
|
|
+// //双重循环查出来的档案 将我们的项目 合同ID 设置为吉林的
|
|
|
+// for (JiLinArchiveAutoDto archiveAutoDto : archiveAutoDtos) {
|
|
|
+// Long id = SnowFlakeUtil.getId();
|
|
|
+// Long id1 = SnowFlakeUtil.getId();
|
|
|
+// archiveAutoDto.setProjectId(jlHjProjId);
|
|
|
+// archiveAutoDto.setTomeId(id);
|
|
|
+// archiveAutoDto.setCatlogId(id1);
|
|
|
+// for (ArchiveJiLinPush archiveJiLinPush : archiveJiLinPushList) {
|
|
|
+// if (archiveAutoDto.getContractId() != null && archiveAutoDto.getContractId().equals(archiveJiLinPush.getCqContractId())) {
|
|
|
+// archiveAutoDto.setContractId(archiveJiLinPush.getJlPactId());
|
|
|
+// }
|
|
|
+// }
|
|
|
+// }
|
|
|
+// System.out.println("档案:"+archiveAutoDtos.size());
|
|
|
+// iJiLinArchiveAutoDtoService.saveBatch(archiveAutoDtos);
|
|
|
|
|
|
- //双重循环查出来的档案 将我们的项目 合同ID 设置为吉林的
|
|
|
- for (JiLinArchiveAutoDto archiveAutoDto : archiveAutoDtos) {
|
|
|
- Long id = SnowFlakeUtil.getId();
|
|
|
- Long id1 = SnowFlakeUtil.getId();
|
|
|
- archiveAutoDto.setProjectId(jlPyProjId);
|
|
|
- archiveAutoDto.setTomeId(id);
|
|
|
- archiveAutoDto.setCatlogId(id1);
|
|
|
- for (ArchiveJiLinPush archiveJiLinPush : archiveJiLinPushList) {
|
|
|
- if (archiveAutoDto.getContractId() != null && archiveAutoDto.getContractId().equals(archiveJiLinPush.getCqContractId())) {
|
|
|
- archiveAutoDto.setContractId(archiveJiLinPush.getJlPactId());
|
|
|
- }
|
|
|
+ Long projId=jlPyProjId;
|
|
|
+ for (int j = 46; j <47 ; j++) {
|
|
|
+ Page<JiLinArchiveAutoDto> pages=iJiLinArchiveAutoDtoService.queryAll(j,500,projId);
|
|
|
+ List<JiLinArchiveAutoDto> archiveAutoDtos = pages.getRecords();
|
|
|
+ if(archiveAutoDtos.size()<500) {
|
|
|
+ System.out.println("最后一次数据大小:"+archiveAutoDtos.size());
|
|
|
+ j=101;
|
|
|
}
|
|
|
- }
|
|
|
- System.out.println("档案:"+archiveAutoDtos.size());
|
|
|
- iJiLinArchiveAutoDtoService.saveBatch(archiveAutoDtos);
|
|
|
+ List<JiLinPushTomeDto> jiLinPushTomeDtoList = new ArrayList<>();
|
|
|
+ List<JiLinPushCatalogDto> jiLinPushCatalogDtoList = new ArrayList<>();
|
|
|
+ List<JiLinPushFileUrlDto> jiLinPushFileUrlDtoList = new ArrayList<>();
|
|
|
+ for (int i = 0; i < archiveAutoDtos.size(); i++) {
|
|
|
+ //设置档案案卷
|
|
|
+ JiLinPushTomeDto jiLinPushTomeDto = new JiLinPushTomeDto();
|
|
|
+ jiLinPushTomeDto.setPactId(jlPyProjId);
|
|
|
+ jiLinPushTomeDto.setPactId(archiveAutoDtos.get(i).getContractId());
|
|
|
+ jiLinPushTomeDto.setKid(archiveAutoDtos.get(i).getTomeId());
|
|
|
+ jiLinPushTomeDto.setSortID(archiveAutoDtos.get(i).getNodeId());
|
|
|
+ jiLinPushTomeDto.setTomeSuper(StringUtils.deleteWhitespace(archiveAutoDtos.get(i).getName()));
|
|
|
+ jiLinPushTomeDto.setRecordNum(archiveAutoDtos.get(i).getFileNumber());
|
|
|
+ jiLinPushTomeDto.setAddUserName(archiveAutoDtos.get(i).getUpdateUserName());
|
|
|
+ jiLinPushTomeDto.setAddTime(archiveAutoDtos.get(i).getCreateUserTime());
|
|
|
+ jiLinPushTomeDto.setBWeaveDate(archiveAutoDtos.get(i).getStartDate());
|
|
|
+ jiLinPushTomeDto.setEWeaveDate(archiveAutoDtos.get(i).getEndDate());
|
|
|
+ jiLinPushTomeDto.setKeepTerm(archiveAutoDtos.get(i).getStorageTime());
|
|
|
+ jiLinPushTomeDto.setSortOrder(i);
|
|
|
+ jiLinPushTomeDto.setMutualNum("0");
|
|
|
+ jiLinPushTomeDto.setWeaveUnit(archiveAutoDtos.get(i).getUnit());
|
|
|
+ jiLinPushTomeDto.setSecrecy(archiveAutoDtos.get(i).getSecretLevel());
|
|
|
+ jiLinPushTomeDto.setYear(Integer.parseInt(archiveAutoDtos.get(i).getStorageTime()));
|
|
|
+ jiLinPushTomeDtoList.add(jiLinPushTomeDto);
|
|
|
+ // 设置档案卷内目录
|
|
|
+ JiLinPushCatalogDto jiLinPushCatalogDto = new JiLinPushCatalogDto();
|
|
|
+ jiLinPushCatalogDto.setProjId(jlPyProjId);
|
|
|
+ jiLinPushCatalogDto.setPactId(archiveAutoDtos.get(i).getContractId());
|
|
|
+ jiLinPushCatalogDto.setKid(archiveAutoDtos.get(i).getCatlogId());
|
|
|
+ jiLinPushCatalogDto.setSortId(archiveAutoDtos.get(i).getNodeId());
|
|
|
+ jiLinPushCatalogDto.setTomeId(archiveAutoDtos.get(i).getTomeId());
|
|
|
+ jiLinPushCatalogDto.setFileSuper(StringUtils.deleteWhitespace(archiveAutoDtos.get(i).getName()));
|
|
|
+ jiLinPushCatalogDto.setCatalogRecord(archiveAutoDtos.get(i).getFileNumber());
|
|
|
+ jiLinPushCatalogDto.setAmsFileNum("0");
|
|
|
+ jiLinPushCatalogDto.setFileNum("0");
|
|
|
+ jiLinPushCatalogDto.setWeaveDate(archiveAutoDtos.get(i).getCreateUserTime());
|
|
|
+ jiLinPushCatalogDto.setPieceCount(archiveAutoDtos.get(i).getFileN());
|
|
|
+ jiLinPushCatalogDto.setDutyPerson(archiveAutoDtos.get(i).getRollor());
|
|
|
+ jiLinPushCatalogDto.setFilePage(archiveAutoDtos.get(i).getPageN());
|
|
|
+ jiLinPushCatalogDto.setReferenceInfo("0");
|
|
|
+ jiLinPushCatalogDto.setSortOrder(i);
|
|
|
+ jiLinPushCatalogDto.setAddUserName(archiveAutoDtos.get(i).getUpdateUserName());
|
|
|
+ jiLinPushCatalogDto.setAddTime(archiveAutoDtos.get(i).getUpdateUserTime());
|
|
|
+ jiLinPushCatalogDtoList.add(jiLinPushCatalogDto);
|
|
|
+ //设置档案文件
|
|
|
+ JiLinPushFileUrlDto jiLinPushFileUrlDto = new JiLinPushFileUrlDto();
|
|
|
+ jiLinPushFileUrlDto.setProjId(jlPyProjId);
|
|
|
+ jiLinPushFileUrlDto.setPactId(archiveAutoDtos.get(i).getContractId());
|
|
|
+ jiLinPushFileUrlDto.setKid(archiveAutoDtos.get(i).getId());
|
|
|
+ jiLinPushFileUrlDto.setCatalogID(archiveAutoDtos.get(i).getCatlogId());
|
|
|
+ jiLinPushFileUrlDto.setAnnexName(StringUtils.deleteWhitespace(archiveAutoDtos.get(i).getName()));
|
|
|
+ jiLinPushFileUrlDto.setTableNumber(archiveAutoDtos.get(i).getFileNumber());
|
|
|
+ jiLinPushFileUrlDto.setWeaveDate(archiveAutoDtos.get(i).getCreateUserTime());
|
|
|
+ jiLinPushFileUrlDto.setAnnexPage(archiveAutoDtos.get(i).getPageN());
|
|
|
+ jiLinPushFileUrlDto.setFileUrl(archiveAutoDtos.get(i).getPdfFileUrl() == null ? archiveAutoDtos.get(i).getFileUrl() : archiveAutoDtos.get(i).getPdfFileUrl());
|
|
|
+ jiLinPushFileUrlDto.setSortOrder(i);
|
|
|
+ jiLinPushFileUrlDto.setAddUserName(archiveAutoDtos.get(i).getUpdateUserName());
|
|
|
+ jiLinPushFileUrlDto.setAddTime(archiveAutoDtos.get(i).getUpdateUserTime());
|
|
|
+ jiLinPushFileUrlDtoList.add(jiLinPushFileUrlDto);
|
|
|
+ }
|
|
|
+ //传输吉林档案案卷的地址
|
|
|
+ String tome=JSONObject.toJSONString(jiLinPushTomeDtoList);
|
|
|
+ String tomeMsg=tome+PYCLIENTSECRETKEY;
|
|
|
+ String tomeUrl="https://hgqs.jtyst.jl.gov.cn:6100/dock/openapi/veams/api/doc/tome";
|
|
|
+ String tomeSignature = DigestUtils.md5Hex(tomeMsg).toUpperCase();
|
|
|
+ HashMap<String,String> tomeHeaders=new HashMap<>();
|
|
|
+ tomeHeaders.put("Content-Type", "application/json");
|
|
|
+ tomeHeaders.put("clientId",PYCLIENTID);
|
|
|
+ tomeHeaders.put("signature",tomeSignature);
|
|
|
+ tomeHeaders.put("systemId",PYSYSTEMID);
|
|
|
+ String tomeBody = HttpUtil.createPost(tomeUrl).addHeaders(tomeHeaders).body(tome).contentType("application/json").execute().body();
|
|
|
+ System.out.println("第"+(j+1)+"次档案案卷"+tomeBody);
|
|
|
+ //传输吉林档案卷内目录
|
|
|
+ String catLog=JSONObject.toJSONString(jiLinPushCatalogDtoList);
|
|
|
+ String catLogMsg=catLog+PYCLIENTSECRETKEY;
|
|
|
+ String catLogUrl="https://hgqs.jtyst.jl.gov.cn:6100/dock/openapi/veams/api/doc/catalog";
|
|
|
+ String catLogSignature = DigestUtils.md5Hex(catLogMsg).toUpperCase();
|
|
|
+ HashMap<String,String> catLogHeaders=new HashMap<>();
|
|
|
+ catLogHeaders.put("Content-Type", "application/json");
|
|
|
+ catLogHeaders.put("clientId",PYCLIENTID);
|
|
|
+ catLogHeaders.put("signature",catLogSignature);
|
|
|
+ catLogHeaders.put("systemId",PYSYSTEMID);
|
|
|
+ String catLogBody = HttpUtil.createPost(catLogUrl).addHeaders(catLogHeaders).body(catLog).contentType("application/json").execute().body();
|
|
|
+ System.out.println("第"+(j+1)+"次卷内目录"+catLogBody);
|
|
|
|
|
|
-// Long projId=jlPyProjId;
|
|
|
-// for (int j = 0; j <100 ; j++) {
|
|
|
-// Page<JiLinArchiveAutoDto> pages=iJiLinArchiveAutoDtoService.queryAll(j,500,projId);
|
|
|
-// List<JiLinArchiveAutoDto> archiveAutoDtos = pages.getRecords();
|
|
|
-// if(archiveAutoDtos.size()<500) {
|
|
|
-// System.out.println("最后一次数据大小:"+archiveAutoDtos.size());
|
|
|
-// j=101;
|
|
|
-// }
|
|
|
-// List<JiLinPushTomeDto> jiLinPushTomeDtoList = new ArrayList<>();
|
|
|
-// List<JiLinPushCatalogDto> jiLinPushCatalogDtoList = new ArrayList<>();
|
|
|
-// List<JiLinPushFileUrlDto> jiLinPushFileUrlDtoList = new ArrayList<>();
|
|
|
-// for (int i = 0; i < archiveAutoDtos.size(); i++) {
|
|
|
-// //设置档案案卷
|
|
|
-// JiLinPushTomeDto jiLinPushTomeDto = new JiLinPushTomeDto();
|
|
|
-// jiLinPushTomeDto.setPactId(jlPyProjId);
|
|
|
-// jiLinPushTomeDto.setPactId(archiveAutoDtos.get(i).getContractId());
|
|
|
-// jiLinPushTomeDto.setKid(archiveAutoDtos.get(i).getTomeId());
|
|
|
-// jiLinPushTomeDto.setSortID(archiveAutoDtos.get(i).getNodeId());
|
|
|
-// jiLinPushTomeDto.setTomeSuper(archiveAutoDtos.get(i).getName());
|
|
|
-// jiLinPushTomeDto.setRecordNum(archiveAutoDtos.get(i).getFileNumber());
|
|
|
-// jiLinPushTomeDto.setAddUserName(archiveAutoDtos.get(i).getUpdateUserName());
|
|
|
-// jiLinPushTomeDto.setAddTime(archiveAutoDtos.get(i).getCreateUserTime());
|
|
|
-// jiLinPushTomeDto.setBWeaveDate(archiveAutoDtos.get(i).getStartDate());
|
|
|
-// jiLinPushTomeDto.setEWeaveDate(archiveAutoDtos.get(i).getEndDate());
|
|
|
-// jiLinPushTomeDto.setKeepTerm(archiveAutoDtos.get(i).getStorageTime());
|
|
|
-// jiLinPushTomeDto.setSortOrder(i);
|
|
|
-// jiLinPushTomeDto.setMutualNum("0");
|
|
|
-// jiLinPushTomeDto.setWeaveUnit(archiveAutoDtos.get(i).getUnit());
|
|
|
-// jiLinPushTomeDto.setSecrecy(archiveAutoDtos.get(i).getSecretLevel());
|
|
|
-// jiLinPushTomeDto.setYear(Integer.parseInt(archiveAutoDtos.get(i).getStorageTime()));
|
|
|
-// jiLinPushTomeDtoList.add(jiLinPushTomeDto);
|
|
|
-// // 设置档案卷内目录
|
|
|
-// JiLinPushCatalogDto jiLinPushCatalogDto = new JiLinPushCatalogDto();
|
|
|
-// jiLinPushCatalogDto.setProjId(jlPyProjId);
|
|
|
-// jiLinPushCatalogDto.setPactId(archiveAutoDtos.get(i).getContractId());
|
|
|
-// jiLinPushCatalogDto.setKid(archiveAutoDtos.get(i).getCatlogId());
|
|
|
-// jiLinPushCatalogDto.setSortId(archiveAutoDtos.get(i).getNodeId());
|
|
|
-// jiLinPushCatalogDto.setTomeId(archiveAutoDtos.get(i).getTomeId());
|
|
|
-// jiLinPushCatalogDto.setFileSuper(archiveAutoDtos.get(i).getName());
|
|
|
-// jiLinPushCatalogDto.setCatalogRecord(archiveAutoDtos.get(i).getFileNumber());
|
|
|
-// jiLinPushCatalogDto.setAmsFileNum("0");
|
|
|
-// jiLinPushCatalogDto.setFileNum("0");
|
|
|
-// jiLinPushCatalogDto.setWeaveDate(archiveAutoDtos.get(i).getCreateUserTime());
|
|
|
-// jiLinPushCatalogDto.setPieceCount(archiveAutoDtos.get(i).getFileN());
|
|
|
-// jiLinPushCatalogDto.setDutyPerson(archiveAutoDtos.get(i).getRollor());
|
|
|
-// jiLinPushCatalogDto.setFilePage(archiveAutoDtos.get(i).getPageN());
|
|
|
-// jiLinPushCatalogDto.setReferenceInfo("0");
|
|
|
-// jiLinPushCatalogDto.setSortOrder(i);
|
|
|
-// jiLinPushCatalogDto.setAddUserName(archiveAutoDtos.get(i).getUpdateUserName());
|
|
|
-// jiLinPushCatalogDto.setAddTime(archiveAutoDtos.get(i).getUpdateUserTime());
|
|
|
-// jiLinPushCatalogDtoList.add(jiLinPushCatalogDto);
|
|
|
-// //设置档案文件
|
|
|
-// JiLinPushFileUrlDto jiLinPushFileUrlDto = new JiLinPushFileUrlDto();
|
|
|
-// jiLinPushFileUrlDto.setProjId(jlPyProjId);
|
|
|
-// jiLinPushFileUrlDto.setPactId(archiveAutoDtos.get(i).getContractId());
|
|
|
-// jiLinPushFileUrlDto.setKid(archiveAutoDtos.get(i).getId());
|
|
|
-// jiLinPushFileUrlDto.setCatalogID(archiveAutoDtos.get(i).getCatlogId());
|
|
|
-// jiLinPushFileUrlDto.setAnnexName(archiveAutoDtos.get(i).getName());
|
|
|
-// jiLinPushFileUrlDto.setTableNumber(archiveAutoDtos.get(i).getFileNumber());
|
|
|
-// jiLinPushFileUrlDto.setWeaveDate(archiveAutoDtos.get(i).getCreateUserTime());
|
|
|
-// jiLinPushFileUrlDto.setAnnexPage(archiveAutoDtos.get(i).getPageN());
|
|
|
-// jiLinPushFileUrlDto.setFileUrl(archiveAutoDtos.get(i).getPdfFileUrl() == null ? archiveAutoDtos.get(i).getFileUrl() : archiveAutoDtos.get(i).getPdfFileUrl());
|
|
|
-// jiLinPushFileUrlDto.setSortOrder(i);
|
|
|
-// jiLinPushFileUrlDto.setAddUserName(archiveAutoDtos.get(i).getUpdateUserName());
|
|
|
-// jiLinPushFileUrlDto.setAddTime(archiveAutoDtos.get(i).getUpdateUserTime());
|
|
|
-// jiLinPushFileUrlDtoList.add(jiLinPushFileUrlDto);
|
|
|
-// }
|
|
|
-// //传输吉林档案案卷的地址
|
|
|
-// String tome=JSONObject.toJSONString(jiLinPushTomeDtoList);
|
|
|
-// String tomeMsg=tome+PYCLIENTSECRETKEY;
|
|
|
-// String tomeUrl="https://hgqs.jtyst.jl.gov.cn:6100/dock/openapi/veams/api/doc/tome";
|
|
|
-// String tomeSignature = DigestUtils.md5Hex(tomeMsg).toUpperCase();
|
|
|
-// HashMap<String,String> tomeHeaders=new HashMap<>();
|
|
|
-// tomeHeaders.put("Content-Type", "application/json");
|
|
|
-// tomeHeaders.put("clientId",PYCLIENTID);
|
|
|
-// tomeHeaders.put("signature",tomeSignature);
|
|
|
-// tomeHeaders.put("systemId",PYSYSTEMID);
|
|
|
-// String tomeBody = HttpUtil.createPost(tomeUrl).addHeaders(tomeHeaders).body(tome).contentType("application/json").execute().body();
|
|
|
-// System.out.println("第"+j+"次档案案卷"+tomeBody);
|
|
|
-// //传输吉林档案卷内目录
|
|
|
-// String catLog=JSONObject.toJSONString(jiLinPushCatalogDtoList);
|
|
|
-// String catLogMsg=catLog+PYCLIENTSECRETKEY;
|
|
|
-// String catLogUrl="https://hgqs.jtyst.jl.gov.cn:6100/dock/openapi/veams/api/doc/catalog";
|
|
|
-// String catLogSignature = DigestUtils.md5Hex(catLogMsg).toUpperCase();
|
|
|
-// HashMap<String,String> catLogHeaders=new HashMap<>();
|
|
|
-// catLogHeaders.put("Content-Type", "application/json");
|
|
|
-// catLogHeaders.put("clientId",PYCLIENTID);
|
|
|
-// catLogHeaders.put("signature",catLogSignature);
|
|
|
-// catLogHeaders.put("systemId",PYSYSTEMID);
|
|
|
-// String catLogBody = HttpUtil.createPost(catLogUrl).addHeaders(catLogHeaders).body(catLog).contentType("application/json").execute().body();
|
|
|
-// System.out.println("第"+j+"次卷内目录"+catLogBody);
|
|
|
-// //传输吉林档案文件
|
|
|
-// String annex=JSONObject.toJSONString(jiLinPushFileUrlDtoList);
|
|
|
-// String annexMsg=annex+PYCLIENTSECRETKEY;
|
|
|
-// String annexUrl="https://hgqs.jtyst.jl.gov.cn:6100/dock/openapi/veams/api/doc/annex";
|
|
|
-// String annexSignature = DigestUtils.md5Hex(annexMsg).toUpperCase();
|
|
|
-// HashMap<String,String> annexHeaders=new HashMap<>();
|
|
|
-// annexHeaders.put("Content-Type", "application/json");
|
|
|
-// annexHeaders.put("clientId",PYCLIENTID);
|
|
|
-// annexHeaders.put("signature",annexSignature);
|
|
|
-// annexHeaders.put("systemId",PYSYSTEMID);
|
|
|
-// String annexBody = HttpUtil.createPost(annexUrl).addHeaders(annexHeaders).body(annex).contentType("application/json").execute().body();
|
|
|
-// System.out.println("第"+j+"次档案文件"+annexBody);
|
|
|
-// }
|
|
|
-// System.out.println("蒲烟传输结束");
|
|
|
+ //传输吉林档案文件
|
|
|
+ String annex=JSONObject.toJSONString(jiLinPushFileUrlDtoList);
|
|
|
+ String annexMsg=annex+PYCLIENTSECRETKEY;
|
|
|
+ String annexUrl="https://hgqs.jtyst.jl.gov.cn:6100/dock/openapi/veams/api/doc/annex";
|
|
|
+ String annexSignature = DigestUtils.md5Hex(annexMsg).toUpperCase();
|
|
|
+ HashMap<String,String> annexHeaders=new HashMap<>();
|
|
|
+ annexHeaders.put("Content-Type", "application/json");
|
|
|
+ annexHeaders.put("clientId",PYCLIENTID);
|
|
|
+ annexHeaders.put("signature",annexSignature);
|
|
|
+ annexHeaders.put("systemId",PYSYSTEMID);
|
|
|
+ String annexBody = HttpUtil.createPost(annexUrl).addHeaders(annexHeaders).body(annex).contentType("application/json").execute().body();
|
|
|
+ System.out.println("第"+(j+1)+"次档案文件"+annexBody);
|
|
|
+ }
|
|
|
+ System.out.println("蒲烟传输结束");
|
|
|
}
|
|
|
}
|