|
|
@ -24,6 +24,8 @@ import com.elink.esua.epdc.commons.tools.constant.FieldConstant; |
|
|
|
import com.elink.esua.epdc.commons.tools.constant.NumConstant; |
|
|
|
import com.elink.esua.epdc.commons.tools.constant.StrConstant; |
|
|
|
import com.elink.esua.epdc.commons.tools.page.PageData; |
|
|
|
import com.elink.esua.epdc.commons.tools.security.user.SecurityUser; |
|
|
|
import com.elink.esua.epdc.commons.tools.security.user.UserDetail; |
|
|
|
import com.elink.esua.epdc.commons.tools.utils.ConvertUtils; |
|
|
|
import com.elink.esua.epdc.commons.tools.utils.Result; |
|
|
|
import com.elink.esua.epdc.constant.ImageConstant; |
|
|
@ -69,6 +71,7 @@ public class SuggestionMakeServiceImpl extends BaseServiceImpl<SuggestionMakeDao |
|
|
|
|
|
|
|
@Override |
|
|
|
public PageData<SuggestionMakeDTO> page(Map<String, Object> params) { |
|
|
|
params.put("deptIdList", SecurityUser.getUser().getDeptIdList()); |
|
|
|
IPage<SuggestionMakeDTO> page = getPage(params); |
|
|
|
List<SuggestionMakeDTO> list = baseDao.selectListPage(params); |
|
|
|
return new PageData<>(list, page.getTotal()); |
|
|
@ -95,12 +98,10 @@ public class SuggestionMakeServiceImpl extends BaseServiceImpl<SuggestionMakeDao |
|
|
|
SuggestionMakeDTO result = baseDao.selectDetailById(id); |
|
|
|
// 查询建议图片URL
|
|
|
|
String[] urls = customImgDao.selectListImgUrlsByIds(result.getId()); |
|
|
|
List<Map<String, String>> suggestionPicList = new ArrayList<>(); |
|
|
|
List<String> suggestionPicList = new ArrayList<>(); |
|
|
|
for (int i = 0; i < urls.length; i++) { |
|
|
|
Map<String, String> map = new HashMap<>(); |
|
|
|
map.put("name", i + ""); |
|
|
|
map.put("url", urls[i]); |
|
|
|
suggestionPicList.add(map); |
|
|
|
suggestionPicList.add(urls[i]); |
|
|
|
} |
|
|
|
result.setSuggestionPicList(suggestionPicList); |
|
|
|
return result; |
|
|
|