#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.Areas.Config.Views.Export
{
    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("~/Areas/Config/Views/Export/_Edit.cshtml")]
    public partial class _Edit : Disco.Services.Web.WebViewPage<Disco.Web.Areas.Config.Models.Export.EditModel>
    {
        public _Edit()
        {
        }
        public override void Execute()
        {
            
            #line 2 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
 using (Html.BeginForm(MVC.API.Export.Update(), FormMethod.Post))
{
    
            
            #line default
            #line hidden
            
            #line 4 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
Write(Html.AntiForgeryToken());

            
            #line default
            #line hidden
            
            #line 4 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                            ;
    
            
            #line default
            #line hidden
            
            #line 5 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
Write(Html.HiddenFor(m => m.Id));

            
            #line default
            #line hidden
            
            #line 5 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                              


            
            #line default
            #line hidden
WriteLiteral("    <div");

WriteLiteral(" id=\"Config_Export_Edit_Details\"");

WriteLiteral(" class=\"form\"");

WriteLiteral(" style=\"width: 530px;\"");

WriteLiteral(">\r\n        <h2>Saved ");

            
            #line 8 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
             Write(Model.ExportTypeName);

            
            #line default
            #line hidden
WriteLiteral("</h2>\r\n        <table>\r\n            <tr>\r\n                <th");

WriteLiteral(" style=\"width: 140px\"");

WriteLiteral(">Name:</th>\r\n                <td>\r\n");

WriteLiteral("                    ");

            
            #line 13 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
               Write(Html.EditorFor(model => model.Name));

            
            #line default
            #line hidden
WriteLiteral("\r\n                </td>\r\n            </tr>\r\n            <tr>\r\n                <th" +
">\r\n                    Description:<br />\r\n                    <em");

WriteLiteral(" class=\"small\"");

WriteLiteral(">Optional</em>\r\n                </th>\r\n                <td>\r\n");

WriteLiteral("                    ");

            
            #line 22 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
               Write(Html.EditorFor(model => model.Description));

            
            #line default
            #line hidden
WriteLiteral("\r\n                </td>\r\n            </tr>\r\n        </table>\r\n    </div>\r\n");

            
            #line 27 "..\..\Areas\Config\Views\Export\_Edit.cshtml"


            
            #line default
            #line hidden
WriteLiteral("    <div");

WriteLiteral(" id=\"Config_Export_Edit_Schedule\"");

WriteLiteral(" class=\"form\"");

WriteLiteral(" style=\"width: 530px; margin-top: 10px;\"");

WriteLiteral(">\r\n        <h2>Schedule</h2>\r\n        <table>\r\n            <tr>\r\n                " +
"<th");

WriteLiteral(" style=\"width: 140px\"");

WriteLiteral(">&nbsp;</th>\r\n                <td>\r\n                    <label>\r\n");

WriteLiteral("                        ");

            
            #line 35 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                   Write(Html.EditorFor(m => m.ScheduleEnabled));

            
            #line default
            #line hidden
WriteLiteral("\r\n                        Enable Scheduled Export\r\n                    </label>\r\n" +
"                </td>\r\n            </tr>\r\n            <tr");

WriteAttribute("class", Tuple.Create(" class=\"", 1306), Tuple.Create("\"", 1356)
            
            #line 40 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create("", 1314), Tuple.Create<System.Object, System.Int32>(Model.ScheduleEnabled ? null : "hidden"
            
            #line default
            #line hidden
, 1314), false)
);

WriteLiteral(">\r\n                <th>\r\n                    Days:\r\n                </th>\r\n      " +
"          <td>\r\n                    <ul");

WriteLiteral(" class=\"none\"");

WriteLiteral(">\r\n                        <li><label>");

            
            #line 46 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                              Write(Html.EditorFor(m => m.ScheduleMonday));

            
            #line default
            #line hidden
WriteLiteral(" Monday</label></li>\r\n                        <li><label>");

            
            #line 47 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                              Write(Html.EditorFor(m => m.ScheduleTuesday));

            
            #line default
            #line hidden
WriteLiteral(" Tuesday</label></li>\r\n                        <li><label>");

            
            #line 48 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                              Write(Html.EditorFor(m => m.ScheduleWednesday));

            
            #line default
            #line hidden
WriteLiteral(" Wednesday</label></li>\r\n                        <li><label>");

            
            #line 49 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                              Write(Html.EditorFor(m => m.ScheduleThursday));

            
            #line default
            #line hidden
WriteLiteral(" Thursday</label></li>\r\n                        <li><label>");

            
            #line 50 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                              Write(Html.EditorFor(m => m.ScheduleFriday));

            
            #line default
            #line hidden
WriteLiteral(" Friday</label></li>\r\n                        <li><label>");

            
            #line 51 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                              Write(Html.EditorFor(m => m.ScheduleSaturday));

            
            #line default
            #line hidden
WriteLiteral(" Saturday</label></li>\r\n                        <li><label>");

            
            #line 52 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                              Write(Html.EditorFor(m => m.ScheduleSunday));

            
            #line default
            #line hidden
WriteLiteral(" Sunday</label></li>\r\n                    </ul>\r\n                </td>\r\n         " +
"   </tr>\r\n            <tr");

WriteAttribute("class", Tuple.Create(" class=\"", 2258), Tuple.Create("\"", 2308)
            
            #line 56 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create("", 2266), Tuple.Create<System.Object, System.Int32>(Model.ScheduleEnabled ? null : "hidden"
            
            #line default
            #line hidden
, 2266), false)
);

