| | |
| | | import com.whyc.dto.InfoDto; |
| | | import com.whyc.dto.Real.QuarterDto; |
| | | import com.whyc.dto.Response; |
| | | import com.whyc.dto.Statistic.StationStic; |
| | | import com.whyc.factory.InfoFactory; |
| | | import com.whyc.mapper.BattInfMapper; |
| | | import com.whyc.mapper.PowerInfMapper; |
| | |
| | | } |
| | | return list; |
| | | } |
| | | |
| | | //设备信息统计 |
| | | public Response getDevStatistic(StationStic stic) { |
| | | PageHelper.startPage(stic.getPageNum(),stic.getPageSize()); |
| | | List<BattInf> list=mapper.getDevStatistic(stic); |
| | | for (BattInf binf:list) { |
| | | //获取设备下电池组个数 |
| | | int battCount=mapper.getBattCountBydevId(binf.getDevId()); |
| | | binf.setBattCount(battCount); |
| | | } |
| | | PageInfo<BattInf> pageInfo=new PageInfo<>(list); |
| | | return new Response().setII(1,list.size()>0,pageInfo,"设备信息统计"); |
| | | } |
| | | } |