|
|
@ -194,7 +194,7 @@ public class InteractiveServiceImpl implements IInteractiveService { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public Boolean authentication(String stationId, String userId, String funcCode) { |
|
|
|
public Boolean authentication(String stationId, String userId, String func) { |
|
|
|
// 站点鉴权
|
|
|
|
// 站点鉴权
|
|
|
|
if(StringUtil.isNotBlank(stationId)) { |
|
|
|
if(StringUtil.isNotBlank(stationId)) { |
|
|
|
List<String> stations = this.getStationPermissionsById(userId).stream().map(DeptStationDTO::getStationId) |
|
|
|
List<String> stations = this.getStationPermissionsById(userId).stream().map(DeptStationDTO::getStationId) |
|
|
@ -204,9 +204,9 @@ public class InteractiveServiceImpl implements IInteractiveService { |
|
|
|
}); |
|
|
|
}); |
|
|
|
} |
|
|
|
} |
|
|
|
// 菜单鉴权
|
|
|
|
// 菜单鉴权
|
|
|
|
if(StringUtil.isNotBlank(funcCode) && StringUtil.isNotBlank(userId)) { |
|
|
|
if(StringUtil.isNotBlank(func) && StringUtil.isNotBlank(userId)) { |
|
|
|
FunctionEntity function = functionService.getFunctionByCode(funcCode); |
|
|
|
FunctionEntity function = functionService.getFunctionByCode(func); |
|
|
|
if(Func.isNotEmpty(function.getRoute()) && StringUtil.isNotBlank(function.getRoute())) { |
|
|
|
if(Func.isNotEmpty(function) && Func.isNotEmpty(function.getRoute()) && StringUtil.isNotBlank(function.getRoute())) { |
|
|
|
R<Boolean> authenticationR = userClient.permissionMenuById(Long.valueOf(userId), function.getRoute()); |
|
|
|
R<Boolean> authenticationR = userClient.permissionMenuById(Long.valueOf(userId), function.getRoute()); |
|
|
|
Assert.isTrue(authenticationR.isSuccess() && authenticationR.getData(), () -> { |
|
|
|
Assert.isTrue(authenticationR.isSuccess() && authenticationR.getData(), () -> { |
|
|
|
throw new ServiceException("人员菜单鉴权失败!"); |
|
|
|
throw new ServiceException("人员菜单鉴权失败!"); |
|
|
|