WriteLiteral(">\r\n                <th>\r\n                    Start Time:\r\n                </th>\r\n" +
"                <td>\r\n                    <select");

WriteLiteral(" name=\"ScheduleStartHour\"");

WriteLiteral(">\r\n");

            
            #line 62 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                        
            
            #line default
            #line hidden
            
            #line 62 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                          

            
            #line default
            #line hidden
WriteLiteral("                            <option");

WriteLiteral(" value=\"0\"");

WriteLiteral(" ");

            
            #line 63 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                          Write(Model.ScheduleStartHour == 0 ? "selected" : null);

            
            #line default
            #line hidden
WriteLiteral(">12:00 AM</option>\r\n");

            
            #line 64 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                            for (int i = 1; i < 12; i++)
                            {

            
            #line default
            #line hidden
WriteLiteral("                                <option");

WriteAttribute("value", Tuple.Create(" value=\"", 2740), Tuple.Create("\"", 2750)
            
            #line 66 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create("", 2748), Tuple.Create<System.Object, System.Int32>(i
            
            #line default
            #line hidden
, 2748), false)
);

WriteLiteral(" ");

            
            #line 66 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                               Write(Model.ScheduleStartHour == i ? "selected" : null);

            
            #line default
            #line hidden
WriteLiteral(">");

            
            #line 66 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                                                                                  Write(i);

            
            #line default
            #line hidden
WriteLiteral(":00 AM</option>\r\n");

            
            #line 67 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                            }

            
            #line default
            #line hidden
WriteLiteral("                            <option");

WriteLiteral(" value=\"12\"");

WriteLiteral(" ");

            
            #line 68 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                           Write(Model.ScheduleStartHour == 12 ? "selected" : null);

            
            #line default
            #line hidden
WriteLiteral(">12:00 PM</option>\r\n");

            
            #line 69 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                            for (int i = 13; i < 24; i++)
                            {

            
            #line default
            #line hidden
WriteLiteral("                                <option");

WriteAttribute("value", Tuple.Create(" value=\"", 3102), Tuple.Create("\"", 3112)
            
            #line 71 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create("", 3110), Tuple.Create<System.Object, System.Int32>(i
            
            #line default
            #line hidden
, 3110), false)
);

WriteLiteral(" ");

            
            #line 71 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                               Write(Model.ScheduleStartHour == i ? "selected" : null);

            
            #line default
            #line hidden
WriteLiteral(">");

            
            #line 71 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                                                                                   Write(i % 12);

            
            #line default
            #line hidden
WriteLiteral(":00 PM</option>\r\n");

            
            #line 72 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                            }
                        
            
            #line default
            #line hidden
WriteLiteral("\r\n                    </select>\r\n                    <div");

WriteLiteral(" class=\"info-box\"");

WriteLiteral(">\r\n                        <p");

WriteLiteral(" class=\"fa-p\"");

WriteLiteral(">\r\n                            <i");

WriteLiteral(" class=\"fa fa-fw fa-info-circle\"");

WriteLiteral(@"></i> By default, Disco ICT shuts down at 1:30am and does not resume again until its needed. If a scheduled export was missed during this time, it will be run as soon as Disco ICT is resumed.
                        </p>
                    </div>
                </td>
            </tr>
            <tr");

WriteAttribute("class", Tuple.Create(" class=\"", 3737), Tuple.Create("\"", 3787)
            
            #line 82 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create("", 3745), Tuple.Create<System.Object, System.Int32>(Model.ScheduleEnabled ? null : "hidden"
            
            #line default
            #line hidden
, 3745), false)
);

WriteLiteral(">\r\n                <th>\r\n                    Repeat Hourly Until:\r\n              " +
"  </th>\r\n                <td>\r\n                    <select");

WriteLiteral(" name=\"ScheduleEndHour\"");

WriteLiteral(">\r\n                        <option");

WriteLiteral(" value=\"\"");

WriteLiteral(" ");

            
            #line 88 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                     Write(Model.ScheduleEndHour.HasValue ? null : "selected");

            
            #line default
            #line hidden
WriteLiteral(">Run once</option>\r\n");

            
            #line 89 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                        
            
            #line default
            #line hidden
            
            #line 89 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                          
                            for (int i = 1; i < 12; i++)
                            {

            
            #line default
            #line hidden
WriteLiteral("                                <option");

WriteAttribute("value", Tuple.Create(" value=\"", 4223), Tuple.Create("\"", 4233)
            
            #line 92 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create("", 4231), Tuple.Create<System.Object, System.Int32>(i
            
            #line default
            #line hidden
, 4231), false)
);

WriteLiteral(" ");

            
            #line 92 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                               Write(Model.ScheduleEndHour == i ? "selected" : null);

            
            #line default
            #line hidden
WriteLiteral(">");

            
            #line 92 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                                                                                Write(i);

            
            #line default
            #line hidden
WriteLiteral(":00 AM</option>\r\n");

            
            #line 93 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                            }

            
            #line default
            #line hidden
WriteLiteral("                            <option");

WriteLiteral(" value=\"12\"");

WriteLiteral(" ");

            
            #line 94 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                           Write(Model.ScheduleEndHour == 12 ? "selected" : null);

            
            #line default
            #line hidden
WriteLiteral(">12:00 PM</option>\r\n");

            
            #line 95 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                            for (int i = 12; i < 24; i++)
                            {

            
            #line default
            #line hidden
WriteLiteral("                                <option");

WriteAttribute("value", Tuple.Create(" value=\"", 4581), Tuple.Create("\"", 4591)
            
            #line 97 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create("", 4589), Tuple.Create<System.Object, System.Int32>(i
            
            #line default
            #line hidden
, 4589), false)
);

WriteLiteral(" ");

            
            #line 97 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                               Write(Model.ScheduleEndHour == i ? "selected" : null);

            
            #line default
            #line hidden
WriteLiteral(">");

            
            #line 97 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                                                                                 Write(i % 12);

            
            #line default
            #line hidden
WriteLiteral(":00 PM</option>\r\n");

            
            #line 98 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                            }
                        
            
            #line default
            #line hidden
WriteLiteral("\r\n                    </select>\r\n                </td>\r\n            </tr>\r\n      " +
"      <tr");

WriteAttribute("class", Tuple.Create(" class=\"", 4815), Tuple.Create("\"", 4865)
            
            #line 103 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create("", 4823), Tuple.Create<System.Object, System.Int32>(Model.ScheduleEnabled ? null : "hidden"
            
            #line default
            #line hidden
, 4823), false)
);

WriteLiteral(">\r\n                <th>\r\n                    File System Location:\r\n             " +
"   </th>\r\n                <td>\r\n");

WriteLiteral("                    ");

            
            #line 108 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
               Write(Html.EditorFor(m => m.FilePath));

            
            #line default
            #line hidden
WriteLiteral("\r\n                    <div");

WriteLiteral(" class=\"info-box\"");

WriteLiteral(">\r\n                        <p");

WriteLiteral(" class=\"fa-p\"");

WriteLiteral(">\r\n                            <i");

