Kaynağa Gözat

功图绘制数据接口,冲次改为从功图自身记录获取

chenwen 1 yıl önce
ebeveyn
işleme
30a1ba4a1a

+ 5 - 5
src/main/java/com/hb/proj/data/controller/DiagramDataController.java

@@ -16,9 +16,8 @@ import com.hb.proj.base.service.WellParamService;
 import com.hb.proj.base.service.WellService;
 import com.hb.proj.constant.SortCodeConstant;
 import com.hb.proj.data.service.DiagramDataService;
-import com.hb.proj.data.service.ParamDataService;
-import com.hb.proj.model.SingleDataVO;
 import com.hb.proj.model.MultiDataVO;
+import com.hb.proj.model.SingleDataVO;
 import com.hb.proj.model.WellParamPO;
 import com.hb.proj.model.WellVO;
 import com.hb.proj.utils.RespVO;
@@ -43,8 +42,6 @@ public class DiagramDataController {
 	@Autowired
 	private DiagramDataService  diagramService;
 	
-	@Autowired
-	private ParamDataService   paramDataService;
 	
 	/**
 	 * 分页查询图形基本数据
@@ -99,9 +96,12 @@ public class DiagramDataController {
 		}
 		DataTransUtils.convert(wparam,diagram);
 		
+		//获取冲次,功图记录已存有冲次直接使用2023.10.10
 		WellVO well=wellService.get(wellId);
 		WellParamPO  freqParam=wpService.get(wellId, SortCodeConstant.PARAM_FREQ);
-		SingleDataVO freqPO=paramDataService.getRefFreq(freqParam.getParamId(), diagram.getGatherTime());
+		//SingleDataVO freqPO=paramDataService.getRefFreq(freqParam.getParamId(), diagram.getGatherTime());
+		SingleDataVO freqPO=new SingleDataVO();
+		freqPO.setDataVal(diagram.getFreq());
 		DataTransUtils.convert(freqParam, freqPO);
 		String freqDesc=freqPO!=null?(freqPO.getDispDataVal()+freqParam.getDisplayUnit()):"";
 		

+ 2 - 1
src/main/java/com/hb/proj/data/service/DiagramDataService.java

@@ -43,7 +43,8 @@ public class DiagramDataService {
 	
 	public MultiDataVO   get(String paramId,Date gatherTime) {
 		String sql="""
-					select well_param,gather_time,data_val1,data_val2 from tzl_gather_data_multi 
+					select well_param,gather_time,data_val1,data_val2,freq 
+					from tzl_gather_data_multi 
 					where well_param=?  and gather_time=?  
 					limit 1
 				""";

+ 5 - 0
src/main/java/com/hb/proj/model/MultiDataVO.java

@@ -20,4 +20,9 @@ public class MultiDataVO {
 	
 	private List<Double> serial2;
 	
+	/**
+	 * 冲次
+	 */
+	private Double freq;
+	
 }