f1ee2937cd
New icon, theme, and fuzzy time. Add moment.js
762 lines
25 KiB
C#
762 lines
25 KiB
C#
#pragma warning disable 1591
|
|
//------------------------------------------------------------------------------
|
|
// <auto-generated>
|
|
// This code was generated by a tool.
|
|
// Runtime Version:4.0.30319.34003
|
|
//
|
|
// Changes to this file may cause incorrect behavior and will be lost if
|
|
// the code is regenerated.
|
|
// </auto-generated>
|
|
//------------------------------------------------------------------------------
|
|
|
|
namespace Disco.Web.Areas.Config.Views.DeviceModel
|
|
{
|
|
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.BI.Extensions;
|
|
using Disco.Models.Repository;
|
|
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("~/Areas/Config/Views/DeviceModel/Show.cshtml")]
|
|
public partial class Show : Disco.Services.Web.WebViewPage<Disco.Web.Areas.Config.Models.DeviceModel.ShowModel>
|
|
{
|
|
public Show()
|
|
{
|
|
}
|
|
public override void Execute()
|
|
{
|
|
|
|
#line 2 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
Authorization.Require(Claims.Config.DeviceModel.Show);
|
|
|
|
var canConfig = Authorization.Has(Claims.Config.DeviceModel.Configure);
|
|
|
|
ViewBag.Title = Html.ToBreadcrumb("Configuration", MVC.Config.Config.Index(), "Device Models", MVC.Config.DeviceModel.Index(null), Model.DeviceModel.ToString());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n<div");
|
|
|
|
WriteLiteral(" class=\"form\"");
|
|
|
|
WriteLiteral(" style=\"width: 530px\"");
|
|
|
|
WriteLiteral(">\r\n <table>\r\n <tr>\r\n <th");
|
|
|
|
WriteLiteral(" style=\"width: 150px\"");
|
|
|
|
WriteLiteral(">Id:\r\n </th>\r\n <td>\r\n");
|
|
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 15 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Html.DisplayFor(model => model.DeviceModel.Id));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n </td>\r\n </tr>\r\n <tr>\r\n <th>Description:\r\n " +
|
|
" </th>\r\n <td>");
|
|
|
|
|
|
#line 21 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
if (canConfig)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 23 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Html.EditorFor(model => model.DeviceModel.Description));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 23 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 24 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(AjaxHelpers.AjaxSave());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 24 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 25 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(AjaxHelpers.AjaxLoader());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 25 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
}
|
|
else
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 29 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Html.DisplayFor(model => model.DeviceModel.Description));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 29 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n </tr>\r\n <tr>\r\n <th>Manufacturer:\r\n " +
|
|
" </th>\r\n <td>\r\n");
|
|
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 37 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Html.DisplayFor(model => model.DeviceModel.Manufacturer));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n </td>\r\n </tr>\r\n <tr>\r\n <th>Model:\r\n " +
|
|
" </th>\r\n <td>\r\n");
|
|
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 44 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Html.DisplayFor(model => model.DeviceModel.Model));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n </td>\r\n </tr>\r\n <tr>\r\n <th>Statistics</th>" +
|
|
"\r\n <td>\r\n <div><strong>");
|
|
|
|
|
|
#line 50 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Model.DeviceCount.ToString("n0"));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</strong> ");
|
|
|
|
|
|
#line 50 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Model.DeviceCount == 1 ? "devices is" : "devices are");
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" of this model type.</div>\r\n");
|
|
|
|
|
|
#line 51 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 51 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
if (Model.DeviceDecommissionedCount > 0)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <div");
|
|
|
|
WriteLiteral(" class=\"smallMessage\"");
|
|
|
|
WriteLiteral(">");
|
|
|
|
|
|
#line 53 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Model.DeviceDecommissionedCount.ToString("n0"));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 53 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Model.DeviceDecommissionedCount == 1 ? "device is" : "devices are");
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" decommissioned.</div>\r\n");
|
|
|
|
|
|
#line 54 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n </tr>\r\n <tr>\r\n <th>Default Purchase " +
|
|
"Date:\r\n </th>\r\n <td>");
|
|
|
|
|
|
#line 60 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
if (canConfig)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 62 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Html.EditorFor(model => model.DeviceModel.DefaultPurchaseDate));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 62 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 63 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(AjaxHelpers.AjaxLoader());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 63 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
}
|
|
else
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 67 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(CommonHelpers.FriendlyDate(Model.DeviceModel.DefaultPurchaseDate, "Unknown"));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 67 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n </tr>\r\n <tr>\r\n <th>Default Warranty " +
|
|
"Provider:\r\n </th>\r\n <td>");
|
|
|
|
|
|
#line 74 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
if (canConfig)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 76 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Html.DropDownListFor(model => model.DeviceModel.DefaultWarrantyProvider, Model.WarrantyProviders.ToSelectListItems(Model.DeviceModel.DefaultWarrantyProvider, true, "None")));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 76 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 77 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(AjaxHelpers.AjaxLoader());
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 77 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
}
|
|
else
|
|
{
|
|
if (Model.DeviceModel.DefaultWarrantyProvider == null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <span");
|
|
|
|
WriteLiteral(" class=\"smallMessage\"");
|
|
|
|
WriteLiteral("><None Specified></span>\r\n");
|
|
|
|
|
|
#line 84 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
}
|
|
else
|
|
{
|
|
var provider = Model.WarrantyProviders.FirstOrDefault(wp => wp.Id == Model.DeviceModel.DefaultWarrantyProvider);
|
|
if (provider == null)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <span");
|
|
|
|
WriteLiteral(" class=\"smallMessage\"");
|
|
|
|
WriteLiteral("><None Specified></span>\r\n");
|
|
|
|
|
|
#line 91 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
}
|
|
else
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 94 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(provider.Name);
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 94 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n </tr>\r\n <tr>\r\n <th>Type:\r\n " +
|
|
" </th>\r\n <td>\r\n");
|
|
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 104 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Html.DisplayFor(model => model.DeviceModel.ModelType));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n </td>\r\n </tr>\r\n <tr>\r\n <th>Image:\r\n " +
|
|
" </th>\r\n <td>\r\n <img");
|
|
|
|
WriteLiteral(" alt=\"Model Image\"");
|
|
|
|
WriteAttribute("src", Tuple.Create(" src=\"", 3910), Tuple.Create("\"", 4007)
|
|
|
|
#line 111 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
, Tuple.Create(Tuple.Create("", 3916), Tuple.Create<System.Object, System.Int32>(Url.Action(MVC.API.DeviceModel.Image(Model.DeviceModel.Id, Model.DeviceModel.ImageHash()))
|
|
|
|
#line default
|
|
#line hidden
|
|
, 3916), false)
|
|
);
|
|
|
|
WriteLiteral(" />\r\n </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 114 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 114 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
if (canConfig)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <tr>\r\n <th>\r\n <label");
|
|
|
|
WriteLiteral(" for=\"DeviceModel_Image\"");
|
|
|
|
WriteLiteral(">\r\n Update Image:\r\n </label>\r\n " +
|
|
" </th>\r\n <td>\r\n");
|
|
|
|
|
|
#line 123 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 123 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
using (Html.BeginForm(MVC.API.DeviceModel.Image(Model.DeviceModel.Id, true, null), FormMethod.Post, new { enctype = "multipart/form-data" }))
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <input");
|
|
|
|
WriteLiteral(" type=\"file\"");
|
|
|
|
WriteLiteral(" name=\"Image\"");
|
|
|
|
WriteLiteral(" id=\"Image\"");
|
|
|
|
WriteLiteral(" style=\"width: 250px;\"");
|
|
|
|
WriteLiteral(" />\r\n");
|
|
|
|
WriteLiteral(" <input");
|
|
|
|
WriteLiteral(" class=\"button\"");
|
|
|
|
WriteLiteral(" type=\"submit\"");
|
|
|
|
WriteLiteral(" value=\"Update\"");
|
|
|
|
WriteLiteral(" />\r\n");
|
|
|
|
|
|
#line 127 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </td>\r\n </tr>\r\n");
|
|
|
|
|
|
#line 130 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" </table>\r\n");
|
|
|
|
|
|
#line 132 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 132 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
if (canConfig)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" <script");
|
|
|
|
WriteLiteral(" type=\"text/javascript\"");
|
|
|
|
WriteLiteral(@">
|
|
$(function () {
|
|
var $Description = $('#DeviceModel_Description');
|
|
var $DescriptionAjaxSave = $Description.next('.ajaxSave');
|
|
$Description
|
|
.watermark('Model Description')
|
|
.focus(function () { $Description.select() })
|
|
.keydown(function (e) {
|
|
$DescriptionAjaxSave.show();
|
|
if (e.which == 13) {
|
|
$(this).blur();
|
|
}
|
|
}).blur(function () {
|
|
$DescriptionAjaxSave.hide();
|
|
})
|
|
.change(function () {
|
|
$DescriptionAjaxSave.hide();
|
|
var $ajaxLoading = $DescriptionAjaxSave.next('.ajaxLoading').show();
|
|
var data = { Description: $Description.val() };
|
|
$.ajax({
|
|
url: '");
|
|
|
|
|
|
#line 154 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Url.Action(MVC.API.DeviceModel.UpdateDescription(Model.DeviceModel.Id)));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(@"',
|
|
dataType: 'json',
|
|
data: data,
|
|
success: function (d) {
|
|
if (d == 'OK') {
|
|
$ajaxLoading.hide().next('.ajaxOk').show().delay('fast').fadeOut('slow');
|
|
} else {
|
|
$ajaxLoading.hide();
|
|
alert('Unable to update description: ' + d);
|
|
}
|
|
},
|
|
error: function (jqXHR, textStatus, errorThrown) {
|
|
alert('Unable to update description: ' + textStatus);
|
|
$ajaxLoading.hide();
|
|
}
|
|
});
|
|
});
|
|
});
|
|
</script>
|
|
");
|
|
|
|
WriteLiteral(" <script");
|
|
|
|
WriteLiteral(" type=\"text/javascript\"");
|
|
|
|
WriteLiteral(@">
|
|
$(function () {
|
|
var $dataField = $('#DeviceModel_DefaultPurchaseDate');
|
|
var $ajaxLoading = $dataField.next('.ajaxLoading');
|
|
var dateFieldValue = $dataField.val();
|
|
var dateFieldChangeToken = null;
|
|
$dataField
|
|
.watermark('None')
|
|
.datepicker({
|
|
changeYear: true,
|
|
changeMonth: true,
|
|
dateFormat: 'yy/mm/dd'
|
|
})
|
|
.change(function () {
|
|
var dateText = $dataField.val();
|
|
if (dateFieldValue.toLowerCase() != dateText.toLowerCase()) {
|
|
dateFieldValue = dateText;
|
|
if (dateFieldChangeToken)
|
|
window.clearTimeout(dateFieldChangeToken);
|
|
dateFieldChangeToken = window.setTimeout(function () {
|
|
$ajaxLoading.show();
|
|
var data = {};
|
|
data['DefaultPurchaseDate'] = dateFieldValue;
|
|
$.getJSON('");
|
|
|
|
|
|
#line 196 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Url.Action(MVC.API.DeviceModel.UpdateDefaultPurchaseDate(Model.DeviceModel.Id)));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(@"', data, function (response, result) {
|
|
if (result != 'success' || response != 'OK') {
|
|
alert('Unable to change Date:\n' + response);
|
|
$ajaxLoading.hide();
|
|
} else {
|
|
$ajaxLoading.hide().next('.ajaxOk').show().delay('fast').fadeOut('slow');
|
|
}
|
|
})
|
|
dateFieldChangeToken = null;
|
|
}, 500);
|
|
}
|
|
}).focus(function () {
|
|
$(this).select();
|
|
});
|
|
});
|
|
</script>
|
|
");
|
|
|
|
WriteLiteral(" <script");
|
|
|
|
WriteLiteral(" type=\"text/javascript\"");
|
|
|
|
WriteLiteral(@">
|
|
$(function () {
|
|
var $DefaultWarrantyProvider = $('#DeviceModel_DefaultWarrantyProvider');
|
|
var $ajaxLoading = $DefaultWarrantyProvider.next('.ajaxLoading');
|
|
$DefaultWarrantyProvider
|
|
.change(function () {
|
|
$ajaxLoading.show();
|
|
var data = { DefaultWarrantyProvider: $DefaultWarrantyProvider.val() };
|
|
$.ajax({
|
|
url: '");
|
|
|
|
|
|
#line 221 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Url.Action(MVC.API.DeviceModel.UpdateDefaultWarrantyProvider(Model.DeviceModel.Id)));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(@"',
|
|
dataType: 'json',
|
|
data: data,
|
|
success: function (d) {
|
|
if (d == 'OK') {
|
|
$ajaxLoading.hide().next('.ajaxOk').show().delay('fast').fadeOut('slow');
|
|
} else {
|
|
$ajaxLoading.hide();
|
|
alert('Unable to default warranty provider: ' + d);
|
|
}
|
|
},
|
|
error: function (jqXHR, textStatus, errorThrown) {
|
|
alert('Unable to default warranty provider: ' + textStatus);
|
|
$ajaxLoading.hide();
|
|
}
|
|
});
|
|
});
|
|
});
|
|
</script>
|
|
");
|
|
|
|
|
|
#line 240 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</div>\r\n<h2>Components</h2>\r\n");
|
|
|
|
|
|
#line 243 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Html.Partial(MVC.Config.DeviceModel.Views._DeviceComponentsTable, Model.DeviceComponentsModel));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("\r\n<div");
|
|
|
|
WriteLiteral(" class=\"actionBar\"");
|
|
|
|
WriteLiteral(">\r\n");
|
|
|
|
|
|
#line 245 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 245 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
if (Model.CanDelete)
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 247 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Html.ActionLinkButton("Delete", MVC.API.DeviceModel.Delete(Model.DeviceModel.Id, true), "buttonDelete"));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 247 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral(" ");
|
|
|
|
|
|
#line 249 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
if (Model.DeviceCount > 0)
|
|
{
|
|
if (Authorization.Has(Claims.Device.Actions.Export))
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 253 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Html.ActionLinkButton("Export Devices", MVC.API.DeviceModel.ExportDevices(Model.DeviceModel.Id)));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 253 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
}
|
|
if (Authorization.Has(Claims.Device.Search))
|
|
{
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 257 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
Write(Html.ActionLinkButton("View Devices", MVC.Search.Query(Model.DeviceModel.Id.ToString(), "DeviceModel")));
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
|
|
#line 257 "..\..\Areas\Config\Views\DeviceModel\Show.cshtml"
|
|
|
|
}
|
|
}
|
|
|
|
|
|
#line default
|
|
#line hidden
|
|
WriteLiteral("</div>\r\n");
|
|
|
|
}
|
|
}
|
|
}
|
|
#pragma warning restore 1591
|