WriteLiteral(" class=\"fa fa-fw fa-info-circle\"");

WriteLiteral("></i> This is the full file path on the Disco ICT server (<code>");

            
            #line 111 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                                                                                                         Write(Environment.MachineName);

            
            #line default
            #line hidden
WriteLiteral("</code>). The location may be a network path. The Disco ICT Service Account (<cod" +
"e>");

            
            #line 111 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                                                                                                                                                                                                                    Write(Environment.UserDomainName);

            
            #line default
            #line hidden
WriteLiteral("\\");

            
            #line 111 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                                                                                                                                                                                                                                                Write(Environment.UserName);

            
            #line default
            #line hidden
WriteLiteral("</code>) must have write access to the location.\r\n                        </p>\r\n " +
"                   </div>\r\n                    <label>\r\n");

WriteLiteral("                        ");

            
            #line 115 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                   Write(Html.EditorFor(m => m.TimestampSuffix));

            
            #line default
            #line hidden
WriteLiteral(" Add time stamp suffix to file name\r\n                    </label>\r\n              " +
"      <div");

WriteLiteral(" class=\"info-box\"");

WriteLiteral(">\r\n                        <p");

WriteLiteral(" class=\"fa-p\"");

WriteLiteral(">\r\n                            <i");

WriteLiteral(" class=\"fa fa-fw fa-info-circle\"");

WriteLiteral("></i> This will create a new file each time the export runs.\r\n                   " +
"     </p>\r\n                    </div>\r\n                </td>\r\n            </tr>\r" +
"\n        </table>\r\n    </div>\r\n");

            
            #line 126 "..\..\Areas\Config\Views\Export\_Edit.cshtml"


            
            #line default
            #line hidden
WriteLiteral("    <div");

WriteLiteral(" id=\"Config_Export_Edit_OnDemand\"");

WriteLiteral(" class=\"form\"");

WriteLiteral(" style=\"width: 530px; margin-top: 10px;\"");

WriteLiteral(">\r\n        <h2>On Demand Export</h2>\r\n        <table>\r\n            <tr>\r\n        " +
"        <th");

WriteLiteral(" style=\"width: 140px\"");

WriteLiteral(">\r\n                    Additional Users/Groups:\r\n                </th>\r\n         " +
"       <td>\r\n                    <ul");

WriteLiteral(" id=\"Config_Export_Edit_OnDemand_List\"");

WriteLiteral(" class=\"none\"");

WriteLiteral(">\r\n");

            
            #line 136 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                        
            
            #line default
            #line hidden
            
            #line 136 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                         if (Model.OnDemandSubjects != null)
                        {
                            foreach (var sg in Model.OnDemandSubjects)
                            {

            
            #line default
            #line hidden
WriteLiteral("                                <li>\r\n                                    <input");

WriteLiteral(" type=\"hidden\"");

WriteLiteral(" name=\"OnDemandPrincipals\"");

WriteAttribute("value", Tuple.Create(" value=\"", 6700), Tuple.Create("\"", 6714)
            
            #line 141 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
          , Tuple.Create(Tuple.Create("", 6708), Tuple.Create<System.Object, System.Int32>(sg.Id
            
            #line default
            #line hidden
, 6708), false)
);

WriteLiteral(" />\r\n                                    <i");

WriteAttribute("class", Tuple.Create(" class=\"", 6758), Tuple.Create("\"", 6808)
, Tuple.Create(Tuple.Create("", 6766), Tuple.Create("fa", 6766), true)
, Tuple.Create(Tuple.Create(" ", 6768), Tuple.Create("fa-user", 6769), true)
            
            #line 142 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create("", 6776), Tuple.Create<System.Object, System.Int32>(sg.IsGroup ? "s" : null
            
            #line default
            #line hidden
, 6776), false)
, Tuple.Create(Tuple.Create(" ", 6802), Tuple.Create("fa-lg", 6803), true)
);

WriteLiteral("></i>\r\n");

WriteLiteral("                                    ");

            
            #line 143 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                               Write(sg.Name);

            
            #line default
            #line hidden
WriteLiteral(" [");

            
            #line 143 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                         Write(sg.Id);

            
            #line default
            #line hidden
