kangwei:设备运行台时问题修改
正在显示
3 个修改的文件
包含
16 行增加
和
9 行删除
... | @@ -27,6 +27,10 @@ public class JSUtils { | ... | @@ -27,6 +27,10 @@ public class JSUtils { |
27 | String expression = obj1+ "-" + obj2; | 27 | String expression = obj1+ "-" + obj2; |
28 | return executeExpression(expression,"0.00"); | 28 | return executeExpression(expression,"0.00"); |
29 | } | 29 | } |
30 | public static String subtract(Object obj1 , Object obj2,Object obj3){ | ||
31 | String expression = obj1+ "-" + obj2 + "-" + obj3 ; | ||
32 | return executeExpression(expression,"0.00"); | ||
33 | } | ||
30 | public static String multiply(Object obj1 , Object obj2){ | 34 | public static String multiply(Object obj1 , Object obj2){ |
31 | String expression = obj1+ "*" + obj2; | 35 | String expression = obj1+ "*" + obj2; |
32 | return executeExpression(expression,"0.00"); | 36 | return executeExpression(expression,"0.00"); | ... | ... |
1 | package com.skua.modules.algorithm.vo; | 1 | package com.skua.modules.algorithm.vo; |
2 | 2 | ||
3 | import com.skua.core.util.ConvertUtils; | ||
4 | import com.skua.tool.util.JSUtils; | ||
3 | import io.swagger.annotations.ApiModel; | 5 | import io.swagger.annotations.ApiModel; |
4 | import io.swagger.annotations.ApiModelProperty; | 6 | import io.swagger.annotations.ApiModelProperty; |
5 | import lombok.Data; | 7 | import lombok.Data; |
8 | import netscape.javascript.JSUtil; | ||
6 | 9 | ||
7 | @Data | 10 | @Data |
8 | @ApiModel(value="指挥中心:运行负荷率分析:处理水量详情", description="指挥中心:运行负荷率分析:处理水量详情)") | 11 | @ApiModel(value="指挥中心:运行负荷率分析:处理水量详情", description="指挥中心:运行负荷率分析:处理水量详情)") |
... | @@ -25,35 +28,35 @@ public class WaterTreatmentVO { | ... | @@ -25,35 +28,35 @@ public class WaterTreatmentVO { |
25 | private Double dayCsl; | 28 | private Double dayCsl; |
26 | 29 | ||
27 | @ApiModelProperty(value = "环比:处理水量比例") | 30 | @ApiModelProperty(value = "环比:处理水量比例") |
28 | private Double hbcslbl; | 31 | private String hbcslbl; |
29 | @ApiModelProperty(value = "同比:处理水量比例") | 32 | @ApiModelProperty(value = "同比:处理水量比例") |
30 | private Double tbcslbl; | 33 | private String tbcslbl; |
31 | 34 | ||
32 | @ApiModelProperty(value = "负荷率") | 35 | @ApiModelProperty(value = "负荷率") |
33 | private Double fhl; | 36 | private String fhl; |
34 | 37 | ||
35 | @ApiModelProperty(value = "排名") | 38 | @ApiModelProperty(value = "排名") |
36 | private Integer rank; | 39 | private Integer rank; |
37 | 40 | ||
38 | private long monthDayNum = 30; | 41 | private long monthDayNum = 30; |
39 | 42 | ||
40 | public Double getFhl() { | 43 | public String getFhl() { |
41 | if(this.getCSL() != null && this.getProScale() != null && this.getProScale().doubleValue() > 0 ){ | 44 | if(this.getCSL() != null && this.getProScale() != null && this.getProScale().doubleValue() > 0 ){ |
42 | fhl = this.getCSL()*100 / (this.getProScale() * this.getMonthDayNum() ); | 45 | fhl = JSUtils.format( this.getCSL()*100 / (this.getProScale() * this.getMonthDayNum() ) ); |
43 | } | 46 | } |
44 | return fhl; | 47 | return fhl; |
45 | } | 48 | } |
46 | 49 | ||
47 | public Double getHbcslbl() { | 50 | public String getHbcslbl() { |
48 | if(this.getCSL() != null && this.getHbcsl() != null && this.getHbcsl().doubleValue() > 0){ | 51 | if(this.getCSL() != null && this.getHbcsl() != null && this.getHbcsl().doubleValue() > 0){ |
49 | hbcslbl = (this.getCSL() - this.getHbcsl()) * 100 / this.getHbcsl() ; | 52 | hbcslbl = JSUtils.format( (this.getCSL() - this.getHbcsl()) * 100 / this.getHbcsl()); |
50 | } | 53 | } |
51 | return hbcslbl; | 54 | return hbcslbl; |
52 | } | 55 | } |
53 | 56 | ||
54 | public Double getTbcslbl() { | 57 | public String getTbcslbl() { |
55 | if(this.getCSL() != null && this.getTbcsl() != null && this.getTbcsl().doubleValue() > 0){ | 58 | if(this.getCSL() != null && this.getTbcsl() != null && this.getTbcsl().doubleValue() > 0){ |
56 | tbcslbl = (this.getCSL() - this.getTbcsl())*100 / this.getTbcsl() ; | 59 | tbcslbl = JSUtils.format( (this.getCSL() - this.getTbcsl())*100 / this.getTbcsl()); |
57 | } | 60 | } |
58 | return tbcslbl; | 61 | return tbcslbl; |
59 | } | 62 | } | ... | ... |
-
请 注册 或 登录 后发表评论