Commit 52a23ed3 by 崔彦峰

modify: 提交优加回调接口。

1 parent 10b7b3f6
......@@ -29,6 +29,9 @@ public class ESignNotifyController extends HttpServlet {
@Value("${esign.appKey}")
private String appSecret;
@Value("${yjzhEsign.appKey}")
private String yjzhAppSecret;
@Autowired
private ESignRemote esignRemote;
......@@ -50,4 +53,19 @@ public class ESignNotifyController extends HttpServlet {
return Map.of("code", "200", "msg", "success");
}
@PostMapping("/yjzhNotify")
public Map<String, String> yjzhEsignNotify(@RequestBody String param, HttpServletRequest request) throws IOException {
log.info("yjzhEsignNotify param:{}", param);
if (StringUtils.isBlank(param)) {
return Map.of("code", "500", "msg", "fail");
}
SafeVerify sv = new SafeVerify();
String res =sv.checkPass(param, request, yjzhAppSecret);
if (!res.equals("true")) {
return Map.of("code", "500", "msg", "fail");
}
esignRemote.notify(param);
return Map.of("code", "200", "msg", "success");
}
}
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!