zoujiajian 2 jaren geleden
bovenliggende
commit
10e8c6f656

+ 2 - 0
netflix-dao/src/main/java/com/cyksj/model/dto/CorpFollowServiceDto.java

@@ -18,4 +18,6 @@ public class CorpFollowServiceDto {
 	private Integer indx;
 
 	private String followId;
+
+	private String img;
 }

+ 7 - 9
netflix-web/src/main/java/com/cyksj/web/controller/manage/corp/CorpCustomerAcquistionLinkController.java

@@ -92,35 +92,33 @@ public class CorpCustomerAcquistionLinkController {
     public Result<SearchResult<CorpCustomerAcquisitionLink>> get() throws Exception {
         SearchResult<CorpCustomerAcquisitionLink> search = beanSearcher.search(CorpCustomerAcquisitionLink.class, MapUtils.flatBuilder(request.getParameterMap()).build());
 
-        SysConfig config = sysConfigService.getOne(Wrappers.lambdaQuery(SysConfig.class)
-                .eq(SysConfig::getSysKey, Constant.serviceKeys.get(1)).last("limit 1"));
-        List<CorpFollowServiceDto> corpFollowServiceDtos = Jsons.parseList(config.getSysValue(), CorpFollowServiceDto.class);
+        List<SysCorpFollowRelate> corpFollowServiceDtos = beanSearcher.searchAll(SysCorpFollowRelate.class, MapUtils.builder().build());
 
-        search.getDataList().forEach(e->{
+        search.getDataList().forEach(e -> {
             try {
                 List<String> userStrList = corpFollowServiceDtos.stream().filter(cf -> {
                     try {
-                        return Jsons.parseList(e.getUserList(), Integer.class).contains(cf.getIndx());
+                        return Jsons.parseList(e.getUserList(), Integer.class).contains(cf.getId());
                     } catch (Exception ex) {
                     }
                     return false;
-                }).map(CorpFollowServiceDto::getName).collect(Collectors.toList());
+                }).map(SysCorpFollowRelate::getName).collect(Collectors.toList());
                 e.setUserStrList(userStrList);
 
                 if (StrUtil.isNotEmpty(e.getChooseDutyUsers())) {
                     List<String> dutyUserList = corpFollowServiceDtos.stream().filter(cf -> {
                         try {
-                            return Jsons.parseList(e.getChooseDutyUsers(), Integer.class).contains(cf.getIndx());
+                            return Jsons.parseList(e.getChooseDutyUsers(), Integer.class).contains(cf.getId());
                         } catch (Exception ex) {
                         }
                         return false;
-                    }).map(CorpFollowServiceDto::getName).collect(Collectors.toList());
+                    }).map(SysCorpFollowRelate::getName).collect(Collectors.toList());
 
                     e.setChooseDutyUserList(dutyUserList);
                 }
 
                 List<String> tagStrList = corpTagMapper.selectList(Wrappers.lambdaQuery(CorpTag.class)
-                        .in(CorpTag::getId, Jsons.parseList(e.getTags(),Long.class))).stream().map(CorpTag::getName).collect(Collectors.toList());
+                        .in(CorpTag::getId, Jsons.parseList(e.getTags(), Long.class))).stream().map(CorpTag::getName).collect(Collectors.toList());
                 e.setTagStrList(tagStrList);
             } catch (Exception ex) {
             }