mirror of
https://gitee.com/huangge1199_admin/vue-pro.git
synced 2024-11-26 17:21:53 +08:00
代码生成时,如果是管理后台,必须设置菜单
This commit is contained in:
parent
6f8baa3110
commit
c11a14b9da
@ -37,7 +37,7 @@ public class CodegenUpdateReqVO {
|
||||
@ApiModelProperty(value = "编号", required = true, example = "1")
|
||||
private Long id;
|
||||
|
||||
@AssertTrue(message = "生成失败,必须设置上级菜单")
|
||||
@AssertTrue(message = "上级菜单不能为空")
|
||||
public boolean isParentMenuIdValid() {
|
||||
// 生成场景为管理后台时,必须设置上级菜单,不然生成的菜单 SQL 是无父级菜单的
|
||||
return ObjectUtil.notEqual(getScene(), CodegenSceneEnum.ADMIN.getScene())
|
||||
|
Loading…
Reference in New Issue
Block a user