修改同步添加联系人

This commit is contained in:
zhangwenzan 2025-09-16 14:46:03 +08:00
parent 1c43e1dd61
commit a2ff304ae0
1 changed files with 37 additions and 38 deletions

View File

@ -391,6 +391,7 @@ public class CrmCustomerServiceImpl extends BaseServiceImpl<CrmCustomerMapper, C
/** /**
* 数据脱敏 * 数据脱敏
*
* @param crmModel * @param crmModel
*/ */
private CrmModel encryptSensitiveData(CrmModel crmModel) { private CrmModel encryptSensitiveData(CrmModel crmModel) {
@ -422,6 +423,7 @@ public class CrmCustomerServiceImpl extends BaseServiceImpl<CrmCustomerMapper, C
/** /**
* 获取客户明文 * 获取客户明文
*
* @param plaintextVO * @param plaintextVO
* @return * @return
*/ */
@ -471,6 +473,7 @@ public class CrmCustomerServiceImpl extends BaseServiceImpl<CrmCustomerMapper, C
/** /**
* 判断crmType * 判断crmType
*
* @param plaintextVO * @param plaintextVO
*/ */
@Override @Override
@ -598,7 +601,6 @@ public class CrmCustomerServiceImpl extends BaseServiceImpl<CrmCustomerMapper, C
CrmCustomer finalCrmCustomer = crmCustomer; CrmCustomer finalCrmCustomer = crmCustomer;
CrmModelFiledVO crmModelFiled = crmModel.getField().get(6); CrmModelFiledVO crmModelFiled = crmModel.getField().get(6);
new Thread(() -> {
if (finalCrmCustomer.getTelephone() != null && !finalCrmCustomer.getTelephone().isEmpty()) { if (finalCrmCustomer.getTelephone() != null && !finalCrmCustomer.getTelephone().isEmpty()) {
// 客户填写 // 客户填写
addContacts(finalCrmCustomer.getCustomerId(), finalCrmCustomer.getTelephone(), crmModelFiled.getValue().toString(), finalCrmCustomer.getMobile(), "", finalCrmCustomer.getEmail()); addContacts(finalCrmCustomer.getCustomerId(), finalCrmCustomer.getTelephone(), crmModelFiled.getValue().toString(), finalCrmCustomer.getMobile(), "", finalCrmCustomer.getEmail());
@ -606,21 +608,18 @@ public class CrmCustomerServiceImpl extends BaseServiceImpl<CrmCustomerMapper, C
// 税局信息 // 税局信息
// 法定代表人 // 法定代表人
if (StrUtil.isNotEmpty(qyjbxxByNsrmc.getFddbrxm()) && StrUtil.isNotEmpty(qyjbxxByNsrmc.getFddbryddh())) { if (Objects.nonNull(qyjbxxByNsrmc) && StrUtil.isNotEmpty(qyjbxxByNsrmc.getFddbrxm()) && StrUtil.isNotEmpty(qyjbxxByNsrmc.getFddbryddh())) {
addContacts(finalCrmCustomer.getCustomerId(), qyjbxxByNsrmc.getFddbrxm(), "法定代表人", qyjbxxByNsrmc.getFddbryddh(), qyjbxxByNsrmc.getFddbrgddh(), qyjbxxByNsrmc.getFddbrdzxx()); addContacts(finalCrmCustomer.getCustomerId(), qyjbxxByNsrmc.getFddbrxm(), "法定代表人", qyjbxxByNsrmc.getFddbryddh(), qyjbxxByNsrmc.getFddbrgddh(), qyjbxxByNsrmc.getFddbrdzxx());
} }
// 财务负责人 // 财务负责人
if (StrUtil.isNotEmpty(qyjbxxByNsrmc.getCwfzrxm()) && StrUtil.isNotEmpty(qyjbxxByNsrmc.getCwfzryddh())) { if (Objects.nonNull(qyjbxxByNsrmc) && StrUtil.isNotEmpty(qyjbxxByNsrmc.getCwfzrxm()) && StrUtil.isNotEmpty(qyjbxxByNsrmc.getCwfzryddh())) {
addContacts(finalCrmCustomer.getCustomerId(), qyjbxxByNsrmc.getCwfzrxm(), "财务负责人", qyjbxxByNsrmc.getCwfzryddh(), qyjbxxByNsrmc.getCwfzrgddh(), qyjbxxByNsrmc.getCwfzrdzxx()); addContacts(finalCrmCustomer.getCustomerId(), qyjbxxByNsrmc.getCwfzrxm(), "财务负责人", qyjbxxByNsrmc.getCwfzryddh(), qyjbxxByNsrmc.getCwfzrgddh(), qyjbxxByNsrmc.getCwfzrdzxx());
} }
// 办税人 // 办税人
if (StrUtil.isNotEmpty(qyjbxxByNsrmc.getBsrxm()) && StrUtil.isNotEmpty(qyjbxxByNsrmc.getBsryddh())) { if (Objects.nonNull(qyjbxxByNsrmc) && StrUtil.isNotEmpty(qyjbxxByNsrmc.getBsrxm()) && StrUtil.isNotEmpty(qyjbxxByNsrmc.getBsryddh())) {
addContacts(finalCrmCustomer.getCustomerId(), qyjbxxByNsrmc.getBsrxm(), "办税人", qyjbxxByNsrmc.getBsryddh(), qyjbxxByNsrmc.getBsrgddh(), qyjbxxByNsrmc.getBsrdzxx()); addContacts(finalCrmCustomer.getCustomerId(), qyjbxxByNsrmc.getBsrxm(), "办税人", qyjbxxByNsrmc.getBsryddh(), qyjbxxByNsrmc.getBsrgddh(), qyjbxxByNsrmc.getBsrdzxx());
} }
}).start();
map.put("customerId", crmCustomer.getCustomerId()); map.put("customerId", crmCustomer.getCustomerId());
map.put("customerName", crmCustomer.getCustomerName()); map.put("customerName", crmCustomer.getCustomerName());