package com.ruoyi.manage.service.impl; import com.ruoyi.common.core.page.TableDataInfo; import com.ruoyi.manage.domain.DmBerth; import com.ruoyi.manage.domain.DpBerth; import com.ruoyi.manage.mapper.DpBerthMapper; import com.ruoyi.manage.service.DpBerthService; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import jakarta.annotation.Resource; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import java.util.List; /** *

* 泊位 服务实现类 *

* * @author zhangyy * @since 2025-03-11 */ @Service public class DpBerthServiceImpl extends ServiceImpl implements DpBerthService { @Resource private DpBerthMapper dpBerthMapper; @Override public TableDataInfo getPageList(DmBerth dpBerth) { Integer offset = (dpBerth.getPageNum()-1)*dpBerth.getPageSize(); dpBerth.setOffset(offset); List records = dpBerthMapper.getPageList(dpBerth); long total = dpBerthMapper.getTotal(dpBerth); return new TableDataInfo(records,Integer.parseInt(String.valueOf(total))); } }