feat: 实时示功图增加三个字段
This commit is contained in:
+8
-1
@@ -1,14 +1,17 @@
|
|||||||
package com.jero.modules.service.impl;
|
package com.jero.modules.service.impl;
|
||||||
|
|
||||||
|
import cn.hutool.core.date.DateUtil;
|
||||||
import com.jero.modules.entity.KhOilRealtimeData;
|
import com.jero.modules.entity.KhOilRealtimeData;
|
||||||
import com.jero.modules.mapper.KhOilRealtimeDataMapper;
|
import com.jero.modules.mapper.KhOilRealtimeDataMapper;
|
||||||
import com.jero.modules.service.IKhOilRealtimeDataService;
|
import com.jero.modules.service.IKhOilRealtimeDataService;
|
||||||
import com.jero.modules.utils.RandomNumberUtil;
|
import com.jero.modules.utils.RandomNumberUtil;
|
||||||
import io.swagger.models.auth.In;
|
import io.swagger.models.auth.In;
|
||||||
|
import javafx.beans.property.SimpleListProperty;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
import com.jero.common.exception.JeroBootException;
|
import com.jero.common.exception.JeroBootException;
|
||||||
|
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
|
|
||||||
import com.github.javafaker.Faker;
|
import com.github.javafaker.Faker;
|
||||||
@@ -73,7 +76,7 @@ public class KhOilRealtimeDataServiceImpl extends ServiceImpl<KhOilRealtimeDataM
|
|||||||
Map<String, Object> result = new HashMap<>();
|
Map<String, Object> result = new HashMap<>();
|
||||||
khOilRealtimeData.mockKhOilRealtimeData();
|
khOilRealtimeData.mockKhOilRealtimeData();
|
||||||
result.put("油井实时参数", khOilRealtimeData);
|
result.put("油井实时参数", khOilRealtimeData);
|
||||||
Map<String, List<Integer>> chartTwo = new HashMap<>();
|
Map<String, Object> chartTwo = new HashMap<>();
|
||||||
Integer[] arr = {0, 25, 50, 75, 100, 125, 150, 175, 200, 225, 250};
|
Integer[] arr = {0, 25, 50, 75, 100, 125, 150, 175, 200, 225, 250};
|
||||||
List<Integer> chartTwoX = Arrays.asList(arr);
|
List<Integer> chartTwoX = Arrays.asList(arr);
|
||||||
List<Integer> chartTwoUp = RandomNumberUtil.generateFakeDataList(arr.length, Integer.class);
|
List<Integer> chartTwoUp = RandomNumberUtil.generateFakeDataList(arr.length, Integer.class);
|
||||||
@@ -81,6 +84,10 @@ public class KhOilRealtimeDataServiceImpl extends ServiceImpl<KhOilRealtimeDataM
|
|||||||
chartTwo.put("X轴", chartTwoX);
|
chartTwo.put("X轴", chartTwoX);
|
||||||
chartTwo.put("上冲程", chartTwoUp);
|
chartTwo.put("上冲程", chartTwoUp);
|
||||||
chartTwo.put("下冲程", chartTwoDown);
|
chartTwo.put("下冲程", chartTwoDown);
|
||||||
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
||||||
|
chartTwo.put("时间", sdf.format(new Date()));
|
||||||
|
chartTwo.put("冲程", RandomNumberUtil.getRandomDouble());
|
||||||
|
chartTwo.put("冲次", RandomNumberUtil.getRandomDouble());
|
||||||
result.put("实时示功图", chartTwo);
|
result.put("实时示功图", chartTwo);
|
||||||
Map<String, List<?>> chartThree = new HashMap<>();
|
Map<String, List<?>> chartThree = new HashMap<>();
|
||||||
List<String> chartThreeX = RandomNumberUtil.getLast30DaysFormattedDatesAscending();
|
List<String> chartThreeX = RandomNumberUtil.getLast30DaysFormattedDatesAscending();
|
||||||
|
|||||||
Reference in New Issue
Block a user