|
@@ -324,7 +324,7 @@ public class FrontServiceImpl implements FrontServiceI {
|
|
|
return SendUtil.send(true, "", data);
|
|
|
}
|
|
|
|
|
|
- return SendUtil.send(false, "", null);
|
|
|
+ return SendUtil.send(false, obj.getString("data"), null);
|
|
|
}
|
|
|
|
|
|
@Override
|
|
@@ -776,54 +776,42 @@ public class FrontServiceImpl implements FrontServiceI {
|
|
|
return SendUtil.layuiTable(obj.getJSONObject("data").getInteger("count"), obj.getJSONObject("data").getJSONArray("data"));
|
|
|
}
|
|
|
|
|
|
- return SendUtil.send(false, "", null);
|
|
|
+ return SendUtil.send(false, obj.getString("data"), null);
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
- public PagingResponse<Object> getCurrLoginPersonListingList(Map<String, Object> params) {
|
|
|
- String resStr = loadLocalJsonFile("getCurrLoginPersonListingList");
|
|
|
- JSONObject resObj = JSONObject.parseObject(resStr);
|
|
|
-
|
|
|
- // TODO: 2022/3/28 接口地址待定
|
|
|
- // HttpResponse response = HttpUtil.createGet("")
|
|
|
- // .form(params)
|
|
|
- // .execute();
|
|
|
- // JSONObject resObj = JSONObject.parseObject(response.body());
|
|
|
- if (ObjectUtil.isNull(resObj)) {
|
|
|
- return PagingResponse.failed();
|
|
|
+ public Map<String, Object> getCurrLoginPersonListingList(Map<String, Object> params) {
|
|
|
+// String resStr = loadLocalJsonFile("getCurrLoginPersonListingList");
|
|
|
+ String resStr = HttpUtil.get(RemoteUrlConstants.getLoginUserListing(), params);
|
|
|
+ if (Blank.isEmpty(resStr)) {
|
|
|
+ SendUtil.layuiTable(0, null);
|
|
|
}
|
|
|
- if (!"success".equals(resObj.getString("type"))) {
|
|
|
- return PagingResponse.failed();
|
|
|
+
|
|
|
+ logger.info("getCurrLoginPersonListingList response body: {}", resStr);
|
|
|
+ JSONObject obj = JSONObject.parseObject(resStr);
|
|
|
+ if (StrUtil.equals(obj.getString("type"), "success", true)) {
|
|
|
+ JSONObject data = obj.getJSONObject("data");
|
|
|
+ SendUtil.layuiTable(data.getInteger("count"), data.getJSONArray("houseList"));
|
|
|
}
|
|
|
- JSONObject data = resObj.getJSONObject("data");
|
|
|
- int count = data.getIntValue("count");
|
|
|
- JSONArray jsonArr = data.getJSONArray("data");
|
|
|
- logger.info("response body: {}", resObj.toJSONString());
|
|
|
- return PagingResponse.success(count, jsonArr.toJavaList(Object.class));
|
|
|
+
|
|
|
+ return SendUtil.layuiTable(0, null);
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
- public PagingResponse<Object> getCompanyStoreInfoListById(Map<String, Object> params) {
|
|
|
-// String resStr = "{\"data\":{\"data\":[{\"DWQCH\":\"重庆链家房产经纪有限公司\",\"updateTime\":\"2022-03-24\",\"FYSL\":15}],\"count\":1},\"type\":\"success\",\"uuid\":\"0020a364a5014dd384716b76802de110\"}";
|
|
|
- String resStr = loadLocalJsonFile("getCompanyStoreInfoListById");
|
|
|
- JSONObject resObj = JSONObject.parseObject(resStr);
|
|
|
-
|
|
|
- // TODO: 2022/3/28 接口地址待定
|
|
|
- // HttpResponse response = HttpUtil.createGet("")
|
|
|
- // .form(params)
|
|
|
- // .execute();
|
|
|
- // JSONObject resObj = JSONObject.parseObject(response.body());
|
|
|
- if (ObjectUtil.isNull(resObj)) {
|
|
|
- return PagingResponse.failed();
|
|
|
+ public Map<String, Object> getCompanyStoreInfoListById(Map<String, Object> params) {
|
|
|
+// String resStr = loadLocalJsonFile("getCompanyStoreInfoListById");
|
|
|
+ String resStr = HttpUtil.get(RemoteUrlConstants.getStores(), params);
|
|
|
+ if (Blank.isEmpty(resStr)) {
|
|
|
+ return SendUtil.layuiTable(0, null);
|
|
|
}
|
|
|
- if (!"success".equals(resObj.getString("type"))) {
|
|
|
- return PagingResponse.failed();
|
|
|
+
|
|
|
+ logger.info("getCompanyStoreInfoListById response body: {}", resStr);
|
|
|
+ JSONObject obj = JSONObject.parseObject(resStr);
|
|
|
+ if (StrUtil.equals(obj.getString("type"), "success", true)) {
|
|
|
+ JSONObject data = obj.getJSONObject("data");
|
|
|
+ return SendUtil.layuiTable(data.getInteger("count"), data.getJSONObject("data"));
|
|
|
}
|
|
|
- JSONObject data = resObj.getJSONObject("data");
|
|
|
- int count = data.getIntValue("count");
|
|
|
- JSONArray jsonArr = data.getJSONArray("data");
|
|
|
- logger.info("response body: {}", resObj.toJSONString());
|
|
|
- return PagingResponse.success(count, jsonArr.toJavaList(Object.class));
|
|
|
+ return SendUtil.layuiTable(0, null);
|
|
|
}
|
|
|
|
|
|
@Override
|