WriteLiteral("]\r\n                                    <i");

WriteLiteral(" class=\"fa fa-times-circle remove\"");

WriteLiteral("></i>\r\n                                </li>\r\n");

            
            #line 146 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                            }
                        }

            
            #line default
            #line hidden
WriteLiteral("                    </ul>\r\n                    <div>\r\n                        <in" +
"put");

WriteLiteral(" type=\"text\"");

WriteLiteral(" id=\"Config_Export_Edit_OnDemand_Input\"");

WriteLiteral(" placeholder=\"Search users and groups\"");

WriteLiteral(" data-url=\"");

            
            #line 150 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                                                                                                              Write(Url.Action(MVC.API.System.SearchSubjects()));

            
            #line default
            #line hidden
WriteLiteral("\"");

WriteLiteral(" data-subjecturl=\"");

            
            #line 150 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                                                                                                                                                                              Write(Url.Action(MVC.API.System.Subject()));

            
            #line default
            #line hidden
WriteLiteral("\"");

WriteLiteral(" />\r\n                        <button");

WriteLiteral(" type=\"button\"");

WriteLiteral(" id=\"Config_Export_Edit_OnDemand_Add\"");

WriteLiteral(" class=\"button small\"");

WriteLiteral(">Add</button>\r\n                    </div>\r\n                    <div");

WriteLiteral(" class=\"info-box\"");

WriteLiteral(">\r\n                        <p");

WriteLiteral(" class=\"fa-p\"");

WriteLiteral(">\r\n                            <i");

WriteLiteral(" class=\"fa fa-fw fa-info-circle\"");

WriteLiteral("></i> Users with the Manage Saved Exports permission (including Disco ICT Adminis" +
"trators) can perform an on-demand export at any time.\r\n                         " +
"   Users or Group Members can be added to this list.\r\n");

            
            #line 157 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                            
            
            #line default
            #line hidden
            
            #line 157 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                             if (!Model.IsEnabled)
                            {

            
            #line default
            #line hidden
WriteLiteral("                                ");

WriteLiteral("These will also be able to perform an on-demand export using the link available a" +
"fter saving.");

WriteLiteral("\r\n");

            
            #line 160 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                            }

            
            #line default
            #line hidden
WriteLiteral("                        </p>\r\n                    </div>\r\n                </td>\r\n" +
"            </tr>\r\n");

            
            #line 165 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
            
            
            #line default
            #line hidden
            
            #line 165 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
             if (Model.IsEnabled)
            {
                var link = new Uri(Request.Url, Url.Action(MVC.Config.Export.Run(Model.Id)));

            
            #line default
            #line hidden
WriteLiteral("                <tr>\r\n                    <th>Link</th>\r\n                    <td>" +
"\r\n                        <input");

WriteLiteral(" type=\"text\"");

WriteAttribute("value", Tuple.Create(" value=\"", 8472), Tuple.Create("\"", 8485)
            
            #line 171 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create("", 8480), Tuple.Create<System.Object, System.Int32>(link
            
            #line default
            #line hidden
, 8480), false)
);

WriteLiteral(" style=\"width: 90%;\"");

WriteLiteral(" readonly data-clipboard />\r\n                    </td>\r\n                </tr>\r\n");

            
            #line 174 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
            }

            
            #line default
            #line hidden
WriteLiteral("        </table>\r\n    </div>\r\n");

            
            #line 177 "..\..\Areas\Config\Views\Export\_Edit.cshtml"


            
            #line default
            #line hidden
WriteLiteral("    <div");

WriteLiteral(" class=\"actionBar\"");

WriteLiteral(">\r\n");

            
            #line 179 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
        
            
            #line default
            #line hidden
            
            #line 179 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
         if (Model.IsEnabled)
        {
            if (Model.ScheduleEnabled)
            {

            
            #line default
            #line hidden
WriteLiteral("                <a");

WriteAttribute("href", Tuple.Create(" href=\"", 8776), Tuple.Create("\"", 8836)
            
            #line 183 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create("", 8783), Tuple.Create<System.Object, System.Int32>(Url.Action(MVC.Config.Export.RunScheduled(Model.Id))
            
            #line default
            #line hidden
, 8783), false)
);

WriteLiteral(" class=\"button\"");

