package com.zteits.park.dao.impl; import com.github.pagehelper.PageHelper; import com.github.pagehelper.PageInfo; import com.zteits.clouds.api.dto.park.param.parklotapply.QueryParkingLotApplyPageRequest; import com.zteits.park.dao.ParkingLotApplyDao; import com.zteits.park.domain.ParkingLotApply; import com.zteits.park.mapper.ParkingLotApplyMapper; import com.zteits.park.mapper.smapper.ParkingLotApplySMapper; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; import java.util.List; /** * Copyright: Copyright (c) 2018 zteits * * @Description: * @version: v1.0.0 * @author: xiejianpeng * @date: 2018/5/7 16 * Modification History: * Date Author Version Description * ---------------------------------------------------------* * 2018/5/7 xiejianpeng v1.0.0 创建 */ @Component public class ParkingLotApplyDaoImpl implements ParkingLotApplyDao { @Autowired private ParkingLotApplySMapper parkingLotApplySMapper; @Autowired private ParkingLotApplyMapper parkingLotApplyMapper; @Override public PageInfo queryParkLotApplyInfoPage(QueryParkingLotApplyPageRequest request) { //设置分页信息 PageHelper.startPage(request.getBaseRequest().getPageNum(), request.getBaseRequest().getPageSize()); List dtos = parkingLotApplySMapper.queryParkLotApplyList(request); return new PageInfo<>(dtos); } @Override public Integer saveParkLotApply(ParkingLotApply parkingLotApply) { return parkingLotApplyMapper.insertSelective(parkingLotApply); } }