清空老线索信息
This commit is contained in:
@@ -9,7 +9,6 @@ import com.cool.store.mapper.HyPartnerLineInfoMapper;
|
|||||||
import com.google.common.collect.Lists;
|
import com.google.common.collect.Lists;
|
||||||
import org.apache.commons.collections4.CollectionUtils;
|
import org.apache.commons.collections4.CollectionUtils;
|
||||||
import org.apache.commons.lang3.StringUtils;
|
import org.apache.commons.lang3.StringUtils;
|
||||||
import org.apache.ibatis.annotations.Param;
|
|
||||||
import org.springframework.stereotype.Repository;
|
import org.springframework.stereotype.Repository;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
@@ -60,6 +59,10 @@ public class HyPartnerLineInfoDAO {
|
|||||||
return hyPartnerLineInfoMapper.updateByPrimaryKeySelective(hyPartnerLineInfoDO);
|
return hyPartnerLineInfoMapper.updateByPrimaryKeySelective(hyPartnerLineInfoDO);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public int updateByPrimaryKey(HyPartnerLineInfoDO record){
|
||||||
|
return hyPartnerLineInfoMapper.updateByPrimaryKey(record);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
public Integer getAdventLineCount( String userId, String currentDate){
|
public Integer getAdventLineCount( String userId, String currentDate){
|
||||||
if (StringUtils.isEmpty(userId)){
|
if (StringUtils.isEmpty(userId)){
|
||||||
|
|||||||
@@ -5,8 +5,6 @@ import com.cool.store.dto.partner.PartnerBlackListDTO;
|
|||||||
import com.cool.store.dto.partner.PartnerLineInfoAndBaseInfoDTO;
|
import com.cool.store.dto.partner.PartnerLineInfoAndBaseInfoDTO;
|
||||||
import com.cool.store.dto.partner.StageCountDTO;
|
import com.cool.store.dto.partner.StageCountDTO;
|
||||||
import com.cool.store.entity.HyPartnerLineInfoDO;
|
import com.cool.store.entity.HyPartnerLineInfoDO;
|
||||||
import com.cool.store.vo.LineFollowHistoryVO;
|
|
||||||
import com.github.pagehelper.PageInfo;
|
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
@@ -54,6 +52,9 @@ public interface HyPartnerLineInfoMapper {
|
|||||||
*/
|
*/
|
||||||
int updateByPrimaryKeySelective(@Param("record") HyPartnerLineInfoDO record);
|
int updateByPrimaryKeySelective(@Param("record") HyPartnerLineInfoDO record);
|
||||||
|
|
||||||
|
int updateByPrimaryKey(@Param("record") HyPartnerLineInfoDO record);
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 当前用户指定时间 临期线索
|
* 当前用户指定时间 临期线索
|
||||||
* @param userId
|
* @param userId
|
||||||
|
|||||||
@@ -253,6 +253,29 @@
|
|||||||
where id = #{record.id}
|
where id = #{record.id}
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
|
<update id="updateByPrimaryKey">
|
||||||
|
update hy_partner_line_info
|
||||||
|
set
|
||||||
|
partner_id = #{record.partnerId},
|
||||||
|
workflow_stage = #{record.workflowStage},
|
||||||
|
workflow_status = #{record.workflowStatus},
|
||||||
|
line_status = #{record.lineStatus},
|
||||||
|
investment_manager = #{record.investmentManager},
|
||||||
|
development_director = #{record.developmentDirector},
|
||||||
|
development_manager = #{record.developmentManager},
|
||||||
|
deadline = #{record.deadline},
|
||||||
|
pass_reason = #{record.passReason},
|
||||||
|
reject_public_reason = #{record.rejectPublicReason},
|
||||||
|
reject_real_reason = #{record.rejectRealReason},
|
||||||
|
certify_file = #{record.certifyFile},
|
||||||
|
close_time = #{record.closeTime},
|
||||||
|
close_user_id = #{record.closeUserId},
|
||||||
|
join_black_reason = #{record.joinBlackReason},
|
||||||
|
remove_black_reason = #{record.removeBlackReason},
|
||||||
|
user_channel_id = #{record.userChannelId}
|
||||||
|
where id = #{record.id}
|
||||||
|
</update>
|
||||||
|
|
||||||
<select id="getAdventLineCount" resultType="java.lang.Integer">
|
<select id="getAdventLineCount" resultType="java.lang.Integer">
|
||||||
select count(1) from hy_partner_line_info
|
select count(1) from hy_partner_line_info
|
||||||
<where>
|
<where>
|
||||||
|
|||||||
@@ -189,14 +189,12 @@ public class HyPartnerBaseInfoServiceImpl implements HyPartnerBaseInfoService {
|
|||||||
HyPartnerLineInfoDO newLineInfo = hyPartnerLineInfoDAO.selectByPrimaryKeySelective(lineId);
|
HyPartnerLineInfoDO newLineInfo = hyPartnerLineInfoDAO.selectByPrimaryKeySelective(lineId);
|
||||||
Long newLindId = newLineInfo.getId();
|
Long newLindId = newLineInfo.getId();
|
||||||
String newPartnerId = newLineInfo.getPartnerId();
|
String newPartnerId = newLineInfo.getPartnerId();
|
||||||
BeanUtil.copyProperties(oldLineInfo,newLineInfo);
|
BeanUtil.copyProperties(oldLineInfo,newLineInfo,"createTime","updateTime","id","deleted");
|
||||||
newLineInfo.setId(newLindId);
|
newLineInfo.setId(newLindId);
|
||||||
newLineInfo.setPartnerId(newPartnerId);
|
newLineInfo.setPartnerId(newPartnerId);
|
||||||
hyPartnerLineInfoDAO.updateByPrimaryKeySelective(newLineInfo);
|
hyPartnerLineInfoDAO.updateByPrimaryKeySelective(newLineInfo);
|
||||||
oldLineInfo.setWorkflowStage(WorkflowStageEnum.INTENT.getCode());
|
cleanOldLineInfo(oldLineInfo);
|
||||||
oldLineInfo.setWorkflowStatus(WorkflowStatusEnum.INTENT_0.getCode());
|
hyPartnerLineInfoDAO.updateByPrimaryKey(oldLineInfo);
|
||||||
oldLineInfo.setLineStatus(LineStatusEnum.PUBLIC_SEAS.getCode());
|
|
||||||
hyPartnerLineInfoDAO.updateByPrimaryKeySelective(oldLineInfo);
|
|
||||||
// 新线索绑定身份证号
|
// 新线索绑定身份证号
|
||||||
HyPartnerBaseInfoDO newBaseInfo = hyPartnerBaseInfoDAO.getByPartnerIdAndLineId(currentUser.getPartnerId(), lineId);
|
HyPartnerBaseInfoDO newBaseInfo = hyPartnerBaseInfoDAO.getByPartnerIdAndLineId(currentUser.getPartnerId(), lineId);
|
||||||
fillBaseInfoIdCard(newBaseInfo, oldBaseInfo.getIdCard(), oldBaseInfo.getIdCardPhotoFront(), oldBaseInfo.getIdCardPhotoBlack(), oldBaseInfo.getUsername(),
|
fillBaseInfoIdCard(newBaseInfo, oldBaseInfo.getIdCard(), oldBaseInfo.getIdCardPhotoFront(), oldBaseInfo.getIdCardPhotoBlack(), oldBaseInfo.getUsername(),
|
||||||
@@ -231,6 +229,25 @@ public class HyPartnerBaseInfoServiceImpl implements HyPartnerBaseInfoService {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void cleanOldLineInfo(HyPartnerLineInfoDO oldLineInfo) {
|
||||||
|
oldLineInfo.setWorkflowStage(WorkflowStageEnum.INTENT.getCode());
|
||||||
|
oldLineInfo.setWorkflowStatus(WorkflowStatusEnum.INTENT_0.getCode());
|
||||||
|
oldLineInfo.setLineStatus(LineStatusEnum.PUBLIC_SEAS.getCode());
|
||||||
|
oldLineInfo.setInvestmentManager(null);
|
||||||
|
oldLineInfo.setDevelopmentDirector(null);
|
||||||
|
oldLineInfo.setDevelopmentManager(null);
|
||||||
|
oldLineInfo.setDeadline(null);
|
||||||
|
oldLineInfo.setPassReason(null);
|
||||||
|
oldLineInfo.setRejectPublicReason(null);
|
||||||
|
oldLineInfo.setRejectRealReason(null);
|
||||||
|
oldLineInfo.setCertifyFile(null);
|
||||||
|
oldLineInfo.setCloseTime(null);
|
||||||
|
oldLineInfo.setCloseUserId(null);
|
||||||
|
oldLineInfo.setJoinBlackReason(null);
|
||||||
|
oldLineInfo.setRemoveBlackReason(null);
|
||||||
|
oldLineInfo.setUserChannelId(null);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public HyPartnerBaseInfoDO generateBaseInfo(HyPartnerUserInfoDO hyPartnerUserInfoDO, Long partnerLineId, String userPortrait) {
|
public HyPartnerBaseInfoDO generateBaseInfo(HyPartnerUserInfoDO hyPartnerUserInfoDO, Long partnerLineId, String userPortrait) {
|
||||||
HyPartnerBaseInfoDO hyPartnerBaseInfoDO = hyPartnerBaseInfoDAO.getByPartnerIdAndLineId(hyPartnerUserInfoDO.getPartnerId(), partnerLineId);
|
HyPartnerBaseInfoDO hyPartnerBaseInfoDO = hyPartnerBaseInfoDAO.getByPartnerIdAndLineId(hyPartnerUserInfoDO.getPartnerId(), partnerLineId);
|
||||||
|
|||||||
Reference in New Issue
Block a user