| | |
| | | package com.ruoyi.common.enums; |
| | | |
| | | import com.ruoyi.common.utils.StringUtils; |
| | | import lombok.AllArgsConstructor; |
| | | import lombok.Getter; |
| | | |
| | | /** |
| | | * 设备类型 |
| | | * 针对两套 用户体系 |
| | | * 针对多套 用户体系 |
| | | * |
| | | * @author Lion Li |
| | | */ |
| | |
| | | /** |
| | | * pc端 |
| | | */ |
| | | SYS_USER("sys_user:"), |
| | | SYS_USER("sys_user"), |
| | | |
| | | /** |
| | | * app端 |
| | | */ |
| | | APP_USER("app_user:"); |
| | | APP_USER("app_user"); |
| | | |
| | | private final String userType; |
| | | |
| | | public static UserType getUserType(String str) { |
| | | for (UserType value : values()) { |
| | | if (StringUtils.contains(str, value.getUserType())) { |
| | | return value; |
| | | } |
| | | } |
| | | throw new RuntimeException("'UserType' not found By " + str); |
| | | } |
| | | } |