|
|
|
@ -171,6 +171,13 @@ namespace Volo.Abp.AspNetCore.Mvc.Conventions |
|
|
|
{ |
|
|
|
RemoveEmptySelectors(controller.Selectors); |
|
|
|
|
|
|
|
var controllerType = controller.ControllerType.AsType(); |
|
|
|
var remoteServiceAtt = ReflectionHelper.GetSingleAttributeOrDefault<RemoteServiceAttribute>(controllerType.GetTypeInfo()); |
|
|
|
if (remoteServiceAtt != null && !remoteServiceAtt.IsEnabledFor(controllerType)) |
|
|
|
{ |
|
|
|
return; |
|
|
|
} |
|
|
|
|
|
|
|
if (controller.Selectors.Any(selector => selector.AttributeRouteModel != null)) |
|
|
|
{ |
|
|
|
return; |
|
|
|
@ -188,6 +195,12 @@ namespace Volo.Abp.AspNetCore.Mvc.Conventions |
|
|
|
{ |
|
|
|
RemoveEmptySelectors(action.Selectors); |
|
|
|
|
|
|
|
var remoteServiceAtt = ReflectionHelper.GetSingleAttributeOrDefault<RemoteServiceAttribute>(action.ActionMethod); |
|
|
|
if (remoteServiceAtt != null && !remoteServiceAtt.IsEnabledFor(action.ActionMethod)) |
|
|
|
{ |
|
|
|
return; |
|
|
|
} |
|
|
|
|
|
|
|
if (!action.Selectors.Any()) |
|
|
|
{ |
|
|
|
AddAbpServiceSelector(rootPath, controllerName, action, configuration); |
|
|
|
|