aa54d93e8e
Provides a noticeboard for all devices, not just those assigned to users.
598 lines
16 KiB
C#
598 lines
16 KiB
C#
#pragma warning disable 1591
|
|
//------------------------------------------------------------------------------
|
|
// <auto-generated>
|
|
// This code was generated by a tool.
|
|
// Runtime Version:4.0.30319.18033
|
|
//
|
|
// Changes to this file may cause incorrect behavior and will be lost if
|
|
// the code is regenerated.
|
|
// </auto-generated>
|
|
//------------------------------------------------------------------------------
|
|
|
|
namespace Disco.Web.Areas.Public.Views.HeldDevices
|
|
{
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.IO;
|
|
using System.Linq;
|
|
using System.Net;
|
|
using System.Text;
|
|
using System.Web;
|
|
using System.Web.Helpers;
|
|
using System.Web.Mvc;
|
|
using System.Web.Mvc.Ajax;
|
|
using System.Web.Mvc.Html;
|
|
using System.Web.Routing;
|
|
using System.Web.Security;
|
|
using System.Web.UI;
|
|
using System.Web.WebPages;
|
|
using Disco.BI.Extensions;
|
|
using Disco.Models.Repository;
|
|
using Disco.Web;
|
|
using Disco.Web.Extensions;
|
|
|
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("RazorGenerator", "2.0.0.0")]
|
|
[System.Web.WebPages.PageVirtualPathAttribute("~/Areas/Public/Views/HeldDevices/Index.cshtml")]
|
|
public partial class Index : System.Web.Mvc.WebViewPage<IEnumerable<Disco.Web.Areas.Public.Models.HeldDevices.HeldDeviceModel>>
|
|
{
|
|
public Index()
|
|
{
|
|
}
|
|
public override void Execute()
|
|
{
|
|
|
|
#line 2 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
ViewBag.Title = Html.ToBreadcrumb("Public Reports", MVC.Public.Public.Index(), "Held Devices", null);
|
|
Html.BundleDeferred("~/Style/Public/HeldDevices");
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n<div");
|
|
|
|
WriteLiteral(" class=\"clearfix page\"");
|
|
|
|
WriteLiteral(">\r\n <div");
|
|
|
|
WriteLiteral(" class=\"column1\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
|
|
#line 8 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 8 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
var DevicesInProcess = Model.Where(i => !i.ReadyForReturn && !i.WaitingForUserAction).ToArray();
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n <h2>In Process (");
|
|
|
|
|
|
#line 11 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(DevicesInProcess.Length);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(")</h2>\r\n <table");
|
|
|
|
WriteLiteral(" class=\"dataTable\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
|
|
#line 13 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 13 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
foreach (var item in DevicesInProcess)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr>\r\n <td");
|
|
|
|
WriteLiteral(" class=\"id\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 17 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.DeviceSerialNumber);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n </td>\r\n <td");
|
|
|
|
WriteLiteral(" class=\"description\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
|
|
#line 20 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 20 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
if (item.UserId != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <span");
|
|
|
|
WriteLiteral(" class=\"user\"");
|
|
|
|
WriteLiteral(">");
|
|
|
|
|
|
#line 22 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.UserDisplayName);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" (");
|
|
|
|
|
|
#line 22 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.UserId);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(")</span>\r\n");
|
|
|
|
|
|
#line 23 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 24 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
if (!string.IsNullOrWhiteSpace(item.DeviceLocation))
|
|
{
|
|
if (item.UserId != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
WriteLiteral(" - ");
|
|
|
|
WriteLiteral("\r\n");
|
|
|
|
|
|
#line 29 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 30 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.DeviceLocation);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 30 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
}
|
|
else
|
|
{
|
|
if (item.UserId == null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 36 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.DeviceComputerName);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 36 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
}
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 39 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
if (!string.IsNullOrEmpty(item.EstimatedReturnTime))
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <span");
|
|
|
|
WriteLiteral(" class=\"smallMessage\"");
|
|
|
|
WriteLiteral(">(Expected: ");
|
|
|
|
|
|
#line 41 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.EstimatedReturnTime);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(")</span>\r\n");
|
|
|
|
|
|
#line 42 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 45 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </table>\r\n </div>\r\n <div");
|
|
|
|
WriteLiteral(" class=\"column2\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
|
|
#line 49 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 49 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
var WaitingForUserActionJobs = Model.Where(i => i.WaitingForUserAction).ToArray();
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n <h2>Waiting for User Action (");
|
|
|
|
|
|
#line 52 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(WaitingForUserActionJobs.Length);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(")</h2>\r\n <table");
|
|
|
|
WriteLiteral(" class=\"dataTable\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
|
|
#line 54 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 54 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
foreach (var item in WaitingForUserActionJobs)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr>\r\n <td");
|
|
|
|
WriteLiteral(" class=\"id\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 58 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.DeviceSerialNumber);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n </td>\r\n <td");
|
|
|
|
WriteLiteral(" class=\"description\"");
|
|
|
|
WriteLiteral(">\r\n <span");
|
|
|
|
WriteLiteral(" class=\"user\"");
|
|
|
|
WriteLiteral(">");
|
|
|
|
|
|
#line 61 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.UserDisplayName);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" (");
|
|
|
|
|
|
#line 61 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.UserId);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(")</span>\r\n");
|
|
|
|
|
|
#line 62 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 62 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
if (!string.IsNullOrWhiteSpace(item.DeviceLocation))
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
WriteLiteral(" - ");
|
|
|
|
|
|
#line 64 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 64 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.DeviceLocation);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 64 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n <td");
|
|
|
|
WriteAttribute("class", Tuple.Create(" class=\"", 2758), Tuple.Create("\"", 2816)
|
|
, Tuple.Create(Tuple.Create("", 2766), Tuple.Create("timestamp", 2766), true)
|
|
|
|
#line 67 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
, Tuple.Create(Tuple.Create("", 2775), Tuple.Create<System.Object, System.Int32>(item.IsAlert ? " Alert" : string.Empty
|
|
|
|
#line default
|
|
#line hidden
|
|
, 2775), false)
|
|
);
|
|
|
|
WriteLiteral(">Since ");
|
|
|
|
|
|
#line 67 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.WaitingForUserActionSince);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 70 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </table>\r\n <hr />\r\n");
|
|
|
|
|
|
#line 73 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 73 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
var DevicesReadyForReturn = Model.Where(i => i.ReadyForReturn && !i.WaitingForUserAction).ToArray();
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n <h2>Ready for Return (");
|
|
|
|
|
|
#line 76 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(DevicesReadyForReturn.Length);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(")</h2>\r\n <table");
|
|
|
|
WriteLiteral(" class=\"dataTable\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
|
|
#line 78 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 78 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
foreach (var item in DevicesReadyForReturn)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr>\r\n <td");
|
|
|
|
WriteLiteral(" class=\"id\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 82 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.DeviceSerialNumber);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n </td>\r\n <td");
|
|
|
|
WriteLiteral(" class=\"description\"");
|
|
|
|
WriteLiteral(">\r\n <span");
|
|
|
|
WriteLiteral(" class=\"user\"");
|
|
|
|
WriteLiteral(">");
|
|
|
|
|
|
#line 85 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.UserDisplayName);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" (");
|
|
|
|
|
|
#line 85 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.UserId);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(")</span>\r\n");
|
|
|
|
|
|
#line 86 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 86 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
if (!string.IsNullOrWhiteSpace(item.DeviceLocation))
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
WriteLiteral(" - ");
|
|
|
|
|
|
#line 88 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 88 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.DeviceLocation);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 88 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n <td");
|
|
|
|
WriteAttribute("class", Tuple.Create(" class=\"", 3787), Tuple.Create("\"", 3845)
|
|
, Tuple.Create(Tuple.Create("", 3795), Tuple.Create("timestamp", 3795), true)
|
|
|
|
#line 91 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
, Tuple.Create(Tuple.Create("", 3804), Tuple.Create<System.Object, System.Int32>(item.IsAlert ? " Alert" : string.Empty
|
|
|
|
#line default
|
|
#line hidden
|
|
, 3804), false)
|
|
);
|
|
|
|
WriteLiteral(">Ready ");
|
|
|
|
|
|
#line 91 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
Write(item.ReadyForReturnSince);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 94 "..\..\Areas\Public\Views\HeldDevices\Index.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </table>\r\n </div>\r\n</div>\r\n");
|
|
|
|
}
|
|
}
|
|
}
|
|
#pragma warning restore 1591
|