1924 lines
67 KiB
C#
1924 lines
67 KiB
C#
#pragma warning disable 1591
|
|
//------------------------------------------------------------------------------
|
|
// <auto-generated>
|
|
// This code was generated by a tool.
|
|
// Runtime Version:4.0.30319.42000
|
|
//
|
|
// Changes to this file may cause incorrect behavior and will be lost if
|
|
// the code is regenerated.
|
|
// </auto-generated>
|
|
//------------------------------------------------------------------------------
|
|
|
|
namespace Disco.Web.Views.Device.DeviceParts
|
|
{
|
|
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;
|
|
using Disco.Models.Repository;
|
|
using Disco.Services;
|
|
using Disco.Services.Authorization;
|
|
using Disco.Services.Web;
|
|
using Disco.Web;
|
|
using Disco.Web.Extensions;
|
|
|
|
[System.CodeDom.Compiler.GeneratedCodeAttribute("RazorGenerator", "2.0.0.0")]
|
|
[System.Web.WebPages.PageVirtualPathAttribute("~/Views/Device/DeviceParts/_Details.cshtml")]
|
|
public partial class _Details : Disco.Services.Web.WebViewPage<Disco.Web.Models.Device.ShowModel>
|
|
{
|
|
public _Details()
|
|
{
|
|
}
|
|
public override void Execute()
|
|
{
|
|
|
|
#line 2 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
Authorization.Require(Claims.Device.ShowDetails);
|
|
|
|
var canConfig = Authorization.Has(Claims.Device.Properties.Details);
|
|
|
|
if (canConfig)
|
|
{
|
|
Html.BundleDeferred("~/ClientScripts/Modules/Disco-PropertyChangeHelpers");
|
|
}
|
|
|
|
var processors = Model.Device.DeviceDetails.Processors();
|
|
var physicalMemory = Model.Device.DeviceDetails.PhysicalMemory();
|
|
var diskDrives = Model.Device.DeviceDetails.DiskDrives();
|
|
var networkAdapters = Model.Device.DeviceDetails.NetworkAdapters();
|
|
var lanMacAddress = Model.Device.DeviceDetails.LanMacAddress();
|
|
var wlanMacAddress = Model.Device.DeviceDetails.WLanMacAddress();
|
|
var bios = Model.Device.DeviceDetails.Bios();
|
|
var baseBoard = Model.Device.DeviceDetails.BaseBoard();
|
|
var computerSystem = Model.Device.DeviceDetails.ComputerSystem();
|
|
var batteries = Model.Device.DeviceDetails.Batteries();
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n<div");
|
|
|
|
WriteLiteral(" id=\"DeviceDetailTab-Details\"");
|
|
|
|
WriteLiteral(" class=\"DevicePart\"");
|
|
|
|
WriteLiteral(">\r\n <div");
|
|
|
|
WriteLiteral(" id=\"DeviceDetailTab-DetailsContainer\"");
|
|
|
|
WriteLiteral(">\r\n <table");
|
|
|
|
WriteLiteral(" class=\"tableData\"");
|
|
|
|
WriteLiteral(">\r\n <tbody>\r\n");
|
|
|
|
|
|
#line 27 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 27 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (bios != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_bios\"");
|
|
|
|
WriteLiteral(">\r\n <th>BIOS</th>\r\n <td>\r\n " +
|
|
" <table");
|
|
|
|
WriteLiteral(" class=\"tableData\"");
|
|
|
|
WriteLiteral(@">
|
|
<thead>
|
|
<tr>
|
|
<th>Manufacturer</th>
|
|
<th>Serial Number</th>
|
|
<th>Version</th>
|
|
<th>System Version</th>
|
|
<th>Release Date</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
");
|
|
|
|
|
|
#line 43 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 43 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
foreach (var b in bios)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr>\r\n " +
|
|
" <td>");
|
|
|
|
|
|
#line 46 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.Manufacturer);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 47 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.SerialNumber);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 48 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.SMBIOSBIOSVersion);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 48 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.SMBIOSMajorVersion.GetValueOrDefault(0));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(".");
|
|
|
|
|
|
#line 48 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.SMBIOSMinorVersion);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 49 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.SystemBiosMajorVersion);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(".");
|
|
|
|
|
|
#line 49 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.SystemBiosMinorVersion);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>\r\n");
|
|
|
|
|
|
#line 51 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 51 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (b.ReleaseDate.HasValue)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 53 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.ReleaseDate.Value.ToString("yyyy-MM-dd"));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 53 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n " +
|
|
" </tr>\r\n");
|
|
|
|
|
|
#line 57 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </tbody>\r\n </table>\r\n " +
|
|
" </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 62 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 63 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (baseBoard != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_base_board\"");
|
|
|
|
WriteLiteral(">\r\n <th>Base Board</th>\r\n <td>\r\n " +
|
|
" <table");
|
|
|
|
WriteLiteral(" class=\"tableData\"");
|
|
|
|
WriteLiteral(@">
|
|
<thead>
|
|
<tr>
|
|
<th>Manufacturer</th>
|
|
<th>Model</th>
|
|
<th>Product</th>
|
|
<th>Part Number</th>
|
|
<th>SKU</th>
|
|
<th>Serial Number</th>
|
|
<th>Config Options</th>
|
|
<th>Version</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
");
|
|
|
|
|
|
#line 82 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 82 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
foreach (var b in baseBoard)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr>\r\n " +
|
|
" <td>");
|
|
|
|
|
|
#line 85 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.Manufacturer);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 86 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.Model);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 87 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.Product);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 88 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.PartNumber);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 89 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.SKU);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 90 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.SerialNumber);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>\r\n");
|
|
|
|
|
|
#line 92 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 92 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (b.ConfigOptions != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 94 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(string.Join("; ", b.ConfigOptions));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 94 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n " +
|
|
" <td>");
|
|
|
|
|
|
#line 97 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(b.Version);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 99 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </tbody>\r\n </table>\r\n " +
|
|
" </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 104 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 105 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (computerSystem != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_computer_system\"");
|
|
|
|
WriteLiteral(">\r\n <th>System</th>\r\n <td>\r\n " +
|
|
" <table");
|
|
|
|
WriteLiteral(" class=\"tableData\"");
|
|
|
|
WriteLiteral(@">
|
|
<thead>
|
|
<tr>
|
|
<th>Description</th>
|
|
<th>Form Factor</th>
|
|
<th>Type</th>
|
|
<th>Primary Owner</th>
|
|
<th>Chassis SKU</th>
|
|
<th>System SKU</th>
|
|
<th>OEM Reference</th>
|
|
<th>Time Zone</th>
|
|
<th>Roles</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
");
|
|
|
|
|
|
#line 125 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 125 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
foreach (var c in computerSystem)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr>\r\n " +
|
|
" <td>");
|
|
|
|
|
|
#line 128 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(c.Description);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 129 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(c.PCSystemType);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 130 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(c.SystemType);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 131 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(c.PrimaryOwnerName);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 131 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(c.PrimaryOwnerContact);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 132 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(c.ChassisSKUNumber);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 133 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(c.SystemSKUNumber);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>\r\n");
|
|
|
|
|
|
#line 135 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 135 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (c.OEMStringArray != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 137 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(string.Join("; ", c.OEMStringArray));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 137 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n " +
|
|
" <td>\r\n");
|
|
|
|
|
|
#line 141 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 141 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (c.CurrentTimeZone.HasValue)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 143 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write((c.CurrentTimeZone.Value / 60).ToString(@"00\:"));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 143 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 143 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(Math.Abs(c.CurrentTimeZone.Value % 60).ToString("00"));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 143 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n " +
|
|
" <td>\r\n");
|
|
|
|
|
|
#line 147 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 147 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (c.Roles != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 149 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(string.Join("; ", c.Roles));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 149 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n " +
|
|
" </tr>\r\n");
|
|
|
|
|
|
#line 153 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </tbody>\r\n </table>\r\n " +
|
|
" </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 158 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 159 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (processors != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_processors\"");
|
|
|
|
WriteLiteral(">\r\n <th>Processors</th>\r\n <td>\r\n " +
|
|
" <table");
|
|
|
|
WriteLiteral(" class=\"tableData\"");
|
|
|
|
WriteLiteral(@">
|
|
<thead>
|
|
<tr>
|
|
<th>Name</th>
|
|
<th>Description</th>
|
|
<th>Architecture</th>
|
|
<th>Max Clock Speed</th>
|
|
<th>Cores</th>
|
|
<th>Logical Processors</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
");
|
|
|
|
|
|
#line 176 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 176 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
foreach (var processor in processors)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr>\r\n " +
|
|
" <td>");
|
|
|
|
|
|
#line 179 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(processor.Name);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 180 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(processor.Description);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 181 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(processor.Architecture);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 182 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(processor.MaxClockSpeedFriendly());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 183 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(processor.NumberOfCores.GetValueOrDefault(0).ToString("N0"));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 184 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(processor.NumberOfLogicalProcessors.GetValueOrDefault(0).ToString("N0"));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 186 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </tbody>\r\n </table>\r\n " +
|
|
" </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 191 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 192 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (physicalMemory != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_memory\"");
|
|
|
|
WriteLiteral(">\r\n <th>Memory</th>\r\n <td>\r\n " +
|
|
" <table");
|
|
|
|
WriteLiteral(" class=\"tableData\"");
|
|
|
|
WriteLiteral(@">
|
|
<thead>
|
|
<tr>
|
|
<th>Location</th>
|
|
<th>Manufacturer</th>
|
|
<th>Part Number</th>
|
|
<th>Serial Number</th>
|
|
<th>Capacity</th>
|
|
<th>Clock Speed</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
");
|
|
|
|
|
|
#line 209 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 209 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
foreach (var memory in physicalMemory)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr>\r\n " +
|
|
" <td>");
|
|
|
|
|
|
#line 212 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(memory.DeviceLocator);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 213 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(memory.Manufacturer);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 214 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(memory.PartNumber);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 215 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(memory.SerialNumber);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 216 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(memory.CapacityFriendly());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 217 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(memory.ConfiguredClockSpeed);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 219 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </tbody>\r\n </table>\r\n " +
|
|
" </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 224 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 225 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (networkAdapters != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_network_adapters\"");
|
|
|
|
WriteLiteral(">\r\n <th>Network Adapters</th>\r\n <td" +
|
|
">\r\n <table");
|
|
|
|
WriteLiteral(" class=\"tableData\"");
|
|
|
|
WriteLiteral(@">
|
|
<thead>
|
|
<tr>
|
|
<th>Connection</th>
|
|
<th>Manufacturer</th>
|
|
<th>Product</th>
|
|
<th>Speed</th>
|
|
<th>MAC Address</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
");
|
|
|
|
|
|
#line 241 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 241 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
foreach (var adapter in networkAdapters)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr>\r\n " +
|
|
" <td>\r\n");
|
|
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 245 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(adapter.NetConnectionID ?? "N/A");
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 245 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (adapter.IsWlanAdapter)
|
|
{
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("<i");
|
|
|
|
WriteLiteral(" class=\"fa fa-wifi\"");
|
|
|
|
WriteLiteral("></i>");
|
|
|
|
|
|
#line 246 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n " +
|
|
" <td>");
|
|
|
|
|
|
#line 248 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(adapter.Manufacturer);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 249 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(adapter.ProductName);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 250 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(adapter.SpeedFriendly());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 251 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(adapter.MACAddress);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 253 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </tbody>\r\n </table>\r\n " +
|
|
" </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 258 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
else
|
|
{
|
|
if (lanMacAddress != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_lan_mac_address\"");
|
|
|
|
WriteLiteral(">\r\n <th>LAN MAC Address</th>\r\n " +
|
|
" <td");
|
|
|
|
WriteLiteral(" class=\"pad code\"");
|
|
|
|
WriteLiteral(">");
|
|
|
|
|
|
#line 265 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(lanMacAddress);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 267 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
if (wlanMacAddress != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_wlan_mac_address\"");
|
|
|
|
WriteLiteral(">\r\n <th>WLAN MAC Address</th>\r\n " +
|
|
" <td");
|
|
|
|
WriteLiteral(" class=\"pad code\"");
|
|
|
|
WriteLiteral(">");
|
|
|
|
|
|
#line 272 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(wlanMacAddress);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 274 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 276 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (diskDrives != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_disk_drives\"");
|
|
|
|
WriteLiteral(">\r\n <th>Disk Drives</th>\r\n <td>\r\n " +
|
|
" <table");
|
|
|
|
WriteLiteral(" class=\"tableData\"");
|
|
|
|
WriteLiteral(@">
|
|
<thead>
|
|
<tr>
|
|
<th>Manufacturer</th>
|
|
<th>Model</th>
|
|
<th>Serial Number</th>
|
|
<th>Firmware</th>
|
|
<th>Type</th>
|
|
<th>Interface</th>
|
|
<th>Size</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
");
|
|
|
|
|
|
#line 294 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 294 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
foreach (var disk in diskDrives)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr>\r\n " +
|
|
" <td>");
|
|
|
|
|
|
#line 297 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(disk.Manufacturer);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 298 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(disk.Model);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 299 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(disk.SerialNumber);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 300 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(disk.FirmwareRevision);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 301 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(disk.MediaType);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 302 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(disk.InterfaceType);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 303 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(disk.SizeFriendly());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 305 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (disk.Partitions != null)
|
|
{
|
|
// calculate stretched offsets
|
|
var minPartitionSize = (double)disk.Size * 0.1;
|
|
var diskSizeAdjusted = disk.Partitions.Sum(p => Math.Max(minPartitionSize, p.Size.GetValueOrDefault(0)));
|
|
var diskAdjustedOffet = (double)0;
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr>\r\n " +
|
|
" <td");
|
|
|
|
WriteLiteral(" colspan=\"7\"");
|
|
|
|
WriteLiteral(">\r\n <div");
|
|
|
|
WriteLiteral(" class=\"partition\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
|
|
#line 314 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 314 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
foreach (var partition in disk.Partitions)
|
|
{
|
|
var logicalDisk = partition.LogicalDisk;
|
|
|
|
var offsetPercentage = Math.Round(((partition.StartingOffset.GetValueOrDefault(0) + diskAdjustedOffet) / diskSizeAdjusted) * 100, 3);
|
|
var widthPercentage = Math.Round((Math.Max(minPartitionSize, partition.Size.GetValueOrDefault(0)) / diskSizeAdjusted) * 100, 3);
|
|
var freeSpacePercentage = 0d;
|
|
if (partition.Size < minPartitionSize)
|
|
{
|
|
diskAdjustedOffet += minPartitionSize - partition.Size.GetValueOrDefault(0);
|
|
}
|
|
|
|
var partitionTitle = partition.Type;
|
|
var tags = new List<string>();
|
|
if (partition.BootPartition.GetValueOrDefault(false))
|
|
{
|
|
tags.Add("Boot");
|
|
}
|
|
if (partition.PrimaryParition.GetValueOrDefault(false))
|
|
{
|
|
tags.Add("Primary");
|
|
}
|
|
if (logicalDisk != null)
|
|
{
|
|
partitionTitle = string.Format("{0} {1}", logicalDisk.DeviceID, logicalDisk.VolumeName);
|
|
tags.Add(logicalDisk.SizeFriendly());
|
|
tags.Add(logicalDisk.FreeSpaceFriendly() + " Free");
|
|
tags.Add(logicalDisk.FileSystem);
|
|
tags.Add(logicalDisk.DriveType);
|
|
freeSpacePercentage = Math.Round(((double)logicalDisk.FreeSpace.GetValueOrDefault(0) / logicalDisk.Size.GetValueOrDefault(0)) * 100, 3);
|
|
}
|
|
else
|
|
{
|
|
tags.Add(partition.SizeFriendly());
|
|
}
|
|
var tag = string.Join(" | ", tags);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <span");
|
|
|
|
WriteAttribute("title", Tuple.Create(" title=\"", 19877), Tuple.Create("\"", 19913)
|
|
|
|
#line 350 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
, Tuple.Create(Tuple.Create("", 19885), Tuple.Create<System.Object, System.Int32>(partitionTitle
|
|
|
|
#line default
|
|
#line hidden
|
|
, 19885), false)
|
|
, Tuple.Create(Tuple.Create(" ", 19902), Tuple.Create("
", 19903), true)
|
|
|
|
#line 350 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
, Tuple.Create(Tuple.Create("", 19907), Tuple.Create<System.Object, System.Int32>(tag
|
|
|
|
#line default
|
|
#line hidden
|
|
, 19907), false)
|
|
);
|
|
|
|
WriteAttribute("style", Tuple.Create(" style=\"", 19914), Tuple.Create("\"", 19976)
|
|
, Tuple.Create(Tuple.Create("", 19922), Tuple.Create("left:", 19922), true)
|
|
|
|
#line 350 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
, Tuple.Create(Tuple.Create(" ", 19927), Tuple.Create<System.Object, System.Int32>(offsetPercentage
|
|
|
|
#line default
|
|
#line hidden
|
|
, 19928), false)
|
|
, Tuple.Create(Tuple.Create("", 19947), Tuple.Create("%;", 19947), true)
|
|
, Tuple.Create(Tuple.Create(" ", 19949), Tuple.Create("width:", 19950), true)
|
|
|
|
#line 350 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
, Tuple.Create(Tuple.Create(" ", 19956), Tuple.Create<System.Object, System.Int32>(widthPercentage
|
|
|
|
#line default
|
|
#line hidden
|
|
, 19957), false)
|
|
, Tuple.Create(Tuple.Create("", 19975), Tuple.Create("%", 19975), true)
|
|
);
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
|
|
#line 351 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 351 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (freeSpacePercentage > 0.5)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <span");
|
|
|
|
WriteLiteral(" class=\"freespace\"");
|
|
|
|
WriteAttribute("style", Tuple.Create(" style=\"", 20235), Tuple.Create("\"", 20310)
|
|
, Tuple.Create(Tuple.Create("", 20243), Tuple.Create("left:", 20243), true)
|
|
|
|
#line 353 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
, Tuple.Create(Tuple.Create(" ", 20248), Tuple.Create<System.Object, System.Int32>(100 - freeSpacePercentage
|
|
|
|
#line default
|
|
#line hidden
|
|
, 20249), false)
|
|
, Tuple.Create(Tuple.Create("", 20277), Tuple.Create("%;", 20277), true)
|
|
, Tuple.Create(Tuple.Create(" ", 20279), Tuple.Create("width:", 20280), true)
|
|
|
|
#line 353 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
, Tuple.Create(Tuple.Create(" ", 20286), Tuple.Create<System.Object, System.Int32>(freeSpacePercentage
|
|
|
|
#line default
|
|
#line hidden
|
|
, 20287), false)
|
|
, Tuple.Create(Tuple.Create("", 20309), Tuple.Create("%", 20309), true)
|
|
);
|
|
|
|
WriteLiteral("></span>\r\n");
|
|
|
|
|
|
#line 354 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <span");
|
|
|
|
WriteLiteral(" class=\"details\"");
|
|
|
|
WriteLiteral(">\r\n <strong>");
|
|
|
|
|
|
#line 356 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(partitionTitle);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</strong>\r\n <b" +
|
|
"r />\r\n");
|
|
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 358 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(tag);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n </span>\r\n " +
|
|
" </span>\r\n");
|
|
|
|
|
|
#line 361 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </div>\r\n " +
|
|
" </td>\r\n </" +
|
|
"tr>\r\n");
|
|
|
|
|
|
#line 365 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </tbody>\r\n </table>\r\n " +
|
|
" </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 371 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_ac_adapter\"");
|
|
|
|
WriteLiteral(">\r\n <th>AC Adapter</th>\r\n <td");
|
|
|
|
WriteLiteral(" class=\"pad\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
|
|
#line 376 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 376 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (canConfig)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 378 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(Html.TextBox("DeviceDetail_ACAdapter", Model.Device.DeviceDetails.ACAdapter()));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 378 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 378 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(AjaxHelpers.AjaxSave());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 378 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 378 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(AjaxHelpers.AjaxLoader());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 378 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <script>\r\n $(function () {" +
|
|
"\r\n document.DiscoFunctions.PropertyChangeHelper($" +
|
|
"(\'#DeviceDetail_ACAdapter\'), \'Unknown\', \'");
|
|
|
|
|
|
#line 381 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(Url.Action(MVC.API.Device.UpdateDetailACAdapter(Model.Device.SerialNumber, null)));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\', \'DetailACAdapter\');\r\n });\r\n " +
|
|
" </script>\r\n");
|
|
|
|
|
|
#line 384 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
else
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 387 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(Model.Device.DeviceDetails.ACAdapter() ?? "Unknown");
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 387 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n </tr>\r\n <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_battery\"");
|
|
|
|
WriteLiteral(">\r\n <th>Battery</th>\r\n <td");
|
|
|
|
WriteLiteral(" class=\"pad\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
|
|
#line 394 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 394 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (canConfig)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 396 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(Html.TextBox("DeviceDetail_Battery", Model.Device.DeviceDetails.Battery()));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 396 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 396 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(AjaxHelpers.AjaxSave());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 396 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 396 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(AjaxHelpers.AjaxLoader());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 396 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <script>\r\n $(function () {" +
|
|
"\r\n document.DiscoFunctions.PropertyChangeHelper($" +
|
|
"(\'#DeviceDetail_Battery\'), \'Unknown\', \'");
|
|
|
|
|
|
#line 399 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(Url.Action(MVC.API.Device.UpdateDetailBattery(Model.Device.SerialNumber, null)));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\', \'DetailBattery\');\r\n });\r\n " +
|
|
" </script>\r\n");
|
|
|
|
|
|
#line 402 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
else
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 405 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(Model.Device.DeviceDetails.Battery() ?? "Unknown");
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 405 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 409 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 409 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (batteries != null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_batteries\"");
|
|
|
|
WriteLiteral(">\r\n <th> </th>\r\n <td>\r\n " +
|
|
" <table");
|
|
|
|
WriteLiteral(" class=\"tableData\"");
|
|
|
|
WriteLiteral(@">
|
|
<thead>
|
|
<tr>
|
|
<th>Name</th>
|
|
<th>Description</th>
|
|
<th>Availability</th>
|
|
<th>Chemistry</th>
|
|
<th>Design Voltage</th>
|
|
<th>Design Capacity</th>
|
|
<th>Capacity</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
");
|
|
|
|
|
|
#line 427 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 427 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
foreach (var battery in batteries)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr>\r\n " +
|
|
" <td>");
|
|
|
|
|
|
#line 430 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(battery.Name);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 431 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(battery.Description);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 432 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(battery.Availability);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 433 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(battery.Chemistry);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</td>\r\n <td>");
|
|
|
|
|
|
#line 434 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(battery.DesignVoltage.GetValueOrDefault(0).ToString("N0"));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" mV</td>\r\n <td>");
|
|
|
|
|
|
#line 435 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(battery.DesignCapacity.GetValueOrDefault(0).ToString("N0"));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" mWh</td>\r\n <td>");
|
|
|
|
|
|
#line 436 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(battery.FullChargeCapacity.GetValueOrDefault(0).ToString("N0"));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" mWh</td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 438 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </tbody>\r\n </table>\r\n " +
|
|
" </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 443 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_keyboard\"");
|
|
|
|
WriteLiteral(">\r\n <th>Keyboard</th>\r\n <td");
|
|
|
|
WriteLiteral(" class=\"pad\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
|
|
#line 447 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 447 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (canConfig)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 449 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(Html.TextBox("DeviceDetail_Keyboard", Model.Device.DeviceDetails.Keyboard()));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 449 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 449 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(AjaxHelpers.AjaxSave());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 449 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 449 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(AjaxHelpers.AjaxLoader());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 449 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <script>\r\n $(function () {" +
|
|
"\r\n document.DiscoFunctions.PropertyChangeHelper($" +
|
|
"(\'#DeviceDetail_Keyboard\'), \'Unknown\', \'");
|
|
|
|
|
|
#line 452 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(Url.Action(MVC.API.Device.UpdateDetailKeyboard(Model.Device.SerialNumber, null)));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\', \'DetailKeyboard\');\r\n });\r\n " +
|
|
" </script>\r\n");
|
|
|
|
|
|
#line 455 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
else
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 458 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(Model.Device.DeviceDetails.Keyboard() ?? "Unknown");
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 458 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 462 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 462 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
if (Model.Device.LastEnrolDate.HasValue)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr");
|
|
|
|
WriteLiteral(" class=\"device_detail_update\"");
|
|
|
|
WriteLiteral(">\r\n <td");
|
|
|
|
WriteLiteral(" colspan=\"2\"");
|
|
|
|
WriteLiteral("><em>Details collected ");
|
|
|
|
|
|
#line 465 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
Write(CommonHelpers.FriendlyDate(Model.Device.LastEnrolDate));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" at time of last enrolment</em></td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 467 "..\..\Views\Device\DeviceParts\_Details.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </tbody>\r\n </table>\r\n </div>\r\n <script>\r\n $(\'#Dev" +
|
|
"iceDetailTabItems\').append(\'<li><a href=\"#DeviceDetailTab-Details\">Details</a></" +
|
|
"li>\');\r\n </script>\r\n</div>\r\n");
|
|
|
|
}
|
|
}
|
|
}
|
|
#pragma warning restore 1591
|