Bug Fix: Job Index Authorization Check
The LongRunningJobs claim is checked instead of the StaleJobs claim which resulted in an NullReferenceException for users without StaleJobs authorization.
This commit is contained in:
@@ -129,7 +129,7 @@
|
|||||||
<h2>My Jobs (@Model.MyJobs.Items.Count())</h2>
|
<h2>My Jobs (@Model.MyJobs.Items.Count())</h2>
|
||||||
@Html.Partial(MVC.Shared.Views._JobTable, Model.MyJobs, new ViewDataDictionary())
|
@Html.Partial(MVC.Shared.Views._JobTable, Model.MyJobs, new ViewDataDictionary())
|
||||||
}
|
}
|
||||||
@if (Authorization.Has(Claims.Job.Lists.LongRunningJobs))
|
@if (Authorization.Has(Claims.Job.Lists.StaleJobs))
|
||||||
{
|
{
|
||||||
<h2>Stale Jobs (@Model.StaleJobs.Items.Count())</h2>
|
<h2>Stale Jobs (@Model.StaleJobs.Items.Count())</h2>
|
||||||
@Html.Partial(MVC.Shared.Views._JobTable, Model.StaleJobs, new ViewDataDictionary())
|
@Html.Partial(MVC.Shared.Views._JobTable, Model.StaleJobs, new ViewDataDictionary())
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
// <auto-generated>
|
// <auto-generated>
|
||||||
// This code was generated by a tool.
|
// This code was generated by a tool.
|
||||||
// Runtime Version:4.0.30319.34003
|
// Runtime Version:4.0.30319.34011
|
||||||
//
|
//
|
||||||
// Changes to this file may cause incorrect behavior and will be lost if
|
// Changes to this file may cause incorrect behavior and will be lost if
|
||||||
// the code is regenerated.
|
// the code is regenerated.
|
||||||
@@ -260,7 +260,7 @@ Write(Html.Partial(MVC.Shared.Views._JobTable, Model.MyJobs, new ViewDataDiction
|
|||||||
#line hidden
|
#line hidden
|
||||||
|
|
||||||
#line 132 "..\..\Views\Job\Index.cshtml"
|
#line 132 "..\..\Views\Job\Index.cshtml"
|
||||||
if (Authorization.Has(Claims.Job.Lists.LongRunningJobs))
|
if (Authorization.Has(Claims.Job.Lists.StaleJobs))
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user