cloud-modules-system/src/main/java/com/muyu/system/domain/SysMenu.java

139 lines
2.6 KiB
Java
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

package com.muyu.system.domain;
import com.muyu.common.core.web.domain.BaseEntity;
import lombok.*;
import lombok.experimental.SuperBuilder;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;
import java.util.ArrayList;
import java.util.List;
/**
* 菜单权限表 sys_menu
*
* @author muyu
*/
@Data
@SuperBuilder
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper = true)
public class SysMenu extends BaseEntity {
private static final long serialVersionUID = 1L;
/**
* 菜单ID
*/
private Long menuId;
/**
* 菜单名称
*/
private String menuName;
/**
* 父菜单名称
*/
private String parentName;
/**
* 父菜单ID
*/
private Long parentId;
/**
* 显示顺序
*/
private Integer orderNum;
/**
* 路由地址
*/
private String path;
/**
* 组件路径
*/
private String component;
/**
* 路由参数
*/
private String query;
/**
* 是否为外链0是 1否
*/
private String isFrame;
/**
* 是否缓存0缓存 1不缓存
*/
private String isCache;
/**
* 类型M目录 C菜单 F按钮
*/
private String menuType;
/**
* 显示状态0显示 1隐藏
*/
private String visible;
/**
* 菜单状态0正常 1停用
*/
private String status;
/**
* 权限字符串
*/
private String perms;
/**
* 菜单图标
*/
private String icon;
/**
* 子菜单
*/
@Builder.Default
private List<SysMenu> children = new ArrayList<SysMenu>();
@NotBlank(message = "菜单名称不能为空")
@Size(min = 0, max = 50, message = "菜单名称长度不能超过50个字符")
public String getMenuName () {
return menuName;
}
@NotNull(message = "显示顺序不能为空")
public Integer getOrderNum () {
return orderNum;
}
@Size(min = 0, max = 200, message = "路由地址不能超过200个字符")
public String getPath () {
return path;
}
@Size(min = 0, max = 200, message = "组件路径不能超过255个字符")
public String getComponent () {
return component;
}
@NotBlank(message = "菜单类型不能为空")
public String getMenuType () {
return menuType;
}
@Size(min = 0, max = 100, message = "权限标识长度不能超过100个字符")
public String getPerms () {
return perms;
}
}