mirror of
https://gitee.com/likeadmin/likeadmin_java.git
synced 2026-09-06 23:01:08 +08:00
feat 初始化menu 默认开启caache
fix 修复绑定手机的提示错误显示的bug fix 装修移动端没有正确显示图片的bug
This commit is contained in:
@@ -76,6 +76,32 @@ public class IndexServiceImpl implements IIndexService {
|
||||
articleList.add(map);
|
||||
}
|
||||
|
||||
String data = decoratePage.getData();
|
||||
JSONArray dataArray = JSONArray.parseArray(data);
|
||||
for (int i = 0; i < dataArray.size() ; i++) {
|
||||
JSONObject dataJson = dataArray.getJSONObject(i);
|
||||
JSONArray tempArray = dataJson.getJSONObject("content").getJSONArray("data");
|
||||
if (StringUtils.isNull(tempArray)) {
|
||||
JSONObject tempJSON = dataJson.getJSONObject("content");
|
||||
if (StringUtils.isNull(tempJSON)) {
|
||||
continue;
|
||||
} else {
|
||||
if (StringUtils.isNotNull(tempJSON.getString("image"))) {
|
||||
tempJSON.put("image", UrlUtils.toAbsoluteUrl(tempJSON.getString("image")));
|
||||
}
|
||||
if (StringUtils.isNotNull(tempJSON.getString("qrcode"))) {
|
||||
tempJSON.put("qrcode", UrlUtils.toAbsoluteUrl(tempJSON.getString("qrcode")));
|
||||
}
|
||||
}
|
||||
} else {
|
||||
for (int j = 0; j < tempArray.size(); j++) {
|
||||
JSONObject tempImageJson = tempArray.getJSONObject(j);
|
||||
tempImageJson.put("image", UrlUtils.toAbsoluteUrl(tempImageJson.getString("image")));
|
||||
}
|
||||
}
|
||||
}
|
||||
decoratePage.setData(dataArray.toJSONString());
|
||||
|
||||
response.put("domain", UrlUtils.domain());
|
||||
response.put("page", decoratePage);
|
||||
response.put("article", articleList);
|
||||
@@ -98,6 +124,34 @@ public class IndexServiceImpl implements IIndexService {
|
||||
|
||||
Assert.notNull(decoratePage, "数据不存在!");
|
||||
|
||||
String data = decoratePage.getData();
|
||||
if (StringUtils.isJsonArrayString(data)) {
|
||||
JSONArray dataArray = JSONArray.parseArray(data);
|
||||
for (int i = 0; i < dataArray.size(); i++) {
|
||||
JSONObject dataJson = dataArray.getJSONObject(i);
|
||||
JSONArray tempArray = dataJson.getJSONObject("content").getJSONArray("data");
|
||||
if (StringUtils.isNull(tempArray)) {
|
||||
JSONObject tempJSON = dataJson.getJSONObject("content");
|
||||
if (StringUtils.isNull(tempJSON)) {
|
||||
continue;
|
||||
} else {
|
||||
if (StringUtils.isNotNull(tempJSON.getString("image"))) {
|
||||
tempJSON.put("image", UrlUtils.toAbsoluteUrl(tempJSON.getString("image")));
|
||||
}
|
||||
if (StringUtils.isNotNull(tempJSON.getString("qrcode"))) {
|
||||
tempJSON.put("qrcode", UrlUtils.toAbsoluteUrl(tempJSON.getString("qrcode")));
|
||||
}
|
||||
}
|
||||
} else {
|
||||
for (int j = 0; j < tempArray.size(); j++) {
|
||||
JSONObject tempImageJson = tempArray.getJSONObject(j);
|
||||
tempImageJson.put("image", UrlUtils.toAbsoluteUrl(tempImageJson.getString("image")));
|
||||
}
|
||||
}
|
||||
}
|
||||
decoratePage.setData(dataArray.toJSONString());
|
||||
}
|
||||
|
||||
Map<String, Object> response = new LinkedHashMap<>();
|
||||
response.put("type", decoratePage.getType());
|
||||
response.put("name", decoratePage.getName());
|
||||
|
||||
@@ -450,6 +450,7 @@ public class LoginServiceImpl implements ILoginService {
|
||||
vo.setIsBindMobile(!StringUtils.isEmpty(mobile));
|
||||
vo.setToken(StpUtil.getTokenValue());
|
||||
vo.setIsNew(isNew);
|
||||
vo.setMobile(mobile);
|
||||
|
||||
//保存登录信息到session
|
||||
userSessionMapper.delete(new QueryWrapper<UserSession>().eq("user_id", userId).eq("terminal", terminal));
|
||||
|
||||
@@ -123,11 +123,24 @@ public class PcServiceImpI implements IPcService {
|
||||
for (int i = 0; i < dataArray.size() ; i++) {
|
||||
JSONObject dataJson = dataArray.getJSONObject(i);
|
||||
JSONArray tempArray = dataJson.getJSONObject("content").getJSONArray("data");
|
||||
for (int j = 0; j < tempArray.size() ; j++) {
|
||||
JSONObject tempImageJson = tempArray.getJSONObject(j);
|
||||
|
||||
tempImageJson.put("image", UrlUtils.toAbsoluteUrl(tempImageJson.getString("image")));
|
||||
if (StringUtils.isNull(tempArray)) {
|
||||
|
||||
JSONObject tempJSON = dataJson.getJSONObject("content");
|
||||
if (StringUtils.isNull(tempJSON)) {
|
||||
continue;
|
||||
} else {
|
||||
if (StringUtils.isNotNull(tempJSON.getString("image"))) {
|
||||
tempJSON.put("image", UrlUtils.toAbsoluteUrl(tempJSON.getString("image")));
|
||||
}
|
||||
if (StringUtils.isNotNull(tempJSON.getString("qrcode"))) {
|
||||
tempJSON.put("qrcode", UrlUtils.toAbsoluteUrl(tempJSON.getString("qrcode")));
|
||||
}
|
||||
}
|
||||
} else {
|
||||
for (int j = 0; j < tempArray.size(); j++) {
|
||||
JSONObject tempImageJson = tempArray.getJSONObject(j);
|
||||
tempImageJson.put("image", UrlUtils.toAbsoluteUrl(tempImageJson.getString("image")));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -18,6 +18,9 @@ public class LoginTokenVo implements Serializable {
|
||||
@ApiModelProperty(value = "绑定手机")
|
||||
private Boolean isBindMobile;
|
||||
|
||||
@ApiModelProperty(value = "绑定手机")
|
||||
private String mobile;
|
||||
|
||||
@ApiModelProperty(value = "登录令牌")
|
||||
private String token;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user