Skip to content

@Ignore 支持分组功能 #133

Description

@cup-of-latte

首先感谢作者开发的如此方便好用的文档工具
希望 @ignore 用在实体字段支持@notblank的分组功能,这样对于不同的接口可以分组忽略
(hibernate-validator 的 groups = UpdateGroup.class)

    @Ignore
    @NotBlank(message = "表单ID不能为空",groups = UpdateGroup.class)
    private String formId; 
 ---------------------------------------------------
    /**
     * 修改表单模板
     * @param form
     */
    @PutMapping("/form")
    public ResultData editForm(@RequestBody @Validated(UpdateGroup.class) DictFormEntity form) {
            return dictFormService.update(form);
    }

因为新增的时候是不要formId的,而修改是必须要formId的,如果加了@ignore生成的文档就都没有formId了
希望@ignore支持分组能够使2个接口分别用不同策略生成文档
谢谢

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions