|
@@ -195,16 +195,19 @@ public class SceneEditInfoExtServiceImpl extends ServiceImpl<ISceneEditInfoExtMa
|
|
|
@Override
|
|
|
public JSONObject listBillboards(BaseSceneParamVO param) throws Exception {
|
|
|
|
|
|
+ JSONObject result = new JSONObject();
|
|
|
+ List<JSONObject> tags = new ArrayList<>();
|
|
|
+ List<JSONObject> styles = new ArrayList<>();
|
|
|
ScenePlus scenePlus = scenePlusService.getScenePlusByNum(param.getNum());
|
|
|
SceneEditInfoExt sceneEditInfoExt = this.getByScenePlusId(scenePlus.getId());
|
|
|
if(sceneEditInfoExt.getBillboards() == CommonStatus.NO.code().intValue()){
|
|
|
- return null;
|
|
|
+ result.put("tags", tags);
|
|
|
+ result.put("styles", styles);
|
|
|
+ return result;
|
|
|
}
|
|
|
|
|
|
this.syncBillboardsFromFileToRedis(param.getNum());
|
|
|
|
|
|
- JSONObject result = new JSONObject();
|
|
|
-
|
|
|
//获取指示牌数据
|
|
|
String key = String.format(RedisKey.SCENE_BILLBOARDS, param.getNum());
|
|
|
List<String> list = redisUtil.hgetValues(key);
|
|
@@ -217,7 +220,7 @@ public class SceneEditInfoExtServiceImpl extends ServiceImpl<ISceneEditInfoExtMa
|
|
|
return tagBean;
|
|
|
}).collect(Collectors.toList());
|
|
|
sortList.sort(Comparator.comparingLong(TagBean::getCreateTime).reversed());
|
|
|
- List<JSONObject> tags = sortList.stream().map(item -> item.getTag()).collect(Collectors.toList());
|
|
|
+ tags = sortList.stream().map(item -> item.getTag()).collect(Collectors.toList());
|
|
|
result.put("tags", tags);
|
|
|
|
|
|
//获取图标数据
|
|
@@ -233,7 +236,7 @@ public class SceneEditInfoExtServiceImpl extends ServiceImpl<ISceneEditInfoExtMa
|
|
|
return tagBean;
|
|
|
}).collect(Collectors.toList());
|
|
|
sortList.sort(Comparator.comparingLong(TagBean::getCreateTime).reversed());
|
|
|
- List<JSONObject> styles = sortList.stream().map(item -> item.getTag()).collect(Collectors.toList());
|
|
|
+ styles = sortList.stream().map(item -> item.getTag()).collect(Collectors.toList());
|
|
|
result.put("styles", styles);
|
|
|
|
|
|
return result;
|