WriteLiteral(">Schedule Now</a>\r\n");

            
            #line 184 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
            }


            
            #line default
            #line hidden
WriteLiteral("            <a");

WriteAttribute("href", Tuple.Create(" href=\"", 8902), Tuple.Create("\"", 8953)
            
            #line 186 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create("", 8909), Tuple.Create<System.Object, System.Int32>(Url.Action(MVC.Config.Export.Run(Model.Id))
            
            #line default
            #line hidden
, 8909), false)
);

WriteLiteral(" class=\"button\"");

WriteLiteral(">Export Now</a>\r\n");

            
            #line 187 "..\..\Areas\Config\Views\Export\_Edit.cshtml"


            
            #line default
            #line hidden
WriteLiteral("            <button");

WriteLiteral(" id=\"Config_Export_Edit_DeleteButton\"");

WriteLiteral(" type=\"button\"");

WriteLiteral(" class=\"button alert\"");

WriteLiteral(">Delete</button>\r\n");

            
            #line 189 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
        }

            
            #line default
            #line hidden
WriteLiteral("\r\n        <button");

WriteLiteral(" type=\"submit\"");

WriteLiteral(" class=\"button\"");

WriteLiteral(">Save</button>\r\n    </div>\r\n");

            
            #line 193 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
}

            
            #line default
            #line hidden
            
            #line 194 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
 if (Model.IsEnabled)
{

            
            #line default
            #line hidden
WriteLiteral("    <div");

WriteLiteral(" id=\"Config_Export_Edit_DeleteDialog\"");

WriteAttribute("title", Tuple.Create(" title=\"", 9256), Tuple.Create("\"", 9311)
, Tuple.Create(Tuple.Create("", 9264), Tuple.Create("Delete", 9264), true)
, Tuple.Create(Tuple.Create(" ", 9270), Tuple.Create("Saved", 9271), true)
            
            #line 196 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create(" ", 9276), Tuple.Create<System.Object, System.Int32>(Model.ExportTypeName
            
            #line default
            #line hidden
, 9277), false)
, Tuple.Create(Tuple.Create("", 9298), Tuple.Create(":", 9298), true)
            
            #line 196 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
        , Tuple.Create(Tuple.Create(" ", 9299), Tuple.Create<System.Object, System.Int32>(Model.Name
            
            #line default
            #line hidden
, 9300), false)
);

WriteLiteral(" class=\"dialog\"");

WriteLiteral(">\r\n        <div");

WriteLiteral(" class=\"info-box\"");

WriteLiteral(">\r\n            <p");

WriteLiteral(" class=\"fa-p\"");

WriteLiteral(">\r\n                <i");

WriteLiteral(" class=\"fa fa-exclamation-triangle\"");

WriteLiteral("></i>Are you sure you want to delete the Saved ");

            
            #line 199 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                                                                               Write(Model.ExportTypeName);

            
            #line default
            #line hidden
WriteLiteral(": ");

            
            #line 199 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                                                                                                      Write(Model.Name);

            
            #line default
            #line hidden
WriteLiteral("?\r\n            </p>\r\n        </div>\r\n");

            
            #line 202 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
        
            
            #line default
            #line hidden
            
            #line 202 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
         using (Html.BeginForm(MVC.API.Export.Delete(), FormMethod.Post))
        {
            
            
            #line default
            #line hidden
            
            #line 204 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
       Write(Html.AntiForgeryToken());

            
            #line default
            #line hidden
            
            #line 204 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
                                    

            
            #line default
            #line hidden
WriteLiteral("            <input");

WriteLiteral(" type=\"hidden\"");

WriteLiteral(" name=\"id\"");

WriteAttribute("value", Tuple.Create(" value=\"", 9729), Tuple.Create("\"", 9746)
            
            #line 205 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
, Tuple.Create(Tuple.Create("", 9737), Tuple.Create<System.Object, System.Int32>(Model.Id
            
            #line default
            #line hidden
, 9737), false)
);

WriteLiteral(" />\r\n");

            
            #line 206 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
        }

            
            #line default
            #line hidden
WriteLiteral("    </div>\r\n");

            
            #line 208 "..\..\Areas\Config\Views\Export\_Edit.cshtml"
}

            
            #line default
            #line hidden
