|
|
|
@ -41,12 +41,6 @@ public class Token implements Serializable {
|
|
|
|
|
private Set<String> resSet = new HashSet<>();
|
|
|
|
|
|
|
|
|
|
public boolean hasRes(String res) {
|
|
|
|
|
for (String s : resSet) {
|
|
|
|
|
if (res.matches(s)) {
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
String[] profiles = LocalData.getEnvironment().getActiveProfiles();
|
|
|
|
|
for (String profile : profiles) {
|
|
|
|
|
if (profile.contains("dev")) {//测试环境捕获资源
|
|
|
|
@ -68,6 +62,12 @@ public class Token implements Serializable {
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
for (String s : resSet) {
|
|
|
|
|
if (res.matches(s)) {
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|