Commit bf78ec83 authored by 胡定国's avatar 胡定国

策略排序

parent 4717a79d
...@@ -545,12 +545,13 @@ public class ProductPrivateServiceImpl implements ProductPrivateService, Constan ...@@ -545,12 +545,13 @@ public class ProductPrivateServiceImpl implements ProductPrivateService, Constan
} }
// 排除白名单相关策略 // 排除白名单相关策略
List<String> excludeCodes = Lists.newArrayList("9010", "9020", "9030", "9040", "9050", "7030"); List<String> excludeCodes = Lists.newArrayList("9010", "9020", "9030", "9040", "9050", "7030");
return resp.attributes.stream().filter(v -> !excludeCodes.contains(v.getConstantCode())).map(item -> { return resp.attributes.stream().sorted(Comparator.comparing(SysConstantResp::getConstantCode))
SysConstantVO vo = new SysConstantVO(); .filter(v -> !excludeCodes.contains(v.getConstantCode())).map(item -> {
vo.setConstantCode(item.getConstantCode()); SysConstantVO vo = new SysConstantVO();
vo.setConstantName(item.getConstantName()); vo.setConstantCode(item.getConstantCode());
vo.setConstantValue(item.getConstantValue()); vo.setConstantName(item.getConstantName());
return vo; vo.setConstantValue(item.getConstantValue());
}).collect(Collectors.toList()); return vo;
}).collect(Collectors.toList());
} }
} }
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