WriteLiteral("<script>\r\n    $(function () {\r\n        $(\'#ScheduleEnabled\').on(\'change\', functio" +
"n () {\r\n            const enabled = $(this).is(\':checked\');\r\n            $(\'#Con" +
"fig_Export_Edit_Schedule tr:not(:first)\').toggleClass(\'hidden\', !enabled);\r\n    " +
"    });\r\n\r\n        const onDemandInput = $(\'#Config_Export_Edit_OnDemand_Input\')" +
";\r\n\r\n        onDemandInput\r\n            .autocomplete({\r\n                source:" +
" onDemandInput.attr(\'data-url\'),\r\n                minLength: 2,\r\n               " +
" focus: function (e, ui) {\r\n                    onDemandInput.val(ui.item.Id);\r\n" +
"                    return false;\r\n                },\r\n                select: f" +
"unction (e, ui) {\r\n                    onDemandInput.val(ui.item.Id).blur();\r\n  " +
"                  return false;\r\n                }\r\n            }).data(\'ui-auto" +
"complete\')._renderItem = function (ul, item) {\r\n                return $(\"<li></" +
"li>\")\r\n                    .data(\"item.autocomplete\", item)\r\n                   " +
" .append(\"<a><strong>\" + item.Name + \"</strong><br>\" + item.Id + \" (\" + item.Typ" +
"e + \")</a>\")\r\n                    .appendTo(ul);\r\n            };\r\n        $(\'#Co" +
"nfig_Export_Edit_OnDemand_Add\').on(\'click\', async function () {\r\n            con" +
"st id = onDemandInput.val();\r\n            const body = new FormData();\r\n        " +
"    body.append(\'Id\', id);\r\n            const response = await fetch(onDemandInp" +
"ut.attr(\'data-subjecturl\'), {\r\n                method: \'POST\',\r\n                " +
"body: body\r\n            });\r\n            if (!response.ok) {\r\n                al" +
"ert(\'Error: \' + response.statusText);\r\n                return;\r\n            }\r\n " +
"           const data = await response.json();\r\n\r\n            if (!data.IsGroup " +
"&& !data.IsUserAccount) {\r\n                alert(\'Error: Only users and groups c" +
"an be added.\');\r\n                return;\r\n            }\r\n\r\n            const $li" +
" = $(\'<li><input type=\"hidden\" name=\"OnDemandPrincipals\" /><i class=\"fa fa-lg\"><" +
"/i> <span></span><i class=\"fa fa-times-circle remove\"></i></li>\');\r\n            " +
"$li.find(\'input\').val(data.Id);\r\n            $li.find(\'i.fa-lg\').addClass(data.T" +
"ype === \'user\' ? \'fa-user\' : \'fa-users\');\r\n            $li.find(\'span\').text(dat" +
"a.Name + \' [\' + data.Id + \']\');\r\n            $li.appendTo(\'#Config_Export_Edit_O" +
"nDemand_List\');\r\n        });\r\n        $(\'#Config_Export_Edit_OnDemand_List\').on(" +
"\'click\', \'.remove\', function () {\r\n            $(this).closest(\'li\').remove();\r\n" +
"        })\r\n\r\n        let $deleteDialog = null;\r\n        $(\'#Config_Export_Edit_" +
"DeleteButton\').on(\'click\', function () {\r\n            if (!$deleteDialog) {\r\n   " +
"             $deleteDialog = $(\'#Config_Export_Edit_DeleteDialog\').dialog({\r\n   " +
"                 resizable: false,\r\n                    modal: true,\r\n          " +
"          width: 350,\r\n                    autoOpen: false,\r\n                   " +
" buttons: {\r\n                        \'Cancel\': function () {\r\n                  " +
"          $(this).dialog(\"close\");\r\n                        },\r\n                " +
"        \'Delete\': function () {\r\n                            $deleteDialog.find(" +
"\'form\').submit();\r\n                            $(this).dialog(\"disable\");\r\n     " +
"                   }\r\n                    }\r\n                });\r\n            }\r" +
"\n            $deleteDialog.dialog(\'open\');\r\n        })\r\n    })\r\n</script>\r\n");

        }
    }
}
#pragma warning restore 1591
