mirror of https://github.com/abpframework/abp
Merge pull request #17422 from abpframework/auto-merge/rel-7-4/2132
Merge branch dev with rel-7.4pull/17423/head
commit
db551080e9
@ -0,0 +1,20 @@
|
||||
using System;
|
||||
using Hangfire;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Volo.Abp.BackgroundJobs.Hangfire;
|
||||
|
||||
namespace Microsoft.AspNetCore.Builder;
|
||||
|
||||
public static class AbpHangfireApplicationBuilderExtensions
|
||||
{
|
||||
public static IApplicationBuilder UseAbpHangfireDashboard(
|
||||
this IApplicationBuilder app,
|
||||
string pathMatch = "/hangfire",
|
||||
Action<DashboardOptions>? configure = null,
|
||||
JobStorage? storage = null)
|
||||
{
|
||||
var options = app.ApplicationServices.GetRequiredService<AbpDashboardOptionsProvider>().Get();
|
||||
configure?.Invoke(options);
|
||||
return app.UseHangfireDashboard(pathMatch, options, storage);
|
||||
}
|
||||
}
|
Loading…
Reference in new issue