Search in sources :

Example 56 with PageInfo

use of com.github.pagehelper.PageInfo in project production_ssm by megagao.

the class ProductServiceImpl method searchProductByProductType.

@Override
public EUDataGridResult searchProductByProductType(int page, int rows, String productType) throws Exception {
    // 分页处理
    PageHelper.startPage(page, rows);
    List<Product> list = productMapper.searchProductByProductType(productType);
    // 创建一个返回值对象
    EUDataGridResult result = new EUDataGridResult();
    result.setRows(list);
    // 取记录总条数
    PageInfo<Product> pageInfo = new PageInfo<>(list);
    result.setTotal(pageInfo.getTotal());
    return result;
}
Also used : PageInfo(com.github.pagehelper.PageInfo) EUDataGridResult(com.megagao.production.ssm.domain.customize.EUDataGridResult) Product(com.megagao.production.ssm.domain.Product)

Example 57 with PageInfo

use of com.github.pagehelper.PageInfo in project production_ssm by megagao.

the class TechnologyPlanServiceImpl method searchTechnologyPlanByTechnologyPlanId.

@Override
public EUDataGridResult searchTechnologyPlanByTechnologyPlanId(Integer page, Integer rows, String technologyPlanId) throws Exception {
    // 分页处理
    PageHelper.startPage(page, rows);
    List<TechnologyPlan> list = technologyPlanMapper.searchTechnologyPlanByTechnologyPlanId(technologyPlanId);
    // 创建一个返回值对象
    EUDataGridResult result = new EUDataGridResult();
    result.setRows(list);
    // 取记录总条数
    PageInfo<TechnologyPlan> pageInfo = new PageInfo<>(list);
    result.setTotal(pageInfo.getTotal());
    return result;
}
Also used : PageInfo(com.github.pagehelper.PageInfo) TechnologyPlan(com.megagao.production.ssm.domain.TechnologyPlan) EUDataGridResult(com.megagao.production.ssm.domain.customize.EUDataGridResult)

Example 58 with PageInfo

use of com.github.pagehelper.PageInfo in project production_ssm by megagao.

the class DepartmentServiceImpl method searchDepartmentByDepartmentId.

@Override
public EUDataGridResult searchDepartmentByDepartmentId(Integer page, Integer rows, String departmentId) throws Exception {
    // 分页处理
    PageHelper.startPage(page, rows);
    List<Department> list = departmentMapper.searchDepartmentByDepartmentId(departmentId);
    // 创建一个返回值对象
    EUDataGridResult result = new EUDataGridResult();
    result.setRows(list);
    // 取记录总条数
    PageInfo<Department> pageInfo = new PageInfo<>(list);
    result.setTotal(pageInfo.getTotal());
    return result;
}
Also used : Department(com.megagao.production.ssm.domain.Department) PageInfo(com.github.pagehelper.PageInfo) EUDataGridResult(com.megagao.production.ssm.domain.customize.EUDataGridResult)

Example 59 with PageInfo

use of com.github.pagehelper.PageInfo in project production_ssm by megagao.

the class DepartmentServiceImpl method searchDepartmentByDepartmentName.

@Override
public EUDataGridResult searchDepartmentByDepartmentName(Integer page, Integer rows, String departmentName) throws Exception {
    // 分页处理
    PageHelper.startPage(page, rows);
    List<Department> list = departmentMapper.searchDepartmentByDepartmentName(departmentName);
    // 创建一个返回值对象
    EUDataGridResult result = new EUDataGridResult();
    result.setRows(list);
    // 取记录总条数
    PageInfo<Department> pageInfo = new PageInfo<>(list);
    result.setTotal(pageInfo.getTotal());
    return result;
}
Also used : Department(com.megagao.production.ssm.domain.Department) PageInfo(com.github.pagehelper.PageInfo) EUDataGridResult(com.megagao.production.ssm.domain.customize.EUDataGridResult)

Example 60 with PageInfo

use of com.github.pagehelper.PageInfo in project production_ssm by megagao.

the class DeviceFaultServiceImpl method searchDeviceFaultByDeviceFaultId.

@Override
public EUDataGridResult searchDeviceFaultByDeviceFaultId(Integer page, Integer rows, String deviceFaultId) {
    // 分页处理
    PageHelper.startPage(page, rows);
    List<DeviceFault> list = deviceFaultMapper.searchDeviceFaultByDeviceFaultId(deviceFaultId);
    // 创建一个返回值对象
    EUDataGridResult result = new EUDataGridResult();
    result.setRows(list);
    // 取记录总条数
    PageInfo<DeviceFault> pageInfo = new PageInfo<>(list);
    result.setTotal(pageInfo.getTotal());
    return result;
}
Also used : PageInfo(com.github.pagehelper.PageInfo) DeviceFault(com.megagao.production.ssm.domain.DeviceFault) EUDataGridResult(com.megagao.production.ssm.domain.customize.EUDataGridResult)

Aggregations

PageInfo (com.github.pagehelper.PageInfo)273 PostMapping (org.springframework.web.bind.annotation.PostMapping)96 EUDataGridResult (com.megagao.production.ssm.domain.customize.EUDataGridResult)90 Test (org.junit.Test)21 UserMapper (com.github.pagehelper.mapper.UserMapper)17 User (com.github.pagehelper.model.User)17 SqlSession (org.apache.ibatis.session.SqlSession)17 ApiOperation (io.swagger.annotations.ApiOperation)14 TaskRecordDetail (com.eservice.api.model.task_record.TaskRecordDetail)11 Condition (tk.mybatis.mapper.entity.Condition)9 DataTablesResult (cn.exrick.common.pojo.DataTablesResult)7 ArrayList (java.util.ArrayList)7 Criteria (tk.mybatis.mapper.entity.Example.Criteria)6 TaskRecord (com.eservice.api.model.task_record.TaskRecord)4 Product (com.megagao.production.ssm.domain.Product)4 Task (com.megagao.production.ssm.domain.Task)4 ManufactureVO (com.megagao.production.ssm.domain.vo.ManufactureVO)4 WorkVO (com.megagao.production.ssm.domain.vo.WorkVO)4 MachineInfo (com.eservice.api.model.machine.MachineInfo)3 User (com.eservice.api.model.user.User)3