|
@@ -13,6 +13,7 @@ import javax.validation.constraints.DecimalMin;
|
|
|
import javax.validation.constraints.Max;
|
|
import javax.validation.constraints.Max;
|
|
|
import javax.validation.constraints.Min;
|
|
import javax.validation.constraints.Min;
|
|
|
import java.math.BigDecimal;
|
|
import java.math.BigDecimal;
|
|
|
|
|
+import java.util.Optional;
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* @author lifang
|
|
* @author lifang
|
|
@@ -146,4 +147,19 @@ public class DeviceProperties<K,T> extends TenantGenericEntity<K,T> {
|
|
|
|
|
|
|
|
@ApiModelProperty(value = "公共参数-电量",accessMode = ApiModelProperty.AccessMode.READ_ONLY)
|
|
@ApiModelProperty(value = "公共参数-电量",accessMode = ApiModelProperty.AccessMode.READ_ONLY)
|
|
|
private Integer electricQuantity;
|
|
private Integer electricQuantity;
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ public Integer getPcaTotalCount() {
|
|
|
|
|
+ return getPcaInvalidCount()+getPcaValidCount();
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ public Integer getPcaValidCount() {
|
|
|
|
|
+ return Optional.ofNullable(pcaValidCount).orElse(0);
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ public Integer getPcaInvalidCount() {
|
|
|
|
|
+ return Optional.ofNullable(pcaInvalidCount).orElse(0);
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|