| | |
| | | import com.ruoyi.chargingPile.mapper.TParkingRecordMapper; |
| | | import com.ruoyi.chargingPile.service.TParkingRecordService; |
| | | import com.ruoyi.common.core.web.page.PageInfo; |
| | | import com.ruoyi.common.security.service.TokenService; |
| | | import com.ruoyi.common.security.utils.SecurityUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | |
| | | return this.baseMapper.getSum(sixBefore); |
| | | } |
| | | |
| | | @Autowired |
| | | private TokenService tokenService; |
| | | @Override |
| | | public TParkingRecordPageInfoVO pageList(ParkingRecordQuery query) { |
| | | Long userId = SecurityUtils.getUserId(); |
| | | Long userId = tokenService.getLoginUser().getUserid(); |
| | | //如果没传siteId,获取当前登陆人所有的siteIds |
| | | List<Integer> siteIds = new ArrayList<>(); |
| | | if (query.getSiteId()==null){ |
| | |
| | | }else { |
| | | siteIds.add(query.getSiteId()); |
| | | } |
| | | if (siteIds.isEmpty()){ |
| | | siteIds.add(-1); |
| | | } |
| | | query.setSiteIds(siteIds); |
| | | PageInfo<TParkingRecordVO> pageInfo = new PageInfo<>(query.getPageCurr(),query.getPageSize()); |
| | | // 查询站点的停车场id |