Commit 658380d0 authored by 唐峰's avatar 唐峰

注册登录合同重复签署问题

parent b0fbece8
......@@ -16,7 +16,7 @@ public class LoginReq {
private boolean attachInfo;
/**
* 0:h5,1:web,2:app
* 0:app 1:h5,2:web,
* @see ClientType
*/
@NotNull
......
......@@ -58,30 +58,31 @@ public class BlackHoleRegisteredEventListener implements ApplicationListener<Reg
if (lock.lock()) {
//补签合同,如果需要补签 BlackHoleRegisteredEventListener 签署注册和隐私协议
//此处补签,对于合同中心,可能会重新签署,后续待合同中心处理并发问题或者重复签署逻辑
Thread.sleep(2000);
//Thread.sleep(2000);
JSONArray array = new JSONArray();
//JSONArray array = new JSONArray();
templates.forEach(templateId -> {
JSONObject json = new JSONObject();
if (templateId == 8 || templateId == 280) {
JSONObject fields = new JSONObject();
fields.put("phoneNo", user.getPhoneNo());
fields.put("genarateDateStr", dateStr);
fields.put("day", day);
JSONObject json = new JSONObject();
json.put("userId", user.getId());
json.put("mustReal", false);
json.put("templateId", templateId);
json.put("fields", fields);
array.add(json);
//array.add(json);
} else {
JSONObject json = new JSONObject();
json.put("userId", user.getId());
json.put("templateId", templateId);
array.add(json);
//array.add(json);
}
log.info("注册签合同事件:{},",JSONObject.toJSONString(event));
registeredNotifyBlackHoleRabbitTemplate.convertAndSend(exchange, routingKey,
array.toString());
json.toString());
});
}
} catch (Exception e) {
......
......@@ -66,7 +66,7 @@ public class UserTagLoginEventListener implements ApplicationListener<UserLoginE
if (lock.lock()) {
//补签合同,如果需要补签 BlackHoleRegisteredEventListener 签署注册和隐私协议
//此处补签,对于合同中心,可能会重新签署,后续待合同中心处理并发问题或者重复签署逻辑
Thread.sleep(2000);
//Thread.sleep(2000);
userService.channelUserSignContract(user, userTag.getRegisteredFrom(), userTag.getTenantId());
}
} catch (Exception e) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment