Fixiaobai
2023-08-28 1865de1cd0255f7c42a326018a8cc3b5a1ee5253
inspection-server/src/main/java/com/yuanchu/limslaboratory/controller/InspectionController.java
@@ -6,6 +6,7 @@
import java.util.*;
import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
import com.yuanchu.limslaboratory.annotation.AuthHandler;
import com.yuanchu.limslaboratory.mapper.UserMapper;
import com.yuanchu.limslaboratory.pojo.Inspection;
import com.yuanchu.limslaboratory.pojo.Report;
@@ -57,6 +58,7 @@
            @ApiImplicitParam(name = "message", value = "申请单号/原材料名称", dataTypeClass = String.class)
    })
    @GetMapping("/selectInspectsList")
    @AuthHandler
    public Result selectInspectsList(int pageSize, int countSize, String message) {
        IPage<Map<String, Object>> inspectionPage = inspectionService.selectInspectsList(new Page<Object>(pageSize, countSize), message);
        Map<String, Object> map = new HashMap<>();
@@ -71,6 +73,7 @@
            @ApiImplicitParam(name = "type", value = "类型", dataTypeClass = Integer.class, required = true)
    })
    @GetMapping("/selectAll")
    @AuthHandler
    public Result selectAll(Integer type) {
        switch (type) {
            case 0:
@@ -93,9 +96,23 @@
            @ApiImplicitParam(name = "specifications", value = "规格型号", dataTypeClass = String.class, required = true)
    })
    @GetMapping("/chooseVer")
    @AuthHandler
    public Result chooseVer(String name, String mcode, String specifications) {
        return Result.success(inspectionService.chooseVer(name, mcode, specifications));
    }
    @ApiOperation(value = "新增检验单-->选择检验项目版本-->查看该版本下我们要做的项目要求")
    @ApiImplicitParams(value = {
            @ApiImplicitParam(name = "name", value = "产品名称", dataTypeClass = String.class, required = true),
            @ApiImplicitParam(name = "mcode", value = "产品编号", dataTypeClass = String.class, required = true),
            @ApiImplicitParam(name = "specifications", value = "规格型号", dataTypeClass = String.class, required = true),
            @ApiImplicitParam(name = "version", value = "版本(默认最新版本)", dataTypeClass = Integer.class,required = true ),
            @ApiImplicitParam(name = "experiment", value = "试验项目(委托专属)", dataTypeClass = String.class )
    })
    @GetMapping("/lookProByVer")
    @AuthHandler
    public Result lookProByVer(String name, String mcode, String specifications,Integer version,String experiment) {
        return Result.success(inspectionService.lookProByVer(name, mcode, specifications,version,experiment));
    }
    @ApiOperation(value = "新增检验单")