‘liusuyi’
2023-07-27 4155135bb0247685ce3652fe0257c39ff3e21ced
ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysUser.java
@@ -139,9 +139,34 @@
     * 用户融云token
     */
    private String rongCloudToken;
    /**
     * app用户类型
     * 0-app指挥端 1-app单兵端 空-pc端
     */
    private String appUserType;
    /**
     * 关联报警类型组
     */
    private List<String> commands;
    public SysUser() {
    }
    public String getAppUserType() {
        return appUserType;
    }
    public void setAppUserType(String appUserType) {
        this.appUserType = appUserType;
    }
    public List<String> getCommands() {
        return commands;
    }
    public void setCommands(List<String> commands) {
        this.commands = commands;
    }
    public String getRongCloudToken() {
@@ -178,17 +203,6 @@
    public static boolean isAdmin(String userId) {
        return userId != null && userId.equals("1");
    }
    /**
     * 是否app指挥端
     */
    public boolean isAppLeader() {
        return isAppLeader(this.userId);
    }
    public boolean isAppLeader(String userId) {
        return userId != null && this.getRoles().stream().anyMatch(sysRole -> sysRole.getRoleKey().contains("appLeader"));
    }
    public Long getDeptId() {