Skip to content
Open
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 @@ -37,6 +37,8 @@ public AspNetCoreDashboardRequest([NotNull] HttpContext context)
public override string PathBase => _context.Request.PathBase.Value;
public override string LocalIpAddress => _context.Connection.LocalIpAddress.ToString();
public override string RemoteIpAddress => _context.Connection.RemoteIpAddress.ToString();

public override string QueryString => _context.Request.QueryString.Value;
public override string GetQuery(string key) => _context.Request.Query[key];

public override async Task<IList<string>> GetFormValuesAsync(string key)
Expand Down
3 changes: 3 additions & 0 deletions src/Hangfire.Core/Dashboard/DashboardRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,10 @@ public abstract class DashboardRequest
public abstract string LocalIpAddress { get; }
public abstract string RemoteIpAddress { get; }

public abstract string QueryString { get; }

public abstract string GetQuery(string key);

public abstract Task<IList<string>> GetFormValuesAsync(string key);
}
}
1 change: 1 addition & 0 deletions src/Hangfire.Core/Dashboard/Owin/OwinDashboardRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ public OwinDashboardRequest([NotNull] IDictionary<string, object> environment)
public override string PathBase => _context.Request.PathBase.Value;
public override string LocalIpAddress => _context.Request.LocalIpAddress;
public override string RemoteIpAddress => _context.Request.RemoteIpAddress;
public override string QueryString => _context.Request.QueryString.ToString();

public override string GetQuery(string key) => _context.Request.Query[key];

Expand Down
3 changes: 2 additions & 1 deletion src/Hangfire.Core/Dashboard/UrlHelper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,8 @@ public string To(string relativePath)
#endif
_context.Request.PathBase
+ relativePath
);
)
+ _context.Request.QueryString;
}

public string Home()
Expand Down