e9308e9e 康伟

kangwei:新增三个大屏组件开发-接口

1 个父辈 6698c57d
...@@ -29,7 +29,7 @@ public class MaterialAcceptanceFormServiceImpl extends ServiceImpl<MaterialAccep ...@@ -29,7 +29,7 @@ public class MaterialAcceptanceFormServiceImpl extends ServiceImpl<MaterialAccep
29 @Transactional 29 @Transactional
30 @Override 30 @Override
31 public void saveOrUpdateMaterialAcceptanceForm(MaterialAcceptanceForm materialAcceptanceForm) { 31 public void saveOrUpdateMaterialAcceptanceForm(MaterialAcceptanceForm materialAcceptanceForm) {
32 MaterialAcceptanceForm materialAcceptanceFormEntity = baseMapper.queryByMaterialInId(materialAcceptanceForm.getId()); 32 MaterialAcceptanceForm materialAcceptanceFormEntity = baseMapper.queryById(materialAcceptanceForm.getId());
33 if(materialAcceptanceFormEntity==null) { 33 if(materialAcceptanceFormEntity==null) {
34 //result.error500("未找到对应实体"); 34 //result.error500("未找到对应实体");
35 baseMapper.insert(materialAcceptanceForm); 35 baseMapper.insert(materialAcceptanceForm);
...@@ -37,7 +37,7 @@ public class MaterialAcceptanceFormServiceImpl extends ServiceImpl<MaterialAccep ...@@ -37,7 +37,7 @@ public class MaterialAcceptanceFormServiceImpl extends ServiceImpl<MaterialAccep
37 baseMapper.updateById(materialAcceptanceForm); 37 baseMapper.updateById(materialAcceptanceForm);
38 } 38 }
39 //修改药剂入库的确认状态 39 //修改药剂入库的确认状态
40 baseMapper.updateMaterialINConfirmStatus(materialAcceptanceForm.getId(),materialAcceptanceForm.getConfirmStatus()); 40 baseMapper.updateMaterialINConfirmStatus(materialAcceptanceForm.getMaterialInId(),materialAcceptanceForm.getConfirmStatus());
41 41
42 } 42 }
43 public MaterialAcceptanceForm queryById(String id){ 43 public MaterialAcceptanceForm queryById(String id){
......
1 package com.skua.modules.statistics.service;
2
3 import com.skua.modules.statistics.vo.ReportTargetEnergyVO;
4 import com.skua.modules.statistics.vo.ReportTargetStatisticsVO;
5
6 import java.util.List;
7
8 /**
9 * @auther kangwei
10 * @create 2025-03-21-14:19
11 */
12 public interface IReportTargetStatisticsService {
13 /***
14 * 水量经营分析
15 * @param departIds
16 * @param year
17 * @param endTime
18 * @return
19 */
20 public ReportTargetStatisticsVO targetWaterStatistics(String departIds, String year , String startTime, String endTime );
21 //水量经营分析 列表
22 public List<ReportTargetStatisticsVO> targetWaterStatisticsList(String departIds, String year , String startTime, String endTime);
23
24 /***
25 * 能耗经营分析
26 * @param departIds
27 * @param year
28 * @param
29 * @return
30 */
31 public ReportTargetEnergyVO targetEnergyStatistics(String departIds, String year , String startTime, String endTime);
32 //能耗分析:列表
33 public List<ReportTargetEnergyVO> targetEnergyStatisticsList(String departIds,String year ,String startTime,String endTime);
34
35 /***
36 * 费用经营分析
37 * @param departIds
38 * @param year
39 * @param
40 * @return
41 */
42 public ReportTargetStatisticsVO targetCostStatistics(String departIds,String year ,String startTime,String endTime);
43 //费用经营分析 --列表
44 public List<ReportTargetStatisticsVO> targetCostStatisticsList(String departIds,String year ,String startTime,String endTime);
45 }
1 package com.skua.modules.statistics.vo;
2
3 import io.swagger.annotations.ApiModel;
4 import io.swagger.annotations.ApiModelProperty;
5 import lombok.Data;
6
7 import java.util.List;
8
9 /**
10 * @auther kangwei
11 * @create 2025-03-21-15:10
12 */
13 @Data
14 @ApiModel(value="ReportTargetInfoVO ", description="运营目标报表分析对象")
15 public class ReportTargetEnergyVO {
16
17 @ApiModelProperty(value = "机构ID")
18 private String departId;
19
20 @ApiModelProperty(value = "机构名称")
21 private String departName;
22
23 @ApiModelProperty(value = "吨水电费年目标")
24 private String dsdfYearTarget;
25
26 @ApiModelProperty(value = "吨水药费年目标")
27 private String dsyfYearTarget;
28
29 @ApiModelProperty(value = "吨水电费实际值")
30 private String dsdfValue;
31
32 @ApiModelProperty(value = "吨水药费实际值")
33 private String dsyfValue;
34
35
36 public ReportTargetEnergyVO(){
37
38 }
39
40 public ReportTargetEnergyVO(String dsdfYearTarget, String dsdfValue, String dsyfYearTarget, String dsyfValue) {
41 this.dsdfYearTarget = dsdfYearTarget;
42 this.dsyfYearTarget = dsyfYearTarget;
43 this.dsdfValue = dsdfValue;
44 this.dsyfValue = dsyfValue;
45 }
46
47 @ApiModelProperty(value = "列表数据")
48 private List<ReportTargetEnergyVO> dataList = null;
49 }
1 package com.skua.modules.statistics.vo;
2
3 import com.skua.core.aspect.annotation.Dict;
4 import com.skua.tool.util.JSUtils;
5 import io.swagger.annotations.ApiModel;
6 import io.swagger.annotations.ApiModelProperty;
7 import lombok.Data;
8
9 /**
10 * @auther kangwei
11 * @create 2025-03-21-14:22
12 */
13 @Data
14 @ApiModel(value="ReportTargetInfoVO ", description="运营目标报表分析对象")
15 public class ReportTargetInfoVO {
16
17
18 @ApiModelProperty(value = "目标Code")
19 private String targetCode;
20
21 @ApiModelProperty(value = "目标名称")
22 private String targetName;
23
24 @ApiModelProperty(value = "目标值")
25 private String targetValue;
26
27 @ApiModelProperty(value = "实际值")
28 private String value;
29
30 public ReportTargetInfoVO() {
31 }
32
33 public ReportTargetInfoVO(String targetCode, String targetName, String targetValue, String value) {
34 this.targetCode = targetCode;
35 this.targetName = targetName;
36 this.targetValue = targetValue;
37 this.value = value;
38 }
39 }
1 package com.skua.modules.statistics.vo;
2
3 import com.skua.core.aspect.annotation.Dict;
4 import com.skua.tool.util.JSUtils;
5 import io.swagger.annotations.ApiModel;
6 import io.swagger.annotations.ApiModelProperty;
7 import lombok.Data;
8
9 import java.util.List;
10
11 /**
12 * @auther kangwei
13 * @create 2025-03-21-14:22
14 */
15 @Data
16 @ApiModel(value="ReportTargetStatisticsVO ", description="运营目标报表分析对象")
17 public class ReportTargetStatisticsVO {
18
19 @ApiModelProperty(value = "机构ID")
20 private String departId;
21
22 @ApiModelProperty(value = "机构名称")
23 private String departName;
24
25
26 @ApiModelProperty(value = "年目标")
27 private String yearTarget;
28
29 @ApiModelProperty(value = "年完成值")
30 private String yearValue;
31
32 @ApiModelProperty(value = "年度完成比例")
33 private String yearWcBL;
34
35 @ApiModelProperty(value = "月目标")
36 private String monthTarget;
37
38 @ApiModelProperty(value = "月完成值")
39 private String monthValue;
40
41 @ApiModelProperty(value = "月度完成比例")
42 private String monthWcBL;
43
44 @ApiModelProperty(value = "数据列表")
45 private List<ReportTargetStatisticsVO> dataList = null;
46
47
48
49 public ReportTargetStatisticsVO() {
50 }
51
52 public ReportTargetStatisticsVO(String yearTarget, String yearValue, String monthTarget, String monthValue) {
53 this.yearTarget = yearTarget;
54 this.yearValue = yearValue;
55 String expression = "100 * ( "+yearValue+"/"+yearTarget+" )";
56 this.yearWcBL = JSUtils.executeExpression(expression,"0.00");
57 this.monthTarget = monthTarget;
58 this.monthValue = monthValue;
59 expression = "100 * ( "+monthValue+"/"+monthTarget+" )";
60 this.monthWcBL = JSUtils.executeExpression(expression,"0.00");
61 }
62 }
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!