|
@@ -633,21 +633,7 @@ public class FsUserInformationCollectionServiceImpl extends ServiceImpl<FsUserIn
|
|
|
|
|
|
|
|
@Override
|
|
@Override
|
|
|
public FsUserInfoCollectionUVO info(Long id,Long userId) {
|
|
public FsUserInfoCollectionUVO info(Long id,Long userId) {
|
|
|
- FsUserInformationCollection selectByUserId = fsUserInformationCollectionMapper.selectByUserId(userId);
|
|
|
|
|
- if (selectByUserId != null) {
|
|
|
|
|
- //查询此用户是否添加该销售企微好友,未添加提示添加销售
|
|
|
|
|
- QwExternalContact externalContactCondition=new QwExternalContact();
|
|
|
|
|
- externalContactCondition.setFsUserId(userId);
|
|
|
|
|
- externalContactCondition.setCompanyUserId(selectByUserId.getCompanyUserId());
|
|
|
|
|
- List<QwExternalContact> qwExternalContacts = qwExternalContactMapper.selectQwExternalContactList(externalContactCondition);
|
|
|
|
|
- if (CollectionUtils.isEmpty(qwExternalContacts)){
|
|
|
|
|
- log.error("客户二次提交采集信息,销售与分享客户之间没有企微好友关系,当前销售id:{},当前客户id:{}",selectByUserId.getCompanyUserId(),userId);
|
|
|
|
|
- throw new CustomException("请添加分享销售企微好友!");
|
|
|
|
|
- }
|
|
|
|
|
- if (!selectByUserId.getId().equals(id)) {
|
|
|
|
|
- throw new CustomException("已有信息采集信息!,请联系销售重新分享二维码!");
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
|
|
+
|
|
|
FsUserInfoCollectionUVO vo = new FsUserInfoCollectionUVO();
|
|
FsUserInfoCollectionUVO vo = new FsUserInfoCollectionUVO();
|
|
|
FsUserInformationCollection collection = fsUserInformationCollectionMapper.selectFsUserInformationCollectionById(id);
|
|
FsUserInformationCollection collection = fsUserInformationCollectionMapper.selectFsUserInformationCollectionById(id);
|
|
|
|
|
|
|
@@ -1318,6 +1304,21 @@ public class FsUserInformationCollectionServiceImpl extends ServiceImpl<FsUserIn
|
|
|
if (collection.getUserId() != null) {
|
|
if (collection.getUserId() != null) {
|
|
|
return R.error("信息采集已绑定用户");
|
|
return R.error("信息采集已绑定用户");
|
|
|
}
|
|
}
|
|
|
|
|
+ FsUserInformationCollection selectByUserId = fsUserInformationCollectionMapper.selectByUserId(param.getUserId());
|
|
|
|
|
+ if (selectByUserId != null) {
|
|
|
|
|
+ //查询此用户是否添加该销售企微好友,未添加提示添加销售
|
|
|
|
|
+ QwExternalContact externalContactCondition=new QwExternalContact();
|
|
|
|
|
+ externalContactCondition.setFsUserId(param.getUserId());
|
|
|
|
|
+ externalContactCondition.setCompanyUserId(selectByUserId.getCompanyUserId());
|
|
|
|
|
+ List<QwExternalContact> qwExternalContacts = qwExternalContactMapper.selectQwExternalContactList(externalContactCondition);
|
|
|
|
|
+ if (CollectionUtils.isEmpty(qwExternalContacts)){
|
|
|
|
|
+ log.error("客户二次提交采集信息,销售与分享客户之间没有企微好友关系,当前销售id:{},当前客户id:{}",selectByUserId.getCompanyUserId(),param.getUserId());
|
|
|
|
|
+ throw new CustomException("请添加分享销售企微好友!");
|
|
|
|
|
+ }
|
|
|
|
|
+ if (!selectByUserId.getId().equals(param.getCollectionId())) {
|
|
|
|
|
+ throw new CustomException("已有信息采集信息!,请联系销售重新分享二维码!");
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
|
|
|
FsUserInformationCollection map = new FsUserInformationCollection();
|
|
FsUserInformationCollection map = new FsUserInformationCollection();
|
|
|
map.setUserId(param.getUserId());
|
|
map.setUserId(param.getUserId());
|