Browse Source

优化数据权限获取

master
WendyYang 1 year ago
parent
commit
15c6320a97
1 changed files with 2 additions and 3 deletions
  1. +2
    -3
      pmapi/src/main/java/com/ningdatech/pmapi/datascope/provider/DataScopeContext.java

+ 2
- 3
pmapi/src/main/java/com/ningdatech/pmapi/datascope/provider/DataScopeContext.java View File

@@ -28,10 +28,9 @@ public class DataScopeContext implements Serializable {
}

public static Optional<DataScopeDTO> getDataScope(String roleCode) {
String key = roleCode;
DataScopeProvider dataScopeProvider = DSP_MAP.get(key);
DataScopeProvider dataScopeProvider = DSP_MAP.get(roleCode);
if (dataScopeProvider == null) {
throw new IllegalArgumentException(String.format(WARN_MSG, key));
throw new IllegalArgumentException(String.format(WARN_MSG, roleCode));
}
return dataScopeProvider.findDataFieldProperty();
}


Loading…
Cancel
Save