package com.shanghaichengdi.ghjgitem.service.impl;


import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.github.pagehelper.PageHelper;
import com.shanghaichengdi.ghjgitem.domain.WaterLevelData;
import com.shanghaichengdi.ghjgitem.mapper.WaterLevelDataMapper;
import com.shanghaichengdi.ghjgitem.service.WaterLevelDataService;
import com.shanghaichengdi.ghjgitem.vo.request.WaterLevelDataReq;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class WaterLevelDataServiceImpl extends ServiceImpl<WaterLevelDataMapper, WaterLevelData>
        implements WaterLevelDataService {

    @Resource
    private WaterLevelDataMapper mapper;

    @Override
    public List<WaterLevelData> getDataByTime(WaterLevelDataReq req) {
        PageHelper.startPage(req.getPageIndex(), req.getPageSize());
        return mapper.getDataByTime(req);
    }

}
