kangwei: 区域用户数据权限问题
正在显示
16 个修改的文件
包含
64 行增加
和
35 行删除
sk-module-biz/src/main/java/com/skua/modules/dataAnalysis/controller/SysCommandCentreController.java
... | @@ -91,7 +91,7 @@ public class SysCommandCentreController { | ... | @@ -91,7 +91,7 @@ public class SysCommandCentreController { |
91 | fReportItemvList.add( avgDayDataVO ); | 91 | fReportItemvList.add( avgDayDataVO ); |
92 | 92 | ||
93 | //年数据统计: | 93 | //年数据统计: |
94 | String total = factoryInfoService.querySumProScale(); | 94 | String total = factoryInfoService.querySumProScale( departIds ); |
95 | total = String.format("%.2f", Double.parseDouble(total)); | 95 | total = String.format("%.2f", Double.parseDouble(total)); |
96 | fReportItemvList.add( new FRportlCommandCenterVO( total,"0","0")); | 96 | fReportItemvList.add( new FRportlCommandCenterVO( total,"0","0")); |
97 | 97 | ||
... | @@ -364,8 +364,13 @@ public class SysCommandCentreController { | ... | @@ -364,8 +364,13 @@ public class SysCommandCentreController { |
364 | @ApiOperation(value="指挥中心-药剂趋势", notes="指挥中心-药剂趋势") | 364 | @ApiOperation(value="指挥中心-药剂趋势", notes="指挥中心-药剂趋势") |
365 | @GetMapping(value = "/statisticsByYjqs") | 365 | @GetMapping(value = "/statisticsByYjqs") |
366 | public Result<DepartDrugResult> statisticsByYjqs(@RequestParam(name = "month", required = true)String month) { | 366 | public Result<DepartDrugResult> statisticsByYjqs(@RequestParam(name = "month", required = true)String month) { |
367 | DateVO dateVO = new DateVO(month); | 367 | // DateVO dateVO = new DateVO(month); |
368 | DepartDrugResult departDrugResult = commandCentreService.getYhTotal(dateVO.getNowMonth()); | 368 | |
369 | String departIds = BaseContextHandler.getDeparts();//1818214519948836864,1711662624459804674 | ||
370 | /* if(StringUtils.isNotEmpty(reportItemvParam.getDepartIds()) ){ | ||
371 | departIds = reportItemvParam.getDepartIds(); | ||
372 | }*/ | ||
373 | DepartDrugResult departDrugResult = commandCentreService.getYhTotal(departIds,month); | ||
369 | Result<DepartDrugResult> result = new Result<>(); | 374 | Result<DepartDrugResult> result = new Result<>(); |
370 | result.setSuccess(true); | 375 | result.setSuccess(true); |
371 | result.setResult(departDrugResult); | 376 | result.setResult(departDrugResult); | ... | ... |
... | @@ -26,7 +26,7 @@ public interface ICommandCentreService { | ... | @@ -26,7 +26,7 @@ public interface ICommandCentreService { |
26 | * @param month | 26 | * @param month |
27 | * @return | 27 | * @return |
28 | */ | 28 | */ |
29 | DepartDrugResult getYhTotal(String month); | 29 | DepartDrugResult getYhTotal(String departIds,String month); |
30 | /*** | 30 | /*** |
31 | * 指挥中心----运行负荷率分析----处理水量详情 | 31 | * 指挥中心----运行负荷率分析----处理水量详情 |
32 | * @param | 32 | * @param | ... | ... |
sk-module-biz/src/main/java/com/skua/modules/dataAnalysis/service/impl/CommandCentreServiceImpl.java
... | @@ -43,21 +43,21 @@ public class CommandCentreServiceImpl implements ICommandCentreService { | ... | @@ -43,21 +43,21 @@ public class CommandCentreServiceImpl implements ICommandCentreService { |
43 | } | 43 | } |
44 | 44 | ||
45 | @Override | 45 | @Override |
46 | public DepartDrugResult getYhTotal(String month) { | 46 | public DepartDrugResult getYhTotal(String departIds,String month) { |
47 | String monthTb = DateUtils.getTbMonth(month);//同比时间 | 47 | String monthTb = DateUtils.getTbMonth(month);//同比时间 |
48 | String monthHb = DateUtils.getHbMonth(month);//环比时间 | 48 | String monthHb = DateUtils.getHbMonth(month);//环比时间 |
49 | String dataViewName2119 = ReportViewUtil.buildViewLike(ReportConstant.view2119, ReportConstant.fieldClsl, "", month); | 49 | String dataViewName2119 = ReportViewUtil.buildViewLike(ReportConstant.view2119, ReportConstant.fieldClsl, departIds, month); |
50 | String dataViewName2119tb = ReportViewUtil.buildViewLike(ReportConstant.view2119, ReportConstant.fieldClsl, "", monthTb); | 50 | String dataViewName2119tb = ReportViewUtil.buildViewLike(ReportConstant.view2119, ReportConstant.fieldClsl, departIds, monthTb); |
51 | String dataViewName2119hb = ReportViewUtil.buildViewLike(ReportConstant.view2119, ReportConstant.fieldClsl, "", monthHb); | 51 | String dataViewName2119hb = ReportViewUtil.buildViewLike(ReportConstant.view2119, ReportConstant.fieldClsl, departIds, monthHb); |
52 | String dataViewName3a24 = ReportViewUtil.buildViewLike(ReportConstant.view3a24, ReportConstant.fieldYj, "", month); | 52 | String dataViewName3a24 = ReportViewUtil.buildViewLike(ReportConstant.view3a24, ReportConstant.fieldYj, departIds, month); |
53 | String dataViewName3a24tb = ReportViewUtil.buildViewLike(ReportConstant.view3a24, ReportConstant.fieldYj, "", monthTb); | 53 | String dataViewName3a24tb = ReportViewUtil.buildViewLike(ReportConstant.view3a24, ReportConstant.fieldYj, departIds, monthTb); |
54 | String dataViewName3a24hb = ReportViewUtil.buildViewLike(ReportConstant.view3a24, ReportConstant.fieldYj, "", monthHb); | 54 | String dataViewName3a24hb = ReportViewUtil.buildViewLike(ReportConstant.view3a24, ReportConstant.fieldYj, departIds, monthHb); |
55 | DepartDrugResult departDrugResult = fReportItemvMapper.getYhData(month,monthTb,monthHb, | 55 | DepartDrugResult departDrugResult = fReportItemvMapper.getYhData(month,monthTb,monthHb, |
56 | dataViewName3a24,dataViewName3a24tb,dataViewName3a24hb); | 56 | dataViewName3a24,dataViewName3a24tb,dataViewName3a24hb); |
57 | if(departDrugResult == null){ | 57 | if(departDrugResult == null){ |
58 | departDrugResult = new DepartDrugResult(); | 58 | departDrugResult = new DepartDrugResult(); |
59 | } | 59 | } |
60 | List<DepartDrugDataVO> drugList = new ArrayList<>(); | 60 | List<DepartDrugDataVO> drugList = null; |
61 | drugList = fReportItemvMapper.getYhList(month,monthTb,monthHb, | 61 | drugList = fReportItemvMapper.getYhList(month,monthTb,monthHb, |
62 | dataViewName2119,dataViewName2119tb,dataViewName2119hb, | 62 | dataViewName2119,dataViewName2119tb,dataViewName2119hb, |
63 | dataViewName3a24,dataViewName3a24tb,dataViewName3a24hb); | 63 | dataViewName3a24,dataViewName3a24tb,dataViewName3a24hb); | ... | ... |
... | @@ -2,6 +2,7 @@ package com.skua.modules.emergency.controller; | ... | @@ -2,6 +2,7 @@ package com.skua.modules.emergency.controller; |
2 | 2 | ||
3 | import com.skua.core.api.vo.Result; | 3 | import com.skua.core.api.vo.Result; |
4 | import com.skua.core.aspect.annotation.AutoLog; | 4 | import com.skua.core.aspect.annotation.AutoLog; |
5 | import com.skua.core.context.BaseContextHandler; | ||
5 | import com.skua.modules.emergency.service.IEmergencyRiskEventService; | 6 | import com.skua.modules.emergency.service.IEmergencyRiskEventService; |
6 | import com.skua.modules.emergency.vo.DangerDatabaseResult; | 7 | import com.skua.modules.emergency.vo.DangerDatabaseResult; |
7 | import com.skua.modules.emergency.vo.MapDatabaseResult; | 8 | import com.skua.modules.emergency.vo.MapDatabaseResult; |
... | @@ -9,6 +10,7 @@ import com.skua.modules.emergency.vo.RiskDatabaseResult; | ... | @@ -9,6 +10,7 @@ import com.skua.modules.emergency.vo.RiskDatabaseResult; |
9 | import io.swagger.annotations.Api; | 10 | import io.swagger.annotations.Api; |
10 | import io.swagger.annotations.ApiOperation; | 11 | import io.swagger.annotations.ApiOperation; |
11 | import lombok.extern.slf4j.Slf4j; | 12 | import lombok.extern.slf4j.Slf4j; |
13 | import org.apache.commons.lang3.StringUtils; | ||
12 | import org.springframework.beans.factory.annotation.Autowired; | 14 | import org.springframework.beans.factory.annotation.Autowired; |
13 | import org.springframework.web.bind.annotation.*; | 15 | import org.springframework.web.bind.annotation.*; |
14 | import java.util.*; | 16 | import java.util.*; |
... | @@ -58,9 +60,12 @@ public class EventMapController { | ... | @@ -58,9 +60,12 @@ public class EventMapController { |
58 | @AutoLog(value = "隐患排查巡检统计") | 60 | @AutoLog(value = "隐患排查巡检统计") |
59 | @ApiOperation(value="隐患排查巡检统计", notes="隐患排查巡检统计") | 61 | @ApiOperation(value="隐患排查巡检统计", notes="隐患排查巡检统计") |
60 | @GetMapping(value = "/getDangerList") | 62 | @GetMapping(value = "/getDangerList") |
61 | public Result<List<DangerDatabaseResult>> getDangerList(String year){ | 63 | public Result<List<DangerDatabaseResult>> getDangerList( String departIds,String year){ |
62 | Result<List<DangerDatabaseResult>> result = new Result<>(); | 64 | Result<List<DangerDatabaseResult>> result = new Result<>(); |
63 | List<DangerDatabaseResult> list = emergencyRiskEventService.getDangerList(year); | 65 | if(StringUtils.isEmpty(departIds)){ |
66 | departIds = BaseContextHandler.getDeparts();//1818214519948836864,1711662624459804674 | ||
67 | } | ||
68 | List<DangerDatabaseResult> list = emergencyRiskEventService.getDangerList(departIds,year); | ||
64 | result.setSuccess(true); | 69 | result.setSuccess(true); |
65 | result.setResult(list); | 70 | result.setResult(list); |
66 | return result; | 71 | return result; |
... | @@ -72,9 +77,12 @@ public class EventMapController { | ... | @@ -72,9 +77,12 @@ public class EventMapController { |
72 | @AutoLog(value = "地图隐患排查巡检统计") | 77 | @AutoLog(value = "地图隐患排查巡检统计") |
73 | @ApiOperation(value="地图隐患排查巡检统计", notes="地图隐患排查巡检统计") | 78 | @ApiOperation(value="地图隐患排查巡检统计", notes="地图隐患排查巡检统计") |
74 | @GetMapping(value = "/getMapData") | 79 | @GetMapping(value = "/getMapData") |
75 | public Result<List<MapDatabaseResult>> getMapData(String year){ | 80 | public Result<List<MapDatabaseResult>> getMapData(String departIds,String year){ |
76 | Result<List<MapDatabaseResult>> result = new Result<>(); | 81 | Result<List<MapDatabaseResult>> result = new Result<>(); |
77 | List<MapDatabaseResult> list = emergencyRiskEventService.getMapData(year); | 82 | if(StringUtils.isEmpty(departIds)){ |
83 | departIds = BaseContextHandler.getDeparts();//1818214519948836864,1711662624459804674 | ||
84 | } | ||
85 | List<MapDatabaseResult> list = emergencyRiskEventService.getMapData(departIds,year); | ||
78 | result.setSuccess(true); | 86 | result.setSuccess(true); |
79 | result.setResult(list); | 87 | result.setResult(list); |
80 | return result; | 88 | return result; | ... | ... |
... | @@ -19,8 +19,8 @@ public interface EmergencyRiskEventMapper extends BaseMapper<EmergencyRiskEvent> | ... | @@ -19,8 +19,8 @@ public interface EmergencyRiskEventMapper extends BaseMapper<EmergencyRiskEvent> |
19 | List<RiskDatabaseResult> getRiskList(@Param("year") String year); | 19 | List<RiskDatabaseResult> getRiskList(@Param("year") String year); |
20 | 20 | ||
21 | @Anonymous | 21 | @Anonymous |
22 | List<DangerDatabaseResult> getDangerList(@Param("year") String year); | 22 | List<DangerDatabaseResult> getDangerList( @Param("departIds")String departIds , @Param("year") String year); |
23 | 23 | ||
24 | @Anonymous | 24 | @Anonymous |
25 | List<MapDatabaseResult> getMapData(@Param("year") String year); | 25 | List<MapDatabaseResult> getMapData( @Param("departIds")String departIds , @Param("year") String year); |
26 | } | 26 | } | ... | ... |
... | @@ -38,7 +38,9 @@ | ... | @@ -38,7 +38,9 @@ |
38 | WHERE | 38 | WHERE |
39 | d.depart_type = 1 | 39 | d.depart_type = 1 |
40 | AND r.report_date LIKE CONCAT(#{year},'%') | 40 | AND r.report_date LIKE CONCAT(#{year},'%') |
41 | 41 | <if test="departIds != null and departIds !='' "> | |
42 | and d.id in (${departIds}) | ||
43 | </if> | ||
42 | order by r.report_date desc | 44 | order by r.report_date desc |
43 | </select> | 45 | </select> |
44 | 46 | ||
... | @@ -53,6 +55,10 @@ | ... | @@ -53,6 +55,10 @@ |
53 | LEFT JOIN sys_factory_info f ON f.depart_id = d.id | 55 | LEFT JOIN sys_factory_info f ON f.depart_id = d.id |
54 | WHERE | 56 | WHERE |
55 | d.depart_type = 1 | 57 | d.depart_type = 1 |
58 | <if test="departIds != null and departIds !='' "> | ||
59 | and d.id in (${departIds}) | ||
60 | </if> | ||
61 | |||
56 | </select> | 62 | </select> |
57 | 63 | ||
58 | </mapper> | 64 | </mapper> | ... | ... |
... | @@ -45,12 +45,12 @@ public interface IEmergencyRiskEventService extends IService<EmergencyRiskEvent> | ... | @@ -45,12 +45,12 @@ public interface IEmergencyRiskEventService extends IService<EmergencyRiskEvent> |
45 | * 隐患排查巡检统计 | 45 | * 隐患排查巡检统计 |
46 | * @return | 46 | * @return |
47 | */ | 47 | */ |
48 | List<DangerDatabaseResult> getDangerList(String year); | 48 | List<DangerDatabaseResult> getDangerList(String departIds, String year); |
49 | 49 | ||
50 | /** | 50 | /** |
51 | * 地图隐患排查数量 | 51 | * 地图隐患排查数量 |
52 | * @param year | 52 | * @param year |
53 | * @return | 53 | * @return |
54 | */ | 54 | */ |
55 | List<MapDatabaseResult> getMapData(String year); | 55 | List<MapDatabaseResult> getMapData(String departIds, String year); |
56 | } | 56 | } | ... | ... |
... | @@ -29,6 +29,7 @@ import com.skua.modules.safe.entity.DangerLevelManageShare; | ... | @@ -29,6 +29,7 @@ import com.skua.modules.safe.entity.DangerLevelManageShare; |
29 | import com.skua.modules.safe.mapper.DangerInspectionRecordMapper; | 29 | import com.skua.modules.safe.mapper.DangerInspectionRecordMapper; |
30 | import com.skua.modules.safe.mapper.DangerLevelManageMapper; | 30 | import com.skua.modules.safe.mapper.DangerLevelManageMapper; |
31 | import com.skua.modules.safe.mapper.DangerLevelManageShareMapper; | 31 | import com.skua.modules.safe.mapper.DangerLevelManageShareMapper; |
32 | import com.skua.tool.util.JSUtils; | ||
32 | import com.skua.tool.util.UniqIdUtils; | 33 | import com.skua.tool.util.UniqIdUtils; |
33 | import org.apache.commons.lang3.StringUtils; | 34 | import org.apache.commons.lang3.StringUtils; |
34 | import org.springframework.beans.BeanUtils; | 35 | import org.springframework.beans.BeanUtils; |
... | @@ -160,21 +161,21 @@ public class EmergencyRiskEventServiceImpl extends ServiceImpl<EmergencyRiskEven | ... | @@ -160,21 +161,21 @@ public class EmergencyRiskEventServiceImpl extends ServiceImpl<EmergencyRiskEven |
160 | } | 161 | } |
161 | 162 | ||
162 | @Override | 163 | @Override |
163 | public List<DangerDatabaseResult> getDangerList(String year) { | 164 | public List<DangerDatabaseResult> getDangerList(String departIds, String year) { |
164 | if(StringUtils.isEmpty(year)){ | 165 | if(StringUtils.isEmpty(year)){ |
165 | year = String.valueOf(DateUtils.getYear()); | 166 | year = String.valueOf(DateUtils.getYear()); |
166 | } | 167 | } |
167 | List<DangerDatabaseResult> list = emergencyRiskEventMapper.getDangerList(year); | 168 | List<DangerDatabaseResult> list = emergencyRiskEventMapper.getDangerList(JSUtils.quoteEach( departIds, ","), year); |
168 | return list; | 169 | return list; |
169 | } | 170 | } |
170 | 171 | ||
171 | @Override | 172 | @Override |
172 | public List<MapDatabaseResult> getMapData(String year) { | 173 | public List<MapDatabaseResult> getMapData(String departIds,String year) { |
173 | if(StringUtils.isEmpty(year)){ | 174 | if(StringUtils.isEmpty(year)){ |
174 | year = String.valueOf(DateUtils.getYear()); | 175 | year = String.valueOf(DateUtils.getYear()); |
175 | } | 176 | } |
176 | List<DangerDatabaseResult> dangerList = emergencyRiskEventMapper.getDangerList(year); | 177 | List<DangerDatabaseResult> dangerList = emergencyRiskEventMapper.getDangerList(JSUtils.quoteEach(departIds,","), year); |
177 | List<MapDatabaseResult> list = emergencyRiskEventMapper.getMapData(year); | 178 | List<MapDatabaseResult> list = emergencyRiskEventMapper.getMapData(JSUtils.quoteEach(departIds,","),year); |
178 | for (MapDatabaseResult mapDatabaseResult : list) { | 179 | for (MapDatabaseResult mapDatabaseResult : list) { |
179 | List<DangerDatabaseResult> daList = new ArrayList<>(); | 180 | List<DangerDatabaseResult> daList = new ArrayList<>(); |
180 | String departId = mapDatabaseResult.getDepartId(); | 181 | String departId = mapDatabaseResult.getDepartId(); | ... | ... |
... | @@ -3,6 +3,7 @@ package com.skua.modules.report.controller; | ... | @@ -3,6 +3,7 @@ package com.skua.modules.report.controller; |
3 | 3 | ||
4 | import com.skua.core.api.vo.Result; | 4 | import com.skua.core.api.vo.Result; |
5 | import com.skua.core.aspect.annotation.AutoLog; | 5 | import com.skua.core.aspect.annotation.AutoLog; |
6 | import com.skua.core.context.BaseContextHandler; | ||
6 | import com.skua.modules.custom.service.IFCustomReportDatasetService; | 7 | import com.skua.modules.custom.service.IFCustomReportDatasetService; |
7 | import com.skua.modules.report.service.IOperationReportService; | 8 | import com.skua.modules.report.service.IOperationReportService; |
8 | import com.skua.modules.report.vo.JnhbReportData; | 9 | import com.skua.modules.report.vo.JnhbReportData; |
... | @@ -38,7 +39,8 @@ public class OperationReportController { | ... | @@ -38,7 +39,8 @@ public class OperationReportController { |
38 | @RequestParam(name="season") Integer season, | 39 | @RequestParam(name="season") Integer season, |
39 | HttpServletRequest req) { | 40 | HttpServletRequest req) { |
40 | Result<ProductDataVO> result = new Result<ProductDataVO>(); | 41 | Result<ProductDataVO> result = new Result<ProductDataVO>(); |
41 | ProductDataVO productDataVO = operationReportService.handeReportMonthData(year,season); | 42 | String departIds = BaseContextHandler.getDeparts();//1818214519948836864,1711662624459804674 |
43 | ProductDataVO productDataVO = operationReportService.handeReportMonthData(departIds,year,season); | ||
42 | result.setResult( productDataVO ); | 44 | result.setResult( productDataVO ); |
43 | return result; | 45 | return result; |
44 | } | 46 | } | ... | ... |
... | @@ -13,5 +13,5 @@ public interface IOperationReportService { | ... | @@ -13,5 +13,5 @@ public interface IOperationReportService { |
13 | * @param season | 13 | * @param season |
14 | * @return | 14 | * @return |
15 | */ | 15 | */ |
16 | ProductDataVO handeReportMonthData(Integer year, Integer season); | 16 | ProductDataVO handeReportMonthData(String departIds,Integer year, Integer season); |
17 | } | 17 | } | ... | ... |
... | @@ -44,7 +44,7 @@ public class OperationReportServiceImpl implements IOperationReportService { | ... | @@ -44,7 +44,7 @@ public class OperationReportServiceImpl implements IOperationReportService { |
44 | * @param season | 44 | * @param season |
45 | * @return | 45 | * @return |
46 | */ | 46 | */ |
47 | public ProductDataVO handeReportMonthData(Integer year, Integer season){ | 47 | public ProductDataVO handeReportMonthData(String departId,Integer year, Integer season){ |
48 | ProductDataVO productDataVO = new ProductDataVO();//返回结果 | 48 | ProductDataVO productDataVO = new ProductDataVO();//返回结果 |
49 | int lastYear = year - 1;//去年 | 49 | int lastYear = year - 1;//去年 |
50 | productDataVO.setLastYear(lastYear); | 50 | productDataVO.setLastYear(lastYear); |
... | @@ -54,12 +54,12 @@ public class OperationReportServiceImpl implements IOperationReportService { | ... | @@ -54,12 +54,12 @@ public class OperationReportServiceImpl implements IOperationReportService { |
54 | productDataVO.setStartTime(seasonTimeVO.getStartTime());//季度开始时间 | 54 | productDataVO.setStartTime(seasonTimeVO.getStartTime());//季度开始时间 |
55 | productDataVO.setEndTime( seasonTimeVO.getEndTime());//季度结束时间 | 55 | productDataVO.setEndTime( seasonTimeVO.getEndTime());//季度结束时间 |
56 | //水务公司总数 | 56 | //水务公司总数 |
57 | String sql = "select count(1) from sys_depart where depart_type = 1"; | 57 | String sql = "select count(1) from sys_depart where depart_type = 1 where id in ("+JSUtils.quoteEach(departId,",")+")"; |
58 | String deptartCount = getJdbcTemplate().queryForObject(sql,String.class); | 58 | String deptartCount = getJdbcTemplate().queryForObject(sql,String.class); |
59 | productDataVO.setDeptartCount( deptartCount ); | 59 | productDataVO.setDeptartCount( deptartCount ); |
60 | 60 | ||
61 | long dayNum = DateUtils.differenceDay(seasonTimeVO.getStartTime(),seasonTimeVO.getEndTime());//天数 | 61 | long dayNum = DateUtils.differenceDay(seasonTimeVO.getStartTime(),seasonTimeVO.getEndTime());//天数 |
62 | String departId = BaseContextHandler.getDeparts(); | 62 | // String departId = BaseContextHandler.getDeparts(); |
63 | productDataVO.setSequentialProgress("基本满足时序进度"); | 63 | productDataVO.setSequentialProgress("基本满足时序进度"); |
64 | // ysfsl:月收费水量 ; yyf:月药费 ; ysjsl:月实际水量 | 64 | // ysfsl:月收费水量 ; yyf:月药费 ; ysjsl:月实际水量 |
65 | String dataViewName4411 = ReportViewUtil.buildView(ReportConstant.view4411,"ysfsl,ysjsl,yyf", departId, seasonTimeVO.getStartTime(),seasonTimeVO.getEndTime()); | 65 | String dataViewName4411 = ReportViewUtil.buildView(ReportConstant.view4411,"ysfsl,ysjsl,yyf", departId, seasonTimeVO.getStartTime(),seasonTimeVO.getEndTime()); | ... | ... |
... | @@ -19,6 +19,9 @@ public class ProductDataVO { | ... | @@ -19,6 +19,9 @@ public class ProductDataVO { |
19 | @ApiModelProperty(value = "去年") | 19 | @ApiModelProperty(value = "去年") |
20 | private Integer lastYear; | 20 | private Integer lastYear; |
21 | 21 | ||
22 | @ApiModelProperty(value = "今年") | ||
23 | private Integer year; | ||
24 | |||
22 | @ApiModelProperty(value = "季度开始时间") | 25 | @ApiModelProperty(value = "季度开始时间") |
23 | private String startTime; | 26 | private String startTime; |
24 | @ApiModelProperty(value = "季度结束时间") | 27 | @ApiModelProperty(value = "季度结束时间") | ... | ... |
... | @@ -100,5 +100,5 @@ public interface SysFactoryInfoMapper extends BaseMapper<SysFactoryInfo> { | ... | @@ -100,5 +100,5 @@ public interface SysFactoryInfoMapper extends BaseMapper<SysFactoryInfo> { |
100 | * 获取总的设计规模 | 100 | * 获取总的设计规模 |
101 | * @return | 101 | * @return |
102 | */ | 102 | */ |
103 | public String querySumProScale(); | 103 | public String querySumProScale(@Param("departIds") String departIds); |
104 | } | 104 | } | ... | ... |
... | @@ -495,5 +495,9 @@ | ... | @@ -495,5 +495,9 @@ |
495 | <!-- 获取总的设计规模--> | 495 | <!-- 获取总的设计规模--> |
496 | <select id="querySumProScale" resultType="java.lang.String"> | 496 | <select id="querySumProScale" resultType="java.lang.String"> |
497 | select sum(pro_scale) from sys_factory_info | 497 | select sum(pro_scale) from sys_factory_info |
498 | where 1=1 | ||
499 | <if test="departIds != null and departIds != ''"> | ||
500 | and depart_id in (${departIds}) | ||
501 | </if> | ||
498 | </select> | 502 | </select> |
499 | </mapper> | 503 | </mapper> | ... | ... |
... | @@ -108,7 +108,7 @@ public interface ISysFactoryInfoService extends IService<SysFactoryInfo> { | ... | @@ -108,7 +108,7 @@ public interface ISysFactoryInfoService extends IService<SysFactoryInfo> { |
108 | * 获取总的设计规模 | 108 | * 获取总的设计规模 |
109 | * @return | 109 | * @return |
110 | */ | 110 | */ |
111 | public String querySumProScale(); | 111 | public String querySumProScale(String departIds); |
112 | 112 | ||
113 | /** | 113 | /** |
114 | * 获取进出水标准 | 114 | * 获取进出水标准 | ... | ... |
... | @@ -681,8 +681,8 @@ public class SysFactoryInfoServiceImpl extends ServiceImpl<SysFactoryInfoMapper, | ... | @@ -681,8 +681,8 @@ public class SysFactoryInfoServiceImpl extends ServiceImpl<SysFactoryInfoMapper, |
681 | * 获取总的设计规模 | 681 | * 获取总的设计规模 |
682 | * @return | 682 | * @return |
683 | */ | 683 | */ |
684 | public String querySumProScale(){ | 684 | public String querySumProScale(String departIds){ |
685 | return sysFactoryInfoMapper.querySumProScale(); | 685 | return sysFactoryInfoMapper.querySumProScale(departIds); |
686 | } | 686 | } |
687 | 687 | ||
688 | @Override | 688 | @Override | ... | ... |
-
请 注册 或 登录 后发表评论