Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public RemoteFeatureChecker(ICachedApplicationConfigurationClient configurationC
ConfigurationClient = configurationClient;
}

public override async Task<string> GetOrNullAsync(string name)
public async override Task<string> GetOrNullAsync(string name)
{
var configuration = await ConfigurationClient.GetAsync();
return configuration.Features.Values.GetOrDefault(name);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ namespace Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Breadcrumb
{
public class AbpBreadcrumbTagHelperService : AbpTagHelperService<AbpBreadcrumbTagHelper>
{
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
output.TagName = "nav";
output.Attributes.Add("aria-label", "breadcrumb");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public AbpCarouselTagHelperService(IStringLocalizer<AbpUiResource> localizer)
L = localizer;
}

public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
output.TagName = "div";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Collapse
{
public class AbpAccordionItemTagHelperService : AbpTagHelperService<AbpAccordionItemTagHelper>
{
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
SetRandomIdIfNotProvided();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public AbpAccordionTagHelperService(IHtmlGenerator htmlGenerator)
HtmlGenerator = htmlGenerator;
}

public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
SetRandomIdIfNotProvided();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Collapse
{
public class AbpCollapseBodyTagHelperService : AbpTagHelperService<AbpCollapseBodyTagHelper>
{
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
output.TagName = "div";
output.Attributes.AddClass("collapse");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public AbpDropdownButtonTagHelperService(
_serviceProvider = serviceProvider;
}

public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
var content = await output.GetChildContentAsync();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public AbpDynamicFormTagHelperService(
_serviceProvider = serviceProvider;
}

public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
var list = InitilizeFormGroupContentsContext(context, output);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public AbpInputTagHelperService(IHtmlGenerator generator, HtmlEncoder encoder, I
_tagHelperLocalizer = tagHelperLocalizer;
}

public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
var (innerHtml, isCheckBox) = await GetFormInputGroupAsHtmlAsync(context, output);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public AbpSelectTagHelperService(
_stringLocalizerFactory = stringLocalizerFactory;
}

public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
var innerHtml = await GetFormInputGroupAsHtmlAsync(context, output);

Expand Down
Original file line number Diff line number Diff line change
@@ -1,48 +1,48 @@
using Microsoft.AspNetCore.Html;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.AspNetCore.Razor.TagHelpers;
using System.Text;
using Microsoft.AspNetCore.Razor.TagHelpers;
using System.Text;
using System.Threading.Tasks;

namespace Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Modal
{
public class AbpModalTagHelperService : AbpTagHelperService<AbpModalTagHelper>
{
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
output.TagName = null;

var childContent = await output.GetChildContentAsync();

SetContent(context, output, childContent);
}

namespace Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Modal
{
public class AbpModalTagHelperService : AbpTagHelperService<AbpModalTagHelper>
{
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
output.TagName = null;
var childContent = await output.GetChildContentAsync();
SetContent(context, output, childContent);
}
protected virtual void SetContent(TagHelperContext context, TagHelperOutput output, TagHelperContent childContent)
{
var modalContent = GetModalContentElement(context, output, childContent);
var modalDialog = GetModalDialogElement(context, output, modalContent);
var modal = GetModal(context, output, modalDialog);

output.Content.SetHtmlContent(modal);
}

}
protected virtual TagBuilder GetModalContentElement(TagHelperContext context, TagHelperOutput output, TagHelperContent childContent)
{
var element = new TagBuilder("div");
element.AddCssClass(GetModalContentClasses());
element.InnerHtml.SetHtmlContent(childContent);
return element;
}

}
protected virtual TagBuilder GetModalDialogElement(TagHelperContext context, TagHelperOutput output, IHtmlContent innerHtml)
{
var element = new TagBuilder("div");
element.AddCssClass(GetModalDialogClasses());
element.Attributes.Add("role", "document");
element.InnerHtml.SetHtmlContent(innerHtml);
return element;
}

}
protected virtual TagBuilder GetModal(TagHelperContext context, TagHelperOutput output, IHtmlContent innerHtml)
{
var element = new TagBuilder("div");
Expand All @@ -61,37 +61,37 @@ protected virtual TagBuilder GetModal(TagHelperContext context, TagHelperOutput
element.InnerHtml.SetHtmlContent(innerHtml);

return element;
}

protected virtual string GetModalClasses()
{
return "modal fade";
}

protected virtual string GetModalDialogClasses()
{
var classNames = new StringBuilder("modal-dialog");

if (TagHelper.Centered ?? false)
{
classNames.Append(" ");
classNames.Append("modal-dialog-centered");
}

if (TagHelper.Size != AbpModalSize.Default)
{
classNames.Append(" ");
classNames.Append(TagHelper.Size.ToClassName());
}

return classNames.ToString();
}

protected virtual string GetModalContentClasses()
{
return "modal-content";
}

}
protected virtual string GetModalClasses()
{
return "modal fade";
}
protected virtual string GetModalDialogClasses()
{
var classNames = new StringBuilder("modal-dialog");
if (TagHelper.Centered ?? false)
{
classNames.Append(" ");
classNames.Append("modal-dialog-centered");
}
if (TagHelper.Size != AbpModalSize.Default)
{
classNames.Append(" ");
classNames.Append(TagHelper.Size.ToClassName());
}
return classNames.ToString();
}
protected virtual string GetModalContentClasses()
{
return "modal-content";
}
protected virtual string GetDataAttributes()
{
if (TagHelper.Static == true)
Expand All @@ -107,6 +107,6 @@ protected virtual void SetDataAttributes(TagBuilder builder)
{
builder.Attributes.Add("data-backdrop", "static");
}
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public AbpPaginationTagHelperService(
_stringLocalizerFactory = stringLocalizerFactory;
}

public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
if (TagHelper.Model.ShownItemsCount <= 0)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Tab
{
public class AbpTabDropdownTagHelperService : AbpTagHelperService<AbpTabDropdownTagHelper>
{
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
if (string.IsNullOrWhiteSpace(TagHelper.Name))
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Tab
{
public class AbpTabTagHelperService : AbpTagHelperService<AbpTabTagHelper>
{
public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
SetPlaceholderForNameIfNotProvided();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public AbpTabsTagHelperService(IHtmlGenerator htmlGenerator)
HtmlGenerator = htmlGenerator;
}

public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
SetRandomNameIfNotProvided();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ protected AbpBundleItemTagHelperService(AbpTagHelperResourceService resourceServ
ResourceService = resourceService;
}

public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
var tagHelperItems = context.Items.GetOrDefault(AbpTagHelperConsts.ContextBundleItemListKey) as List<BundleTagHelperItem>;
if (tagHelperItems != null)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ protected AbpBundleTagHelperService(AbpTagHelperResourceService resourceService)
ResourceService = resourceService;
}

public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
await ResourceService.ProcessAsync(
TagHelper.ViewContext,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public AbpComponentDemoSectionTagHelper(
_guidGenerator = guidGenerator;
}

public override async Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
public async override Task ProcessAsync(TagHelperContext context, TagHelperOutput output)
{
output.TagName = null;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public AuditingInterceptor(IAuditingHelper auditingHelper, IAuditingManager audi
_auditingManager = auditingManager;
}

public override async Task InterceptAsync(IAbpMethodInvocation invocation)
public async override Task InterceptAsync(IAbpMethodInvocation invocation)
{
if (!ShouldIntercept(invocation, out var auditLog, out var auditLogAction))
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public AbpAuthorizationPolicyProvider(
_options = options.Value;
}

public override async Task<AuthorizationPolicy> GetPolicyAsync(string policyName)
public async override Task<AuthorizationPolicy> GetPolicyAsync(string policyName)
{
var policy = await base.GetPolicyAsync(policyName);
if (policy != null)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ public AuthorizationInterceptor(IMethodInvocationAuthorizationService methodInvo
_methodInvocationAuthorizationService = methodInvocationAuthorizationService;
}

public override async Task InterceptAsync(IAbpMethodInvocation invocation)
public async override Task InterceptAsync(IAbpMethodInvocation invocation)
{
await AuthorizeAsync(invocation);
await invocation.ProceedAsync();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public ClientPermissionValueProvider(IPermissionStore permissionStore)

}

public override async Task<PermissionGrantResult> CheckAsync(PermissionValueCheckContext context)
public async override Task<PermissionGrantResult> CheckAsync(PermissionValueCheckContext context)
{
var clientId = context.Principal?.FindFirst(AbpClaimTypes.ClientId)?.Value;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ public RolePermissionValueProvider(IPermissionStore permissionStore)

}

public override async Task<PermissionGrantResult> CheckAsync(PermissionValueCheckContext context)
public async override Task<PermissionGrantResult> CheckAsync(PermissionValueCheckContext context)
{
var roles = context.Principal?.FindAll(AbpClaimTypes.Role).Select(c => c.Value).ToArray();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public UserPermissionValueProvider(IPermissionStore permissionStore)

}

public override async Task<PermissionGrantResult> CheckAsync(PermissionValueCheckContext context)
public async override Task<PermissionGrantResult> CheckAsync(PermissionValueCheckContext context)
{
var userId = context.Principal?.FindFirst(AbpClaimTypes.UserId)?.Value;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public void BuildWorker(IBackgroundWorker worker)
.Build();
}

public override async Task Execute(IJobExecutionContext context)
public async override Task Execute(IJobExecutionContext context)
{
var worker = (IBackgroundWorker) ServiceProvider.GetService(typeof(TWorker));
var workerContext = new PeriodicBackgroundWorkerContext(ServiceProvider);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,13 @@ protected AsyncPeriodicBackgroundWorkerBase(
Timer.Elapsed += Timer_Elapsed;
}

public override async Task StartAsync(CancellationToken cancellationToken = default)
public async override Task StartAsync(CancellationToken cancellationToken = default)
{
await base.StartAsync(cancellationToken);
Timer.Start(cancellationToken);
}

public override async Task StopAsync(CancellationToken cancellationToken = default)
public async override Task StopAsync(CancellationToken cancellationToken = default)
{
Timer.Stop(cancellationToken);
await base.StopAsync(cancellationToken);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ protected PeriodicBackgroundWorkerBase(
Timer.Elapsed += Timer_Elapsed;
}

public override async Task StartAsync(CancellationToken cancellationToken = default)
public async override Task StartAsync(CancellationToken cancellationToken = default)
{
await base.StartAsync(cancellationToken);
Timer.Start(cancellationToken);
}

public override async Task StopAsync(CancellationToken cancellationToken = default)
public async override Task StopAsync(CancellationToken cancellationToken = default)
{
Timer.Stop(cancellationToken);
await base.StopAsync(cancellationToken);
Expand Down
Loading