|
@@ -88,12 +88,12 @@ public class EsignSignServiceImpl implements IEsignSignService {
|
|
|
}
|
|
|
|
|
|
|
|
|
- * @description: 司机授权书
|
|
|
- * @param: [businessScene, fileId, posX, posY, posX2, posY2, fileName, signerAccountId, authorizedAccountId, redirectUrl]
|
|
|
- * @return: java.lang.String
|
|
|
- * @author: njs
|
|
|
- * @date: 2023/2/28 16:10
|
|
|
- */
|
|
|
+ * @description: 司机授权书
|
|
|
+ * @param: [businessScene, fileId, posX, posY, posX2, posY2, fileName, signerAccountId, authorizedAccountId, redirectUrl]
|
|
|
+ * @return: java.lang.String
|
|
|
+ * @author: njs
|
|
|
+ * @date: 2023/2/28 16:10
|
|
|
+ */
|
|
|
@Override
|
|
|
public String oneStepFlowDriver(String businessScene, String fileId, float posX, float posY, float posX2, float posY2, String fileName, String signerAccountId, String authorizedAccountId, String redirectUrl) {
|
|
|
JSONObject json = buildParamDriver(businessScene, fileId,posX,posY,posX2,posY2, fileName, signerAccountId,authorizedAccountId,redirectUrl);
|
|
@@ -260,14 +260,14 @@ public class EsignSignServiceImpl implements IEsignSignService {
|
|
|
orderFile.setFlowId(flowId);
|
|
|
if(orderFlag.getTypes()==1){
|
|
|
downloadFile(Global.getPdfPath(), orderFlag.getOrderId()+uId + ".pdf", fileUrl);
|
|
|
- orderFile.setFileUrl(Constants.RESOURCE_PREFIX+"/pdf/"+DateUtils.datePath()+"/"+orderFlag.getOrderId()+uId + "_司机授权.pdf");
|
|
|
- tmsCertificate(orderFlag.getDeliveryNumber(),Constants.RESOURCE_PREFIX+"/pdf/"+DateUtils.datePath()+"/"+orderFlag.getOrderId()+uId + "_司机授权.pdf");
|
|
|
+ orderFile.setFileUrl(Constants.RESOURCE_PREFIX+"/pdf/"+DateUtils.datePath()+"/"+orderFlag.getOrderId()+uId + ".pdf");
|
|
|
+ tmsCertificate(orderFlag.getDeliveryNumber(),Constants.RESOURCE_PREFIX+"/pdf/"+DateUtils.datePath()+"/"+orderFlag.getOrderId()+uId + ".pdf");
|
|
|
}else if( orderFlag.getTypes()==2){
|
|
|
- downloadFile(Global.getPdfPath(), orderFlag.getFlowId()+uId + "_签收订单.pdf", fileUrl);
|
|
|
- orderFile.setFileUrl(Constants.RESOURCE_PREFIX+"/pdf/"+DateUtils.datePath()+"/"+orderFlag.getFlowId()+uId + "_签收订单.pdf");
|
|
|
+ downloadFile(Global.getPdfPath(), orderFlag.getFlowId()+uId + "_授权委托.pdf", fileUrl);
|
|
|
+ orderFile.setFileUrl(Constants.RESOURCE_PREFIX+"/pdf/"+DateUtils.datePath()+"/"+orderFlag.getFlowId()+uId + "_授权委托.pdf");
|
|
|
}else{
|
|
|
- downloadFile(Global.getPdfPath(), orderFlag.getOrderId()+uId + "_授权委托.pdf", fileUrl);
|
|
|
- orderFile.setFileUrl(Constants.RESOURCE_PREFIX+"/pdf/"+DateUtils.datePath()+"/"+orderFlag.getOrderId()+uId + "_授权委托.pdf");
|
|
|
+ downloadFile(Global.getPdfPath(), orderFlag.getOrderId()+uId + "_签收订单.pdf", fileUrl);
|
|
|
+ orderFile.setFileUrl(Constants.RESOURCE_PREFIX+"/pdf/"+DateUtils.datePath()+"/"+orderFlag.getOrderId()+uId + "_签收订单.pdf");
|
|
|
|
|
|
}
|
|
|
|
|
@@ -277,7 +277,7 @@ public class EsignSignServiceImpl implements IEsignSignService {
|
|
|
* @description: orders交货单
|
|
|
* @param: [orders, certificateUrl]
|
|
|
* @return: void
|
|
|
- * @author: njs
|
|
|
+ * @author: njs
|
|
|
* @date: 2023/4/12 18:29
|
|
|
*/
|
|
|
@Override
|
|
@@ -369,29 +369,21 @@ public class EsignSignServiceImpl implements IEsignSignService {
|
|
|
List<Attachment> attachments = new ArrayList<>();
|
|
|
|
|
|
|
|
|
- Copier copier = new Copier();
|
|
|
- copier.setCopierAccountId(signerAccountId);
|
|
|
- copier.setCopierIdentityAccountType(0);
|
|
|
+ Copier copier = new Copier(signerAccountId, 0, null);
|
|
|
List<Copier> copiers = new ArrayList<>();
|
|
|
copiers.add(copier);
|
|
|
|
|
|
|
|
|
- Doc doc = new Doc();
|
|
|
- doc.setFileId(fileId);
|
|
|
- doc.setFileName(fileName);
|
|
|
+ Doc doc = new Doc(fileId, fileName);
|
|
|
+
|
|
|
List<Doc> docs = new ArrayList<>();
|
|
|
docs.add(doc);
|
|
|
|
|
|
|
|
|
String noticeDeveloperUrl = eSignConfig.getSignSuccessUrl();
|
|
|
- FlowConfigInfo flowConfigInfo = new FlowConfigInfo();
|
|
|
- flowConfigInfo.setNoticeDeveloperUrl(noticeDeveloperUrl);
|
|
|
- flowConfigInfo.setNoticeType("1,2");
|
|
|
- FlowInfo flowInfo = new FlowInfo();
|
|
|
- flowInfo.setAutoArchive(true);
|
|
|
- flowInfo.setAutoInitiate(true);
|
|
|
- flowInfo.setBusinessScene(businessScene);
|
|
|
- flowInfo.setFlowConfigInfo(flowConfigInfo);
|
|
|
+ FlowConfigInfo flowConfigInfo = new FlowConfigInfo(noticeDeveloperUrl, "1,2", null, null);
|
|
|
+ FlowInfo flowInfo = new FlowInfo(true,true,businessScene,flowConfigInfo);
|
|
|
+
|
|
|
|
|
|
|
|
|
PosBeanInfo posBean1 = new PosBeanInfo("1", posX, posY);
|
|
@@ -404,13 +396,8 @@ public class EsignSignServiceImpl implements IEsignSignService {
|
|
|
signfields.add(signfield1);
|
|
|
signfields.add(signfield2);
|
|
|
|
|
|
- SignerAccount signAccount = new SignerAccount();
|
|
|
- signAccount.setSignerAccountId(authorizedAccountId);
|
|
|
- Signer signer1 = new Signer();
|
|
|
- signer1.setPlatformSign(false);
|
|
|
- signer1.setSignOrder(1);
|
|
|
- signer1.setSignerAccount(signAccount);
|
|
|
- signer1.setSignfields(signfields);
|
|
|
+ SignerAccount signAccount = new SignerAccount(authorizedAccountId);
|
|
|
+ Signer signer1 = new Signer(false, 1, signAccount, signfields, null);
|
|
|
|
|
|
|
|
|
|
|
@@ -420,7 +407,7 @@ public class EsignSignServiceImpl implements IEsignSignService {
|
|
|
List<Signer> signers = new ArrayList<>();
|
|
|
signers.add(signer1);
|
|
|
|
|
|
- log.info("E签宝拼接需要的参数++++", signers);
|
|
|
+
|
|
|
|
|
|
return buildOneStepFlowParam(attachments, copiers, docs, flowInfo, signers);
|
|
|
}
|
|
@@ -455,9 +442,9 @@ public class EsignSignServiceImpl implements IEsignSignService {
|
|
|
* @description: 下载文件
|
|
|
* @param: [filePath, fileName, httpUrl]
|
|
|
* @return: void
|
|
|
- * @author: qxm
|
|
|
+ * @author: qxm
|
|
|
* @date: 2020/10/27 9:58
|
|
|
- */
|
|
|
+ */
|
|
|
public static void downloadFile(String filePath,String fileName,String httpUrl){
|
|
|
BufferedInputStream bis=null;
|
|
|
BufferedOutputStream bos=null;
|