fuliqi
2024-06-12 8bcc04c9623e0eee0995e1139dee6258a8df464d
src/main/java/com/ycl/jxkg/controller/admin/ExamTemplateController.java
@@ -50,6 +50,10 @@
    @PutMapping
    @ApiOperation(value = "修改", notes = "修改")
    public Result update(@RequestBody @Validated(Update.class) ExamTemplateForm form) {
        //参数校验
        if(form.getDeductType()!=null && (form.getDeductType() ==PartCorrect.getCode() || form.getDeductType() == EachCorrect.getCode()) && (form.getDeductTypeScore() ==null || form.getDeductTypeScore().compareTo(BigDecimal.ZERO) <= 0)){
            return Result.fail(SystemCode.ParameterValidError.getCode(),"多选评分不能为0或空");
        }
        return examTemplateService.update(form);
    }