换绑更新跟进任务id

This commit is contained in:
zhangchenbiao
2023-08-23 17:42:02 +08:00
parent 9e6fce5060
commit 5ee8b907f0
4 changed files with 27 additions and 0 deletions

View File

@@ -207,6 +207,18 @@ public class HyFollowTaskDAO {
return hyFollowTaskMapper.updateUndoTaskStatusToOverdue(); return hyFollowTaskMapper.updateUndoTaskStatusToOverdue();
} }
/**
* 更改线索id
* @param oldLineId
* @param newLineId
*/
public Integer changeLineId(Long oldLineId, Long newLineId){
if(Objects.isNull(oldLineId) || Objects.isNull(newLineId)){
return CommonConstants.ZERO;
}
return hyFollowTaskMapper.changeLineId(oldLineId, newLineId);
}
} }

View File

@@ -100,4 +100,12 @@ public interface HyFollowTaskMapper {
* @return * @return
*/ */
List<HyFollowTaskDO> getFollowTaskList(@Param("followTaskIds") List<Long> followTaskIds); List<HyFollowTaskDO> getFollowTaskList(@Param("followTaskIds") List<Long> followTaskIds);
/**
* 更改线索id
* @param oldLineId
* @param newLineId
* @return
*/
Integer changeLineId(@Param("oldLineId") Long oldLineId, @Param("newLineId") Long newLineId);
} }

View File

@@ -245,5 +245,9 @@
where where
deleted = '0' and id in <foreach collection="followTaskIds" item="followTaskId" separator="," open="(" close=")">#{followTaskId}</foreach> deleted = '0' and id in <foreach collection="followTaskIds" item="followTaskId" separator="," open="(" close=")">#{followTaskId}</foreach>
</select> </select>
<update id="changeLineId">
update hy_follow_task set partner_line_id = #{newLineId} where partner_line_id = #{oldLineId}
</update>
</mapper> </mapper>

View File

@@ -80,6 +80,8 @@ public class HyPartnerBaseInfoServiceImpl implements HyPartnerBaseInfoService {
private LogService logService; private LogService logService;
@Resource @Resource
private LabelService labelService; private LabelService labelService;
@Resource
private HyFollowTaskDAO hyFollowTaskDAO;
@Override @Override
@@ -264,6 +266,7 @@ public class HyPartnerBaseInfoServiceImpl implements HyPartnerBaseInfoService {
hyInterviewDAO.updateLineId(newPartnerId,newLindId,oldLineInfo.getId()); hyInterviewDAO.updateLineId(newPartnerId,newLindId,oldLineInfo.getId());
hyPartnerCertificationInfoMapper.updateLineId(newPartnerId,newLindId,oldLineInfo.getId()); hyPartnerCertificationInfoMapper.updateLineId(newPartnerId,newLindId,oldLineInfo.getId());
hyPartnerTaskInfoLogDAO.updateLineId(newPartnerId,newLindId,oldLineInfo.getId()); hyPartnerTaskInfoLogDAO.updateLineId(newPartnerId,newLindId,oldLineInfo.getId());
hyFollowTaskDAO.changeLineId(oldLineInfo.getId(), newLindId);
String cacheKeyBaseInfo = MessageFormat.format(RedisConstant.PARTNER_BASEINFO_CACHE_KEY, newPartnerId, newLindId); String cacheKeyBaseInfo = MessageFormat.format(RedisConstant.PARTNER_BASEINFO_CACHE_KEY, newPartnerId, newLindId);
String cacheKeyClerkInfo = MessageFormat.format(RedisConstant.PARTNER_CLERKINFO_CACHE_KEY,newPartnerId, newLindId); String cacheKeyClerkInfo = MessageFormat.format(RedisConstant.PARTNER_CLERKINFO_CACHE_KEY,newPartnerId, newLindId);
String cacheKeyIntentInfo = MessageFormat.format(RedisConstant.PARTNER_INTENTINFO_CACHE_KEY, newPartnerId, newLindId); String cacheKeyIntentInfo = MessageFormat.format(RedisConstant.PARTNER_INTENTINFO_CACHE_KEY, newPartnerId, newLindId);