线索规则
This commit is contained in:
@@ -130,6 +130,14 @@ public interface HyPartnerLineInfoService {
|
||||
*/
|
||||
Boolean assignFollowUser(Long lineId);
|
||||
|
||||
/**
|
||||
* 线索状态
|
||||
* @param wantShopAreaId
|
||||
* @param acceptAdjustType
|
||||
* @return
|
||||
*/
|
||||
Boolean getLineStatus(Long wantShopAreaId,Integer acceptAdjustType);
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -395,21 +395,34 @@ public class HyPartnerLineInfoServiceImpl implements HyPartnerLineInfoService {
|
||||
return Boolean.FALSE;
|
||||
}
|
||||
HyPartnerUserInfoDO hyPartnerUserInfoDO = hyPartnerUserInfoDAO.selectByPartnerId(hyPartnerLineInfoDO.getPartnerId());
|
||||
HyOpenAreaInfoDO hyOpenAreaInfoDO = hyOpenAreaInfoDAO.selectById(Long.valueOf(hyPartnerUserInfoDO.getWantShopArea()));
|
||||
|
||||
Boolean lineStatus = getLineStatus(Long.valueOf(hyPartnerUserInfoDO.getWantShopArea()), hyPartnerUserInfoDO.getAcceptAdjustType());
|
||||
return lineStatus;
|
||||
}
|
||||
|
||||
/**
|
||||
* 线索状态
|
||||
* @param wantShopAreaId
|
||||
* @param acceptAdjustType
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public Boolean getLineStatus(Long wantShopAreaId,Integer acceptAdjustType){
|
||||
HyOpenAreaInfoDO hyOpenAreaInfoDO = hyOpenAreaInfoDAO.selectById(wantShopAreaId);
|
||||
|
||||
if (AreaStatusEnum.OPEN.getCode().equals(hyOpenAreaInfoDO.getAreaStatus()) || AreaStatusEnum.KEY_OPEN.getCode().equals(hyOpenAreaInfoDO.getAreaStatus())){
|
||||
return Boolean.TRUE;
|
||||
}
|
||||
if (AreaStatusEnum.NOT_OPEN.getCode().equals(hyOpenAreaInfoDO.getAreaStatus()) || AreaStatusEnum.SATURATED.getCode().equals(hyOpenAreaInfoDO.getAreaStatus())){
|
||||
if (AcceptAdjustTypeEnum.NOT_ACCEPT.getCode().equals(hyPartnerUserInfoDO.getAcceptAdjustType())){
|
||||
if (AcceptAdjustTypeEnum.NOT_ACCEPT.getCode().equals(acceptAdjustType)){
|
||||
return Boolean.FALSE;
|
||||
}
|
||||
//全国调剂 默认分配呗 有啥好说的
|
||||
if (AcceptAdjustTypeEnum.NATIONAL_ADJUSTMENT.getCode().equals(hyPartnerUserInfoDO.getAcceptAdjustType())){
|
||||
if (AcceptAdjustTypeEnum.NATIONAL_ADJUSTMENT.getCode().equals(acceptAdjustType)){
|
||||
return Boolean.TRUE;
|
||||
}
|
||||
//省内调剂 有重点或者开放的 分配
|
||||
if (AcceptAdjustTypeEnum.PROVINCIAL_ADJUSTMENT.getCode().equals(hyPartnerUserInfoDO.getAcceptAdjustType())){
|
||||
if (AcceptAdjustTypeEnum.PROVINCIAL_ADJUSTMENT.getCode().equals(acceptAdjustType)){
|
||||
Integer apply = hyOpenAreaInfoDAO.getChildrenCount("apply", hyOpenAreaInfoDO.getId());
|
||||
if (apply>CommonConstants.ZERO){
|
||||
return Boolean.TRUE;
|
||||
@@ -417,7 +430,7 @@ public class HyPartnerLineInfoServiceImpl implements HyPartnerLineInfoService {
|
||||
return Boolean.FALSE;
|
||||
}
|
||||
//市内调剂 不分配
|
||||
if (AcceptAdjustTypeEnum.LOCAL_ADJUSTMENT.getCode().equals(hyPartnerUserInfoDO.getAcceptAdjustType())){
|
||||
if (AcceptAdjustTypeEnum.LOCAL_ADJUSTMENT.getCode().equals(acceptAdjustType)){
|
||||
return Boolean.FALSE;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user