13693261870
2025-07-02 6708810c4de34dfb9513061432d656f91d56ee3a
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
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;
 
/**
 * <p>
 * 泊位 服务实现类
 * </p>
 *
 * @author zhangyy
 * @since 2025-03-11
 */
@Service
public class DpBerthServiceImpl extends ServiceImpl<DpBerthMapper, DmBerth> implements DpBerthService {
    @Resource
    private DpBerthMapper dpBerthMapper;
    @Override
    public TableDataInfo getPageList(DmBerth dpBerth) {
        Integer offset = (dpBerth.getPageNum()-1)*dpBerth.getPageSize();
        dpBerth.setOffset(offset);
        List<DmBerth> records = dpBerthMapper.getPageList(dpBerth);
        long total = dpBerthMapper.getTotal(dpBerth);
        return new TableDataInfo(records,Integer.parseInt(String.valueOf(total)));
    }
 
}