|
@@ -1,12 +1,5 @@
|
|
|
package com.sooka.jnb.information.service.impl;
|
|
|
|
|
|
-import java.util.ArrayList;
|
|
|
-import java.util.Arrays;
|
|
|
-import java.util.List;
|
|
|
-import java.util.stream.Collectors;
|
|
|
-
|
|
|
-import com.github.pagehelper.Page;
|
|
|
-import com.ruoyi.common.core.page.TableDataInfo;
|
|
|
import com.ruoyi.common.utils.DateUtils;
|
|
|
import com.ruoyi.common.utils.SecurityUtils;
|
|
|
import com.sooka.jnb.highServer.domain.JnbHighServerImg;
|
|
@@ -21,6 +14,11 @@ import org.springframework.stereotype.Service;
|
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
|
import org.springframework.util.ObjectUtils;
|
|
|
|
|
|
+import java.util.ArrayList;
|
|
|
+import java.util.Arrays;
|
|
|
+import java.util.List;
|
|
|
+import java.util.stream.Collectors;
|
|
|
+
|
|
|
/**
|
|
|
* 高频服务Service业务层处理
|
|
|
*
|
|
@@ -69,21 +67,22 @@ public class InformationServiceImpl implements InformationService
|
|
|
}).collect(Collectors.toList());
|
|
|
}
|
|
|
@Override
|
|
|
- public TableDataInfo selectInformationListWxs(Information information, Integer pageNum, Integer pageSize)
|
|
|
+ public List<Information> selectInformationListWxs(Information information)
|
|
|
{
|
|
|
-// List<Information> result = informationMapper.selectInformationListWxs(information,pageNum, pageSize);
|
|
|
- System.out.println(information.getIsTop());
|
|
|
- List<Information> toolForAbsenteeism = informationMapper.selectInformationListWxs(information,pageNum, pageSize);
|
|
|
- TableDataInfo tableDataInfo = new TableDataInfo();
|
|
|
- tableDataInfo.setRows(toolForAbsenteeism.stream() .skip((long) (pageNum - 1) * pageSize)
|
|
|
- .limit(pageSize)
|
|
|
- .collect(Collectors.toList()));
|
|
|
- tableDataInfo.setTotal(toolForAbsenteeism.size());
|
|
|
- tableDataInfo.setCode(200);
|
|
|
- tableDataInfo.setMsg("查询成功");
|
|
|
- return tableDataInfo;
|
|
|
+ List<Information> list = informationMapper.selectInformationListWxs(information);
|
|
|
+ for (Information information1 : list) {
|
|
|
+ if (information1.getImgUrlList()!=null){
|
|
|
+ String[] split = information1.getImgUrlList().split(",");
|
|
|
+ information1.setUrls(Arrays.asList(split));
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ information1.setUrls(new ArrayList<>(0));
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return list;
|
|
|
}
|
|
|
|
|
|
+
|
|
|
@Override
|
|
|
public int likeById(Information information) {
|
|
|
return informationMapper.updateInformationLike(information);
|