Commit e137445f by 陶光胜

Merge branch 'developer' into 'master'

判空

See merge request !32
parents d4127ef0 70b6cca8
......@@ -120,6 +120,12 @@ public class GoDownComponent {
Integer wgs = storeSearchUtils.isWgs(params.getUserId(), params.getEnterpriseId(), params.getSearchJson());
/**所有渠道或者线下渠道第一层级 合计算上无归属数据**/
if((params.getChannel() == null || (params.getChannel() == StoreChannelEnum.OFFLINE.getChannel() && params.getLevel() == levelVo.getLevel())) && wgs == 1){
if (CollectionUtils.isEmpty(params.getStoreInfoIdList())) {
params.setStoreInfoIdList(new ArrayList<>());
}
if (CollectionUtils.isEmpty(params.getOnlineStoreIdList())) {
params.setOnlineStoreIdList(new ArrayList<>());
}
params.getStoreInfoIdList().add(-1);
params.getOnlineStoreIdList().add("-1");
}
......@@ -129,6 +135,12 @@ public class GoDownComponent {
Integer wgs = storeSearchUtils.isWgs(params.getUserId(), params.getEnterpriseId(), params.getSearchJson());
/**所有渠道或者线下渠道第一层级 合计算上无归属数据**/
if(wgs == 1){
if (CollectionUtils.isEmpty(params.getStoreInfoIdList())) {
params.setStoreInfoIdList(new ArrayList<>());
}
if (CollectionUtils.isEmpty(params.getOnlineStoreIdList())) {
params.setOnlineStoreIdList(new ArrayList<>());
}
params.getStoreInfoIdList().add(-1);
params.getOnlineStoreIdList().add("-1");
}
......@@ -138,6 +150,12 @@ public class GoDownComponent {
Integer wgs = storeSearchUtils.isWgs(params.getUserId(), params.getEnterpriseId(), params.getSearchJson());
if(params.getChannel() != null && params.getChannel() == 1 && params.getLevel() == levelVo.getLevel() && wgs == 1){
params.setChannel(null);
if (CollectionUtils.isEmpty(params.getStoreInfoIdList())) {
params.setStoreInfoIdList(new ArrayList<>());
}
if (CollectionUtils.isEmpty(params.getOnlineStoreIdList())) {
params.setOnlineStoreIdList(new ArrayList<>());
}
params.getStoreInfoIdList().clear();
params.getOnlineStoreIdList().clear();
params.getStoreInfoIdList().add(-1);
......@@ -149,6 +167,12 @@ public class GoDownComponent {
Integer wgs = storeSearchUtils.isWgs(params.getUserId(), params.getEnterpriseId(), params.getSearchJson());
if(wgs == 1){
params.setChannel(null);
if (CollectionUtils.isEmpty(params.getStoreInfoIdList())) {
params.setStoreInfoIdList(new ArrayList<>());
}
if (CollectionUtils.isEmpty(params.getOnlineStoreIdList())) {
params.setOnlineStoreIdList(new ArrayList<>());
}
params.getStoreInfoIdList().clear();
params.getOnlineStoreIdList().clear();
params.getStoreInfoIdList().add(-1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment