|
|
@@ -5,6 +5,7 @@ import lombok.AllArgsConstructor;
|
|
|
import lombok.Data;
|
|
|
|
|
|
import java.math.BigDecimal;
|
|
|
+import java.util.Date;
|
|
|
|
|
|
/**
|
|
|
* @Author 龙三郎
|
|
|
@@ -15,6 +16,7 @@ import java.math.BigDecimal;
|
|
|
@AllArgsConstructor
|
|
|
public class Items {
|
|
|
public static final String VALUE = "value";
|
|
|
+ public static final String TIME = "time";
|
|
|
|
|
|
private JSONObject items;
|
|
|
|
|
|
@@ -26,6 +28,11 @@ public class Items {
|
|
|
return items.getJSONObject(param.getParam()).getInteger(VALUE);
|
|
|
}
|
|
|
|
|
|
+ public Date getDate(){
|
|
|
+ long time = items.getJSONObject(PumpParams.patientCode.getParam()).getLong(TIME);
|
|
|
+ return new Date(time);
|
|
|
+ }
|
|
|
+
|
|
|
public BigDecimal getBigDecimal(PumpParams param){
|
|
|
return items.getJSONObject(param.getParam()).getBigDecimal(VALUE);
|
|
|
}
|