|
|
@@ -0,0 +1,55 @@
|
|
|
+package com.hr.externelSystem;
|
|
|
+
|
|
|
+import com.alibaba.fastjson.JSONObject;
|
|
|
+import com.hr.dto.ApiLogDto;
|
|
|
+import com.hr.dto.EsignParmDto;
|
|
|
+import com.hr.dto.EsignReturnDto;
|
|
|
+import com.hr.repository.domain.IpInterfacePO;
|
|
|
+import com.hr.repository.domain.IpOrderPO;
|
|
|
+import com.hr.repository.service.EsignService;
|
|
|
+import com.hr.vo.CallbackResponseVO;
|
|
|
+import com.hr.vo.ServiceTypeVO;
|
|
|
+import com.yy.basedevelop.common.data.BaseReturnDto;
|
|
|
+import lombok.extern.slf4j.Slf4j;
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.stereotype.Service;
|
|
|
+
|
|
|
+/**
|
|
|
+ * @author yaoy
|
|
|
+ * @createTime 2025/10/23 16:00
|
|
|
+ **/
|
|
|
+@Service
|
|
|
+@Slf4j
|
|
|
+public class ESignGenPdfService implements BizHandler<EsignParmDto, EsignReturnDto>{
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ private EsignService esignService;
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public ServiceTypeVO getType() {
|
|
|
+ return new ServiceTypeVO("esignPdf","E签宝PDF");
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public EsignReturnDto handle(EsignParmDto esignParmDto, IpInterfacePO ipInterfacePO, ApiLogDto logDto) {
|
|
|
+ BaseReturnDto<EsignReturnDto> rdto=esignService.platformSignByPdfStream(esignParmDto);
|
|
|
+
|
|
|
+ logDto.setHttpStatus(String.valueOf(rdto.getCode()));
|
|
|
+ logDto.setUrl(rdto.getData().getOssurl());
|
|
|
+ logDto.setResponseParam(JSONObject.toJSONString(rdto.getData()));
|
|
|
+ logDto.setErrorMessage(rdto.getMsg());
|
|
|
+ logDto.setBusinessNo(esignParmDto.getOssFileName());
|
|
|
+
|
|
|
+ return rdto.getData();
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public Class<EsignParmDto> getRequestClass() {
|
|
|
+ return EsignParmDto.class;
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public CallbackResponseVO doCallBack(IpOrderPO ipOrderPO, JSONObject callbackParam) {
|
|
|
+ return null;
|
|
|
+ }
|
|
|
+}
|