use of com.github.pagehelper.PageInfo in project sinsim by WilsonHu.
the class MachineTypeController method selectAfterN.
/**
* 查询机器类型,从第N个开始的机器类型
* 机型名称改了,之前的名称以后不用了,但是在旧订单里还要用所以无法删除。
* 返回N个之后的机型(即所有新的机型名称)用于新订单
*/
@PostMapping("/selectAfterN")
public Result selectAfterN(@RequestParam(defaultValue = "0") Integer page, @RequestParam(defaultValue = "0") Integer size) {
// PageHelper.startPage(page, size);// 这一行加了,会出错:IndexOutOfBoundsException: Index: 0, Size: 0
// PageHelper.startPage(page, 20);
//
List<MachineType> list = machineTypeService.selectAfterN(23);
PageInfo pageInfo = new PageInfo(list);
return ResultGenerator.genSuccessResult(pageInfo);
}
use of com.github.pagehelper.PageInfo in project sinsim by WilsonHu.
the class OrderChangeRecordController method list.
@PostMapping("/list")
public Result list(@RequestParam(defaultValue = "0") Integer page, @RequestParam(defaultValue = "0") Integer size) {
PageHelper.startPage(page, size);
List<OrderChangeRecord> list = orderChangeRecordService.findAll();
PageInfo pageInfo = new PageInfo(list);
return ResultGenerator.genSuccessResult(pageInfo);
}
use of com.github.pagehelper.PageInfo in project sinsim by WilsonHu.
the class OrderChangeRecordController method getChangeRecordList.
@PostMapping("/getChangeRecordList")
public Result getChangeRecordList(@RequestParam(defaultValue = "0") Integer page, @RequestParam(defaultValue = "0") Integer size, @RequestParam Integer id, @RequestParam Integer orderId) {
PageHelper.startPage(page, size);
List<OrderChangeRecordView> list = orderChangeRecordService.getChangeRecordList(id, orderId);
PageInfo pageInfo = new PageInfo(list);
return ResultGenerator.genSuccessResult(pageInfo);
}
use of com.github.pagehelper.PageInfo in project sinsim by WilsonHu.
the class OrderSignController method getOrderSignListByOrderId.
/**
* 根据orderId获取签核信息
*
* @param orderId
* @return 订单的签核记录只有在新增合同-订单时,才创建订单的签核记录,所以这里其实只返回一个签核记录,先保留这样用list
* (之前考虑过比如驳回造成的多次签核的分别放在不同的签核记录里,最后其实是放在同个签核记录里)
*/
@PostMapping("/getOrderSignListByOrderId")
public Result getOrderSignListByOrderId(@RequestParam(defaultValue = "0") Integer page, @RequestParam(defaultValue = "0") Integer size, @RequestParam Integer orderId) {
PageHelper.startPage(page, size);
List<OrderSign> list = orderSignService.getOrderSignListByOrderId(orderId);
PageInfo pageInfo = new PageInfo(list);
return ResultGenerator.genSuccessResult(pageInfo);
}
use of com.github.pagehelper.PageInfo in project sinsim by WilsonHu.
the class ProcessController method list.
@PostMapping("/list")
public Result list(@RequestParam(defaultValue = "0") Integer page, @RequestParam(defaultValue = "0") Integer size) {
PageHelper.startPage(page, size);
List<Process> list = processService.findAll();
PageInfo pageInfo = new PageInfo(list);
return ResultGenerator.genSuccessResult(pageInfo);
}
Aggregations