XiaoRuby
2023-07-27 b7145c10db0d3ace368689edfebb850760632c79
standard-server/src/main/java/com/yuanchu/limslaboratory/controller/ProductController.java
@@ -33,11 +33,12 @@
    @ApiImplicitParams(value = {
            @ApiImplicitParam(name = "pageNo", value = "起始页", dataTypeClass = Integer.class, required = true),
            @ApiImplicitParam(name = "pageSize", value = "每一页数量", dataTypeClass = Integer.class, required = true),
            @ApiImplicitParam(name = "specificationsId", value = "规格型号ID", dataTypeClass = Integer.class, required = true),
            @ApiImplicitParam(value = "原材料编码/原材料名称", name = "productCodeOrName", dataTypeClass = String.class)
    })
    @GetMapping("/page")
    public Result<?> pageProductInformation(Integer pageNo, Integer pageSize,String productCodeOrName) {
        IPage<Map<String, Object>> maps = productService.pageProductInformation(productCodeOrName, new Page<Objects>(pageNo, pageSize));
    public Result<?> pageProductInformation(Integer pageNo, Integer pageSize, Integer specificationsId, String productCodeOrName) {
        IPage<Map<String, Object>> maps = productService.pageProductInformation(productCodeOrName, specificationsId, new Page<Objects>(pageNo, pageSize));
        Map<String, Object> map = new HashMap<>();
        map.put("row", maps.getRecords());
        map.put("total", maps.getTotal());