|
|
@@ -196,9 +196,10 @@ public class HuiCunServiceImpl implements HuiCunService {
|
|
|
requestParam.put("nonce", UUID.randomUUID().toString());
|
|
|
requestParam.put("timestamp", System.currentTimeMillis());
|
|
|
Map<String, Object> responseData = getMap(requestParam, POINT_RANK_DATA);
|
|
|
+ System.out.println(responseData);
|
|
|
if (responseData.get("code").equals(200)) {
|
|
|
Object data = responseData.get("data");
|
|
|
- if ( data instanceof JSONObject) {
|
|
|
+ if ( data instanceof JSONArray) {
|
|
|
List<JSONObject> dataStr = (List<JSONObject>) responseData.get("data");
|
|
|
return success(dataStr);
|
|
|
}
|
|
|
@@ -236,10 +237,10 @@ public class HuiCunServiceImpl implements HuiCunService {
|
|
|
requestParam.put("nonce", UUID.randomUUID().toString());
|
|
|
requestParam.put("timestamp", System.currentTimeMillis());
|
|
|
Map<String, Object> responseData = getMap(requestParam, VILLAGE_NEWS_DATA);
|
|
|
+ System.out.println(responseData);
|
|
|
if (responseData.get("code").equals(200)) {
|
|
|
Object data = responseData.get("data");
|
|
|
- if ( data instanceof JSONObject) {
|
|
|
- System.out.println(responseData);
|
|
|
+ if ( data instanceof JSONArray) {
|
|
|
// List<VillageNewsDataDto> dataStr = (List<VillageNewsDataDto>) responseData.get("data");
|
|
|
List<VillageNewsDataDto> dataStr = JSONUtil.toList((JSONArray) responseData.get("data"), VillageNewsDataDto.class
|
|
|
);
|