|
|
|
@ -47,9 +47,9 @@ public class GatewayController {
|
|
|
|
|
JSONObject requestBody = JSONObject.parseObject(format);
|
|
|
|
|
JSONObject responseBody = IotUtils.postApi(IotApiEnum.getPathByText("向设备发送方法"), requestBody);
|
|
|
|
|
JSONObject data = requestBody.getJSONObject("data");
|
|
|
|
|
if (!data.isEmpty()) {
|
|
|
|
|
if (data!=null) {
|
|
|
|
|
JSONObject outputData = data.getJSONObject("outputData");
|
|
|
|
|
if (!outputData.isEmpty()) {
|
|
|
|
|
if (outputData!=null) {
|
|
|
|
|
List<JSONObject> list = outputData.getJSONArray("list").toJavaList(JSONObject.class);
|
|
|
|
|
List<JSONObject> subList = list.stream().skip((long) (pageNum - 1) * pageSize).limit(pageSize).collect(Collectors.toList());
|
|
|
|
|
outputData.put("list",subList);
|
|
|
|
|