有没有做好的同学发布一下源码
QueryWrapper<User> queryWrapper = new QueryWrapper<User>(); queryWrapper.ge("age",26); Page<User> page = new Page<>(1, 2); IPage<User> iPage = userMapper.selectPage(page, queryWrapper); System.out.println("总页数:"+iPage.getPages()); System.out.println("总记录数:"+iPage.getTotal()); List<User> userList = iPage.getRecords(); userList.forEach(System.out::println);