Feature: Plugin UI Extensions
Initially available for 'Job Show' action
This commit is contained in:
@@ -1448,6 +1448,9 @@ header .watermark,
|
||||
-webkit-border-radius: 0 0 6px 6px;
|
||||
border-radius: 0 0 6px 6px;
|
||||
}
|
||||
#layout_uiExtensions {
|
||||
display: none;
|
||||
}
|
||||
footer,
|
||||
#footer {
|
||||
color: #777;
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
@@ -270,6 +270,9 @@ header .watermark,
|
||||
-webkit-border-radius: 0 0 6px 6px;
|
||||
border-radius: 0 0 6px 6px;
|
||||
}
|
||||
#layout_uiExtensions {
|
||||
display: none;
|
||||
}
|
||||
footer,
|
||||
#footer {
|
||||
color: #777;
|
||||
|
||||
@@ -238,6 +238,10 @@ header, #header
|
||||
.border-radius4(0, 0, 6px, 6px);
|
||||
}
|
||||
|
||||
#layout_uiExtensions {
|
||||
display: none;
|
||||
}
|
||||
|
||||
footer, #footer
|
||||
{
|
||||
color: #777;
|
||||
|
||||
+1
-1
File diff suppressed because one or more lines are too long
@@ -1,468 +1,473 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.Mvc;
|
||||
using Disco.Data.Repository;
|
||||
using Disco.BI;
|
||||
using Disco.BI.Extensions;
|
||||
using Disco.Models.Repository;
|
||||
using System.Web.Script.Serialization;
|
||||
using Disco.Services.Plugins.Features.WarrantyProvider;
|
||||
using Disco.Services.Plugins;
|
||||
|
||||
namespace Disco.Web.Controllers
|
||||
{
|
||||
public partial class JobController : dbAdminController
|
||||
{
|
||||
|
||||
#region Index
|
||||
public virtual ActionResult Index()
|
||||
{
|
||||
var m = new Models.Job.IndexModel();
|
||||
|
||||
//m.MyJobs = JobBI.SelectJobSearchResultItem((from j in dbContext.Jobs
|
||||
// where j.OpenedTechUserId == DiscoApplication.CurrentUser.Id && j.ClosedDate == null && (j.DeviceHeld == null || j.DeviceReturnedDate != null || j.DeviceReadyForReturn == null)
|
||||
// select j));
|
||||
//m.OpenJobs = JobBI.SelectJobSearchResultItem((from j in dbContext.Jobs
|
||||
// where j.OpenedTechUserId != DiscoApplication.CurrentUser.Id && j.ClosedDate == null && (j.DeviceHeld == null || j.DeviceReturnedDate != null || j.DeviceReadyForReturn == null)
|
||||
// select j));
|
||||
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
|
||||
m.OpenJobs = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.OpenJobs.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null
|
||||
&& !j.WaitingForUserAction.HasValue
|
||||
&& !(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.RepairerLoggedDate.HasValue && j.JobMetaNonWarranty.IsInsuranceClaim && !j.JobMetaInsurance.ClaimFormSentDate.HasValue))
|
||||
&& !(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.RepairerLoggedDate.HasValue && !j.JobMetaNonWarranty.RepairerCompletedDate.HasValue))
|
||||
&& !(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.AccountingChargeAddedDate.HasValue && !j.JobMetaNonWarranty.AccountingChargePaidDate.HasValue))
|
||||
&& !(j.JobTypeId == JobType.JobTypeIds.HWar && (j.JobMetaWarranty.ExternalLoggedDate.HasValue && !j.JobMetaWarranty.ExternalCompletedDate.HasValue))
|
||||
&& (j.DeviceHeld == null || j.DeviceReturnedDate != null || j.DeviceReadyForReturn == null)).OrderBy(j => j.Id));
|
||||
|
||||
var longRunningThreshold = DateTime.Now.AddDays(-7);
|
||||
m.LongRunningJobs = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.LongRunningJobs.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null
|
||||
&& j.OpenedDate < longRunningThreshold).OrderBy(j => j.Id));
|
||||
|
||||
//m.WaitingForUserActionJobs = new Disco.Models.BI.Job.JobTableModel();
|
||||
//m.WaitingForUserActionJobs.Fill(Disco.BI.JobTableModelBI.BuildQuery(dbContext).Where(j => j.WaitingForUserAction.HasValue
|
||||
// && j.ClosedDate == null));
|
||||
|
||||
//m.ReadyForReturnJobs = new Disco.Models.BI.Job.JobTableModel();
|
||||
//m.ReadyForReturnJobs.Fill(BI.JobTableModelBI.BuildQuery(dbContext).Where(j => !j.WaitingForUserAction.HasValue
|
||||
// && j.DeviceHeld != null && j.DeviceReturnedDate == null && j.DeviceReadyForReturn != null
|
||||
// && j.ClosedDate == null));
|
||||
|
||||
//// 2 Days ago - Ignore Weekend
|
||||
//var dateTimeNow = DateTime.Now;
|
||||
//var closedThreshold = dateTimeNow.AddDays(-2);
|
||||
//if (dateTimeNow.DayOfWeek == DayOfWeek.Monday)
|
||||
// closedThreshold = closedThreshold.AddDays(-2);
|
||||
//if (dateTimeNow.DayOfWeek == DayOfWeek.Tuesday)
|
||||
// closedThreshold = closedThreshold.AddDays(-1);
|
||||
//m.RecentlyClosedJobs = new Disco.Models.BI.Job.JobTableModel();
|
||||
//m.RecentlyClosedJobs.Fill(BI.JobTableModelBI.BuildQuery(dbContext).Where(j => j.ClosedDate > closedThreshold));
|
||||
return View(m);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region Lists
|
||||
public virtual ActionResult AllOpen()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "All Open Jobs" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult DevicesReadyForReturn()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs with Devices Ready for Return" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => !j.WaitingForUserAction.HasValue
|
||||
&& j.DeviceHeld != null && j.DeviceReturnedDate == null && j.DeviceReadyForReturn != null &&
|
||||
((!j.JobMetaNonWarranty.AccountingChargeRequiredDate.HasValue && !j.JobMetaNonWarranty.AccountingChargeAddedDate.HasValue) || j.JobMetaNonWarranty.AccountingChargePaidDate.HasValue)
|
||||
&& j.ClosedDate == null).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult DevicesAwaitingRepair()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs with Devices Awaiting Repair" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null &&
|
||||
(
|
||||
(j.JobMetaNonWarranty.RepairerLoggedDate != null && j.JobMetaNonWarranty.RepairerCompletedDate == null) ||
|
||||
(j.JobMetaWarranty.ExternalLoggedDate != null && j.JobMetaWarranty.ExternalCompletedDate == null)
|
||||
)).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
|
||||
#region "Finance Lists"
|
||||
public virtual ActionResult AwaitingFinance()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs Awaiting Finance" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null &&
|
||||
(
|
||||
(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.IsInsuranceClaim && !j.JobMetaInsurance.ClaimFormSentDate.HasValue)) ||
|
||||
(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.AccountingChargeRequiredDate.HasValue && (!j.JobMetaNonWarranty.AccountingChargeAddedDate.HasValue && !j.JobMetaNonWarranty.AccountingChargePaidDate.HasValue))) ||
|
||||
(j.JobTypeId == JobType.JobTypeIds.HNWar && (!j.JobMetaNonWarranty.AccountingChargeAddedDate.HasValue || !j.JobMetaNonWarranty.AccountingChargePaidDate.HasValue)) ||
|
||||
(j.JobTypeId == JobType.JobTypeIds.UMgmt && (long)Job.UserManagementFlags.Infringement_BreachFinancialAgreement == (j.Flags & (long)Job.UserManagementFlags.Infringement_BreachFinancialAgreement))
|
||||
)));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
|
||||
public virtual ActionResult AwaitingFinanceCharge()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs Awaiting Finance - Accounting Charge" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null &&
|
||||
(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.AccountingChargeRequiredDate.HasValue && (!j.JobMetaNonWarranty.AccountingChargeAddedDate.HasValue && !j.JobMetaNonWarranty.AccountingChargePaidDate.HasValue)))
|
||||
).OrderBy(j => j.Id));
|
||||
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult AwaitingFinancePayment()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs Awaiting Finance - Accounting Payment" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null &&
|
||||
(j.JobTypeId == JobType.JobTypeIds.HNWar && (!j.JobMetaNonWarranty.AccountingChargeAddedDate.HasValue || !j.JobMetaNonWarranty.AccountingChargePaidDate.HasValue))
|
||||
).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult AwaitingFinanceInsuranceProcessing()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs Awaiting Finance - Insurance Processing" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null &&
|
||||
(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.IsInsuranceClaim && !j.JobMetaInsurance.ClaimFormSentDate.HasValue))
|
||||
).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult AwaitingFinanceAgreementBreach()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs Awaiting Finance - Agreement Breach" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null &&
|
||||
(j.JobTypeId == JobType.JobTypeIds.UMgmt && (long)Job.UserManagementFlags.Infringement_BreachFinancialAgreement == (j.Flags & (long)Job.UserManagementFlags.Infringement_BreachFinancialAgreement))
|
||||
).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
public virtual ActionResult AwaitingUserAction()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs Awaiting User Action" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => (j.WaitingForUserAction.HasValue || (j.JobMetaNonWarranty.AccountingChargeAddedDate != null && j.JobMetaNonWarranty.AccountingChargePaidDate == null))
|
||||
&& j.ClosedDate == null).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult RecentlyClosed()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Recently Closed Jobs" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
|
||||
var dateTimeNow = DateTime.Now;
|
||||
var closedThreshold = dateTimeNow.AddDays(-2);
|
||||
if (dateTimeNow.DayOfWeek == DayOfWeek.Monday)
|
||||
closedThreshold = closedThreshold.AddDays(-2);
|
||||
if (dateTimeNow.DayOfWeek == DayOfWeek.Tuesday)
|
||||
closedThreshold = closedThreshold.AddDays(-1);
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate > closedThreshold).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult Locations()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Held Device Locations" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true, ShowLocation = true, ShowTechnician = false, ShowType = false };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null && j.DeviceHeld.HasValue && !j.DeviceReturnedDate.HasValue).OrderBy(j => j.DeviceHeldLocation));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Show
|
||||
public virtual ActionResult Show(int? id)
|
||||
{
|
||||
if (!id.HasValue)
|
||||
return RedirectToAction(MVC.Job.Index());
|
||||
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
|
||||
var m = new Models.Job.ShowModel();
|
||||
|
||||
m.Job = (from j in dbContext.Jobs.Include("Device.DeviceModel").Include("Device.DeviceBatch").Include("DeviceHeldTechUser").Include("DeviceReadyForReturnTechUser").Include("DeviceReturnedTechUser")
|
||||
.Include("OpenedTechUser").Include("ClosedTechUser").Include("JobType").Include("JobSubTypes").Include("User").Include("JobLogs.TechUser")
|
||||
where (j.Id == id.Value)
|
||||
select j).FirstOrDefault();
|
||||
|
||||
m.UpdatableJobSubTypes = m.Job.JobType.JobSubTypes.OrderBy(jst => jst.Description).ToList();
|
||||
|
||||
m.DocumentTemplates = m.Job.AvailableDocumentTemplates(dbContext, DiscoApplication.CurrentUser, DateTime.Now);
|
||||
|
||||
return View(m);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region Create
|
||||
public virtual ActionResult Create(string DeviceSerialNumber, string UserId)
|
||||
{
|
||||
var m = new Models.Job.CreateModel()
|
||||
{
|
||||
DeviceSerialNumber = DeviceSerialNumber,
|
||||
UserId = UserId
|
||||
};
|
||||
m.UpdateModel(dbContext);
|
||||
|
||||
return View(m);
|
||||
}
|
||||
[HttpPost]
|
||||
public virtual ActionResult Create(Models.Job.CreateModel m)
|
||||
{
|
||||
m.UpdateModel(dbContext);
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
{
|
||||
return View(m);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Create New Job
|
||||
var currentUser = dbContext.Users.Find(DiscoApplication.CurrentUser.Id);
|
||||
var j = BI.JobBI.Utilities.Create(dbContext, m.Device, m.User, m.GetJobType, m.GetJobSubTypes, currentUser);
|
||||
|
||||
if (m.DeviceHeld.Value)
|
||||
{
|
||||
j.OnDeviceHeld(currentUser);
|
||||
m.QuickLog = false;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (m.QuickLog.HasValue && m.QuickLog.Value && m.QuickLogTaskTimeMinutes.HasValue && m.QuickLogTaskTimeMinutes.Value > 0)
|
||||
{
|
||||
// Quick Log
|
||||
// Set Opened Date in the past
|
||||
j.OpenedDate = DateTime.Now.AddMinutes(-1 * m.QuickLogTaskTimeMinutes.Value);
|
||||
// Close Job
|
||||
j.OnClose(currentUser);
|
||||
}
|
||||
else
|
||||
{
|
||||
m.QuickLog = false;
|
||||
}
|
||||
}
|
||||
|
||||
// Add Comments
|
||||
if (!string.IsNullOrWhiteSpace(m.Comments))
|
||||
{
|
||||
var jl = new Disco.Models.Repository.JobLog()
|
||||
{
|
||||
Job = j,
|
||||
TechUser = currentUser,
|
||||
Timestamp = DateTime.Now,
|
||||
Comments = m.Comments
|
||||
};
|
||||
dbContext.JobLogs.Add(jl);
|
||||
}
|
||||
|
||||
dbContext.SaveChanges();
|
||||
|
||||
// Return Dialog Redirect
|
||||
var redirectModel = new Models.Job.CreateRedirectModel();
|
||||
if (m.QuickLog.HasValue && m.QuickLog.Value && !string.IsNullOrWhiteSpace(m.QuickLogDestinationUrl))
|
||||
redirectModel.RedirectLink = m.QuickLogDestinationUrl;
|
||||
else
|
||||
redirectModel.RedirectLink = Url.Action(MVC.Job.Show(j.Id));
|
||||
|
||||
return View(Views.Create_Redirect, redirectModel);
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
// Decommissioned 2012-11-28 G# - Moved to new infrastructure
|
||||
#region Create - Old
|
||||
//public virtual ActionResult Create(string DeviceSerialNumber, string UserId)
|
||||
//{
|
||||
// var m = new Models.Job.CreateModel()
|
||||
// {
|
||||
// DeviceSerialNumber = DeviceSerialNumber,
|
||||
// UserId = UserId
|
||||
// };
|
||||
// m.UpdateModel(dbContext);
|
||||
|
||||
// return View(m);
|
||||
//}
|
||||
//[HttpPost]
|
||||
//public virtual ActionResult Create(Models.Job.CreateModel m)
|
||||
//{
|
||||
// m.UpdateModel(dbContext);
|
||||
|
||||
// if (!ModelState.IsValid)
|
||||
// {
|
||||
// return View(m);
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// // Create New Job
|
||||
// var currentUser = dbContext.Users.Find(DiscoApplication.CurrentUser.Id);
|
||||
// var j = BI.JobBI.Utilities.Create(dbContext, m.Device, m.User, m.GetJobType, m.GetJobSubTypes, currentUser);
|
||||
// dbContext.SaveChanges();
|
||||
// return RedirectToAction(MVC.Job.Show(j.Id));
|
||||
// }
|
||||
//}
|
||||
#endregion
|
||||
// End Decommissioned 2012-11-28 G#
|
||||
|
||||
#region Log Warranty
|
||||
public virtual ActionResult LogWarranty(int id, string WarrantyProviderId, int? OrganisationAddressId)
|
||||
{
|
||||
var m = new Models.Job.LogWarrantyModel() { JobId = id, WarrantyProviderId = WarrantyProviderId, OrganisationAddressId = OrganisationAddressId };
|
||||
m.UpdateModel(dbContext, false);
|
||||
m.FaultDescription = m.Job.GenerateFaultDescription(dbContext);
|
||||
|
||||
if (m.WarrantyProvider != null)
|
||||
{
|
||||
using (var wp = m.WarrantyProvider.CreateInstance<WarrantyProviderFeature>())
|
||||
{
|
||||
if (wp.SubmitJobViewType != null)
|
||||
{
|
||||
m.WarrantyProviderSubmitJobViewType = wp.SubmitJobViewType;
|
||||
m.WarrantyProviderSubmitJobModel = wp.SubmitJobViewModel(dbContext, this, m.Job, m.OrganisationAddress, m.TechUser);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return View(m);
|
||||
}
|
||||
[HttpPost]
|
||||
public virtual ActionResult LogWarranty(Models.Job.LogWarrantyModel m, FormCollection form)
|
||||
{
|
||||
m.UpdateModel(dbContext, true);
|
||||
|
||||
if (ModelState.IsValid)
|
||||
{
|
||||
switch (m.WarrantyAction)
|
||||
{
|
||||
case "Disclose":
|
||||
using (var p = m.WarrantyProvider.CreateInstance<WarrantyProviderFeature>())
|
||||
{
|
||||
Dictionary<string, string> warrantyProviderProperties;
|
||||
try
|
||||
{
|
||||
warrantyProviderProperties = p.SubmitJobParseProperties(dbContext, form, this, m.Job, m.OrganisationAddress, m.TechUser, m.FaultDescription);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
m.Error = ex;
|
||||
return View(Views.LogWarrantyError, m);
|
||||
}
|
||||
if (!ModelState.IsValid)
|
||||
return View(Views.LogWarranty, m);
|
||||
|
||||
if (warrantyProviderProperties != null)
|
||||
{
|
||||
JavaScriptSerializer j = new JavaScriptSerializer();
|
||||
m.WarrantyProviderPropertiesJson = j.Serialize(warrantyProviderProperties);
|
||||
}
|
||||
m.DiscloseProperties = p.SubmitJobDiscloseInfo(dbContext, m.Job, m.OrganisationAddress, m.TechUser, m.FaultDescription, warrantyProviderProperties);
|
||||
return View(Views.LogWarrantyDisclose, m);
|
||||
}
|
||||
case "Submit":
|
||||
try
|
||||
{
|
||||
m.Job.OnLogWarranty(dbContext, m.FaultDescription, m.WarrantyProvider, m.OrganisationAddress, m.TechUser, m.WarrantyProviderProperties());
|
||||
dbContext.SaveChanges();
|
||||
return RedirectToAction(MVC.Job.Show(m.JobId));
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
m.Error = ex;
|
||||
return View(Views.LogWarrantyError, m);
|
||||
throw;
|
||||
}
|
||||
default:
|
||||
return RedirectToAction(MVC.Job.Show(m.JobId));
|
||||
}
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
return View(Views.LogWarranty, m);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual ActionResult WarrantyProviderJobDetails(int id)
|
||||
{
|
||||
Models.Job.WarrantyProviderJobDetailsModel model = new Models.Job.WarrantyProviderJobDetailsModel();
|
||||
|
||||
Job job = dbContext.Jobs.Include("Device.DeviceModel").Include("JobMetaWarranty").Include("JobSubTypes").Where(j => j.Id == id).FirstOrDefault();
|
||||
if (job != null)
|
||||
{
|
||||
if (job.JobMetaWarranty != null && !string.IsNullOrEmpty(job.JobMetaWarranty.ExternalName))
|
||||
{
|
||||
var providerDef = WarrantyProviderFeature.FindPluginFeature(job.JobMetaWarranty.ExternalName);
|
||||
|
||||
if (providerDef != null)
|
||||
{
|
||||
using (WarrantyProviderFeature providerInstance = providerDef.CreateInstance<WarrantyProviderFeature>())
|
||||
{
|
||||
if (providerInstance.JobDetailsSupported)
|
||||
{
|
||||
try
|
||||
{
|
||||
object providerModel = providerInstance.JobDetailsViewModel(dbContext, this, job);
|
||||
|
||||
model.JobDetailsSupported = true;
|
||||
model.ViewType = providerInstance.JobDetailsViewType;
|
||||
model.ViewModel = providerModel;
|
||||
return View(model);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
model.JobDetailsSupported = false;
|
||||
model.JobDetailsException = ex;
|
||||
return View(model);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
model.JobDetailsSupported = false;
|
||||
model.JobDetailsNotSupportedMessage = string.Format("Plugin '{0} ({1})' (Warranty Provider for '{2}') doesn't support Job Details", providerInstance.Manifest.Name, providerInstance.Manifest.Id, providerInstance.WarrantyProviderId);
|
||||
return View(model);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
model.JobDetailsSupported = false;
|
||||
model.JobDetailsNotSupportedMessage = string.Format("Warranty Provider '{0}' is not integrated with Disco", job.JobMetaWarranty.ExternalName);
|
||||
return View(model);
|
||||
}
|
||||
else
|
||||
{
|
||||
model.JobDetailsSupported = false;
|
||||
model.JobDetailsNotSupportedMessage = "Job not in the correct state";
|
||||
return View(model);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
return HttpNotFound("Invalid Job Id");
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
}
|
||||
}
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.Mvc;
|
||||
using Disco.Data.Repository;
|
||||
using Disco.BI;
|
||||
using Disco.BI.Extensions;
|
||||
using Disco.Models.Repository;
|
||||
using System.Web.Script.Serialization;
|
||||
using Disco.Services.Plugins.Features.WarrantyProvider;
|
||||
using Disco.Services.Plugins;
|
||||
using Disco.Services.UIExtensions;
|
||||
using Disco.Models.UI.Job;
|
||||
|
||||
namespace Disco.Web.Controllers
|
||||
{
|
||||
public partial class JobController : dbAdminController
|
||||
{
|
||||
|
||||
#region Index
|
||||
public virtual ActionResult Index()
|
||||
{
|
||||
var m = new Models.Job.IndexModel();
|
||||
|
||||
//m.MyJobs = JobBI.SelectJobSearchResultItem((from j in dbContext.Jobs
|
||||
// where j.OpenedTechUserId == DiscoApplication.CurrentUser.Id && j.ClosedDate == null && (j.DeviceHeld == null || j.DeviceReturnedDate != null || j.DeviceReadyForReturn == null)
|
||||
// select j));
|
||||
//m.OpenJobs = JobBI.SelectJobSearchResultItem((from j in dbContext.Jobs
|
||||
// where j.OpenedTechUserId != DiscoApplication.CurrentUser.Id && j.ClosedDate == null && (j.DeviceHeld == null || j.DeviceReturnedDate != null || j.DeviceReadyForReturn == null)
|
||||
// select j));
|
||||
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
|
||||
m.OpenJobs = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.OpenJobs.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null
|
||||
&& !j.WaitingForUserAction.HasValue
|
||||
&& !(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.RepairerLoggedDate.HasValue && j.JobMetaNonWarranty.IsInsuranceClaim && !j.JobMetaInsurance.ClaimFormSentDate.HasValue))
|
||||
&& !(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.RepairerLoggedDate.HasValue && !j.JobMetaNonWarranty.RepairerCompletedDate.HasValue))
|
||||
&& !(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.AccountingChargeAddedDate.HasValue && !j.JobMetaNonWarranty.AccountingChargePaidDate.HasValue))
|
||||
&& !(j.JobTypeId == JobType.JobTypeIds.HWar && (j.JobMetaWarranty.ExternalLoggedDate.HasValue && !j.JobMetaWarranty.ExternalCompletedDate.HasValue))
|
||||
&& (j.DeviceHeld == null || j.DeviceReturnedDate != null || j.DeviceReadyForReturn == null)).OrderBy(j => j.Id));
|
||||
|
||||
var longRunningThreshold = DateTime.Now.AddDays(-7);
|
||||
m.LongRunningJobs = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.LongRunningJobs.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null
|
||||
&& j.OpenedDate < longRunningThreshold).OrderBy(j => j.Id));
|
||||
|
||||
//m.WaitingForUserActionJobs = new Disco.Models.BI.Job.JobTableModel();
|
||||
//m.WaitingForUserActionJobs.Fill(Disco.BI.JobTableModelBI.BuildQuery(dbContext).Where(j => j.WaitingForUserAction.HasValue
|
||||
// && j.ClosedDate == null));
|
||||
|
||||
//m.ReadyForReturnJobs = new Disco.Models.BI.Job.JobTableModel();
|
||||
//m.ReadyForReturnJobs.Fill(BI.JobTableModelBI.BuildQuery(dbContext).Where(j => !j.WaitingForUserAction.HasValue
|
||||
// && j.DeviceHeld != null && j.DeviceReturnedDate == null && j.DeviceReadyForReturn != null
|
||||
// && j.ClosedDate == null));
|
||||
|
||||
//// 2 Days ago - Ignore Weekend
|
||||
//var dateTimeNow = DateTime.Now;
|
||||
//var closedThreshold = dateTimeNow.AddDays(-2);
|
||||
//if (dateTimeNow.DayOfWeek == DayOfWeek.Monday)
|
||||
// closedThreshold = closedThreshold.AddDays(-2);
|
||||
//if (dateTimeNow.DayOfWeek == DayOfWeek.Tuesday)
|
||||
// closedThreshold = closedThreshold.AddDays(-1);
|
||||
//m.RecentlyClosedJobs = new Disco.Models.BI.Job.JobTableModel();
|
||||
//m.RecentlyClosedJobs.Fill(BI.JobTableModelBI.BuildQuery(dbContext).Where(j => j.ClosedDate > closedThreshold));
|
||||
return View(m);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region Lists
|
||||
public virtual ActionResult AllOpen()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "All Open Jobs" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult DevicesReadyForReturn()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs with Devices Ready for Return" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => !j.WaitingForUserAction.HasValue
|
||||
&& j.DeviceHeld != null && j.DeviceReturnedDate == null && j.DeviceReadyForReturn != null &&
|
||||
((!j.JobMetaNonWarranty.AccountingChargeRequiredDate.HasValue && !j.JobMetaNonWarranty.AccountingChargeAddedDate.HasValue) || j.JobMetaNonWarranty.AccountingChargePaidDate.HasValue)
|
||||
&& j.ClosedDate == null).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult DevicesAwaitingRepair()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs with Devices Awaiting Repair" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null &&
|
||||
(
|
||||
(j.JobMetaNonWarranty.RepairerLoggedDate != null && j.JobMetaNonWarranty.RepairerCompletedDate == null) ||
|
||||
(j.JobMetaWarranty.ExternalLoggedDate != null && j.JobMetaWarranty.ExternalCompletedDate == null)
|
||||
)).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
|
||||
#region "Finance Lists"
|
||||
public virtual ActionResult AwaitingFinance()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs Awaiting Finance" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null &&
|
||||
(
|
||||
(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.IsInsuranceClaim && !j.JobMetaInsurance.ClaimFormSentDate.HasValue)) ||
|
||||
(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.AccountingChargeRequiredDate.HasValue && (!j.JobMetaNonWarranty.AccountingChargeAddedDate.HasValue && !j.JobMetaNonWarranty.AccountingChargePaidDate.HasValue))) ||
|
||||
(j.JobTypeId == JobType.JobTypeIds.HNWar && (!j.JobMetaNonWarranty.AccountingChargeAddedDate.HasValue || !j.JobMetaNonWarranty.AccountingChargePaidDate.HasValue)) ||
|
||||
(j.JobTypeId == JobType.JobTypeIds.UMgmt && (long)Job.UserManagementFlags.Infringement_BreachFinancialAgreement == (j.Flags & (long)Job.UserManagementFlags.Infringement_BreachFinancialAgreement))
|
||||
)));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
|
||||
public virtual ActionResult AwaitingFinanceCharge()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs Awaiting Finance - Accounting Charge" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null &&
|
||||
(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.AccountingChargeRequiredDate.HasValue && (!j.JobMetaNonWarranty.AccountingChargeAddedDate.HasValue && !j.JobMetaNonWarranty.AccountingChargePaidDate.HasValue)))
|
||||
).OrderBy(j => j.Id));
|
||||
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult AwaitingFinancePayment()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs Awaiting Finance - Accounting Payment" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null &&
|
||||
(j.JobTypeId == JobType.JobTypeIds.HNWar && (!j.JobMetaNonWarranty.AccountingChargeAddedDate.HasValue || !j.JobMetaNonWarranty.AccountingChargePaidDate.HasValue))
|
||||
).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult AwaitingFinanceInsuranceProcessing()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs Awaiting Finance - Insurance Processing" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null &&
|
||||
(j.JobTypeId == JobType.JobTypeIds.HNWar && (j.JobMetaNonWarranty.IsInsuranceClaim && !j.JobMetaInsurance.ClaimFormSentDate.HasValue))
|
||||
).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult AwaitingFinanceAgreementBreach()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs Awaiting Finance - Agreement Breach" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null &&
|
||||
(j.JobTypeId == JobType.JobTypeIds.UMgmt && (long)Job.UserManagementFlags.Infringement_BreachFinancialAgreement == (j.Flags & (long)Job.UserManagementFlags.Infringement_BreachFinancialAgreement))
|
||||
).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
public virtual ActionResult AwaitingUserAction()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Jobs Awaiting User Action" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => (j.WaitingForUserAction.HasValue || (j.JobMetaNonWarranty.AccountingChargeAddedDate != null && j.JobMetaNonWarranty.AccountingChargePaidDate == null))
|
||||
&& j.ClosedDate == null).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult RecentlyClosed()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Recently Closed Jobs" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true };
|
||||
|
||||
var dateTimeNow = DateTime.Now;
|
||||
var closedThreshold = dateTimeNow.AddDays(-2);
|
||||
if (dateTimeNow.DayOfWeek == DayOfWeek.Monday)
|
||||
closedThreshold = closedThreshold.AddDays(-2);
|
||||
if (dateTimeNow.DayOfWeek == DayOfWeek.Tuesday)
|
||||
closedThreshold = closedThreshold.AddDays(-1);
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate > closedThreshold).OrderBy(j => j.Id));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
public virtual ActionResult Locations()
|
||||
{
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
var m = new Models.Job.ListModel() { Title = "Held Device Locations" };
|
||||
m.JobTable = new Disco.Models.BI.Job.JobTableModel() { ShowStatus = true, ShowLocation = true, ShowTechnician = false, ShowType = false };
|
||||
m.JobTable.Fill(dbContext, BI.JobBI.Searching.BuildJobTableModel(dbContext).Where(j => j.ClosedDate == null && j.DeviceHeld.HasValue && !j.DeviceReturnedDate.HasValue).OrderBy(j => j.DeviceHeldLocation));
|
||||
return View(Views.List, m);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Show
|
||||
public virtual ActionResult Show(int? id)
|
||||
{
|
||||
if (!id.HasValue)
|
||||
return RedirectToAction(MVC.Job.Index());
|
||||
|
||||
dbContext.Configuration.LazyLoadingEnabled = true;
|
||||
|
||||
var m = new Models.Job.ShowModel();
|
||||
|
||||
m.Job = (from j in dbContext.Jobs.Include("Device.DeviceModel").Include("Device.DeviceBatch").Include("DeviceHeldTechUser").Include("DeviceReadyForReturnTechUser").Include("DeviceReturnedTechUser")
|
||||
.Include("OpenedTechUser").Include("ClosedTechUser").Include("JobType").Include("JobSubTypes").Include("User").Include("JobLogs.TechUser")
|
||||
where (j.Id == id.Value)
|
||||
select j).FirstOrDefault();
|
||||
|
||||
m.UpdatableJobSubTypes = m.Job.JobType.JobSubTypes.OrderBy(jst => jst.Description).ToList();
|
||||
|
||||
m.AvailableDocumentTemplates = m.Job.AvailableDocumentTemplates(dbContext, DiscoApplication.CurrentUser, DateTime.Now);
|
||||
|
||||
// UI Extensions
|
||||
UIExtensions.ExecuteExtensions<JobShowModel>(this.ControllerContext, m);
|
||||
|
||||
return View(m);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region Create
|
||||
public virtual ActionResult Create(string DeviceSerialNumber, string UserId)
|
||||
{
|
||||
var m = new Models.Job.CreateModel()
|
||||
{
|
||||
DeviceSerialNumber = DeviceSerialNumber,
|
||||
UserId = UserId
|
||||
};
|
||||
m.UpdateModel(dbContext);
|
||||
|
||||
return View(m);
|
||||
}
|
||||
[HttpPost]
|
||||
public virtual ActionResult Create(Models.Job.CreateModel m)
|
||||
{
|
||||
m.UpdateModel(dbContext);
|
||||
|
||||
if (!ModelState.IsValid)
|
||||
{
|
||||
return View(m);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Create New Job
|
||||
var currentUser = dbContext.Users.Find(DiscoApplication.CurrentUser.Id);
|
||||
var j = BI.JobBI.Utilities.Create(dbContext, m.Device, m.User, m.GetJobType, m.GetJobSubTypes, currentUser);
|
||||
|
||||
if (m.DeviceHeld.Value)
|
||||
{
|
||||
j.OnDeviceHeld(currentUser);
|
||||
m.QuickLog = false;
|
||||
}
|
||||
else
|
||||
{
|
||||
if (m.QuickLog.HasValue && m.QuickLog.Value && m.QuickLogTaskTimeMinutes.HasValue && m.QuickLogTaskTimeMinutes.Value > 0)
|
||||
{
|
||||
// Quick Log
|
||||
// Set Opened Date in the past
|
||||
j.OpenedDate = DateTime.Now.AddMinutes(-1 * m.QuickLogTaskTimeMinutes.Value);
|
||||
// Close Job
|
||||
j.OnClose(currentUser);
|
||||
}
|
||||
else
|
||||
{
|
||||
m.QuickLog = false;
|
||||
}
|
||||
}
|
||||
|
||||
// Add Comments
|
||||
if (!string.IsNullOrWhiteSpace(m.Comments))
|
||||
{
|
||||
var jl = new Disco.Models.Repository.JobLog()
|
||||
{
|
||||
Job = j,
|
||||
TechUser = currentUser,
|
||||
Timestamp = DateTime.Now,
|
||||
Comments = m.Comments
|
||||
};
|
||||
dbContext.JobLogs.Add(jl);
|
||||
}
|
||||
|
||||
dbContext.SaveChanges();
|
||||
|
||||
// Return Dialog Redirect
|
||||
var redirectModel = new Models.Job.CreateRedirectModel();
|
||||
if (m.QuickLog.HasValue && m.QuickLog.Value && !string.IsNullOrWhiteSpace(m.QuickLogDestinationUrl))
|
||||
redirectModel.RedirectLink = m.QuickLogDestinationUrl;
|
||||
else
|
||||
redirectModel.RedirectLink = Url.Action(MVC.Job.Show(j.Id));
|
||||
|
||||
return View(Views.Create_Redirect, redirectModel);
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
// Decommissioned 2012-11-28 G# - Moved to new infrastructure
|
||||
#region Create - Old
|
||||
//public virtual ActionResult Create(string DeviceSerialNumber, string UserId)
|
||||
//{
|
||||
// var m = new Models.Job.CreateModel()
|
||||
// {
|
||||
// DeviceSerialNumber = DeviceSerialNumber,
|
||||
// UserId = UserId
|
||||
// };
|
||||
// m.UpdateModel(dbContext);
|
||||
|
||||
// return View(m);
|
||||
//}
|
||||
//[HttpPost]
|
||||
//public virtual ActionResult Create(Models.Job.CreateModel m)
|
||||
//{
|
||||
// m.UpdateModel(dbContext);
|
||||
|
||||
// if (!ModelState.IsValid)
|
||||
// {
|
||||
// return View(m);
|
||||
// }
|
||||
// else
|
||||
// {
|
||||
// // Create New Job
|
||||
// var currentUser = dbContext.Users.Find(DiscoApplication.CurrentUser.Id);
|
||||
// var j = BI.JobBI.Utilities.Create(dbContext, m.Device, m.User, m.GetJobType, m.GetJobSubTypes, currentUser);
|
||||
// dbContext.SaveChanges();
|
||||
// return RedirectToAction(MVC.Job.Show(j.Id));
|
||||
// }
|
||||
//}
|
||||
#endregion
|
||||
// End Decommissioned 2012-11-28 G#
|
||||
|
||||
#region Log Warranty
|
||||
public virtual ActionResult LogWarranty(int id, string WarrantyProviderId, int? OrganisationAddressId)
|
||||
{
|
||||
var m = new Models.Job.LogWarrantyModel() { JobId = id, WarrantyProviderId = WarrantyProviderId, OrganisationAddressId = OrganisationAddressId };
|
||||
m.UpdateModel(dbContext, false);
|
||||
m.FaultDescription = m.Job.GenerateFaultDescription(dbContext);
|
||||
|
||||
if (m.WarrantyProvider != null)
|
||||
{
|
||||
using (var wp = m.WarrantyProvider.CreateInstance<WarrantyProviderFeature>())
|
||||
{
|
||||
if (wp.SubmitJobViewType != null)
|
||||
{
|
||||
m.WarrantyProviderSubmitJobViewType = wp.SubmitJobViewType;
|
||||
m.WarrantyProviderSubmitJobModel = wp.SubmitJobViewModel(dbContext, this, m.Job, m.OrganisationAddress, m.TechUser);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return View(m);
|
||||
}
|
||||
[HttpPost]
|
||||
public virtual ActionResult LogWarranty(Models.Job.LogWarrantyModel m, FormCollection form)
|
||||
{
|
||||
m.UpdateModel(dbContext, true);
|
||||
|
||||
if (ModelState.IsValid)
|
||||
{
|
||||
switch (m.WarrantyAction)
|
||||
{
|
||||
case "Disclose":
|
||||
using (var p = m.WarrantyProvider.CreateInstance<WarrantyProviderFeature>())
|
||||
{
|
||||
Dictionary<string, string> warrantyProviderProperties;
|
||||
try
|
||||
{
|
||||
warrantyProviderProperties = p.SubmitJobParseProperties(dbContext, form, this, m.Job, m.OrganisationAddress, m.TechUser, m.FaultDescription);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
m.Error = ex;
|
||||
return View(Views.LogWarrantyError, m);
|
||||
}
|
||||
if (!ModelState.IsValid)
|
||||
return View(Views.LogWarranty, m);
|
||||
|
||||
if (warrantyProviderProperties != null)
|
||||
{
|
||||
JavaScriptSerializer j = new JavaScriptSerializer();
|
||||
m.WarrantyProviderPropertiesJson = j.Serialize(warrantyProviderProperties);
|
||||
}
|
||||
m.DiscloseProperties = p.SubmitJobDiscloseInfo(dbContext, m.Job, m.OrganisationAddress, m.TechUser, m.FaultDescription, warrantyProviderProperties);
|
||||
return View(Views.LogWarrantyDisclose, m);
|
||||
}
|
||||
case "Submit":
|
||||
try
|
||||
{
|
||||
m.Job.OnLogWarranty(dbContext, m.FaultDescription, m.WarrantyProvider, m.OrganisationAddress, m.TechUser, m.WarrantyProviderProperties());
|
||||
dbContext.SaveChanges();
|
||||
return RedirectToAction(MVC.Job.Show(m.JobId));
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
m.Error = ex;
|
||||
return View(Views.LogWarrantyError, m);
|
||||
throw;
|
||||
}
|
||||
default:
|
||||
return RedirectToAction(MVC.Job.Show(m.JobId));
|
||||
}
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
return View(Views.LogWarranty, m);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual ActionResult WarrantyProviderJobDetails(int id)
|
||||
{
|
||||
Models.Job.WarrantyProviderJobDetailsModel model = new Models.Job.WarrantyProviderJobDetailsModel();
|
||||
|
||||
Job job = dbContext.Jobs.Include("Device.DeviceModel").Include("JobMetaWarranty").Include("JobSubTypes").Where(j => j.Id == id).FirstOrDefault();
|
||||
if (job != null)
|
||||
{
|
||||
if (job.JobMetaWarranty != null && !string.IsNullOrEmpty(job.JobMetaWarranty.ExternalName))
|
||||
{
|
||||
var providerDef = WarrantyProviderFeature.FindPluginFeature(job.JobMetaWarranty.ExternalName);
|
||||
|
||||
if (providerDef != null)
|
||||
{
|
||||
using (WarrantyProviderFeature providerInstance = providerDef.CreateInstance<WarrantyProviderFeature>())
|
||||
{
|
||||
if (providerInstance.JobDetailsSupported)
|
||||
{
|
||||
try
|
||||
{
|
||||
object providerModel = providerInstance.JobDetailsViewModel(dbContext, this, job);
|
||||
|
||||
model.JobDetailsSupported = true;
|
||||
model.ViewType = providerInstance.JobDetailsViewType;
|
||||
model.ViewModel = providerModel;
|
||||
return View(model);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
model.JobDetailsSupported = false;
|
||||
model.JobDetailsException = ex;
|
||||
return View(model);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
model.JobDetailsSupported = false;
|
||||
model.JobDetailsNotSupportedMessage = string.Format("Plugin '{0} ({1})' (Warranty Provider for '{2}') doesn't support Job Details", providerInstance.Manifest.Name, providerInstance.Manifest.Id, providerInstance.WarrantyProviderId);
|
||||
return View(model);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
model.JobDetailsSupported = false;
|
||||
model.JobDetailsNotSupportedMessage = string.Format("Warranty Provider '{0}' is not integrated with Disco", job.JobMetaWarranty.ExternalName);
|
||||
return View(model);
|
||||
}
|
||||
else
|
||||
{
|
||||
model.JobDetailsSupported = false;
|
||||
model.JobDetailsNotSupportedMessage = "Job not in the correct state";
|
||||
return View(model);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
return HttpNotFound("Invalid Job Id");
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,29 +1,30 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.Mvc;
|
||||
using Disco.BI.Extensions;
|
||||
using Disco.Web.Extensions;
|
||||
|
||||
namespace Disco.Web.Models.Job
|
||||
{
|
||||
public class ShowModel
|
||||
{
|
||||
public Disco.Models.Repository.Job Job { get; set; }
|
||||
|
||||
public List<Disco.Models.Repository.DocumentTemplate> DocumentTemplates { get; set; }
|
||||
public List<Disco.Models.Repository.JobSubType> UpdatableJobSubTypes { get; set; }
|
||||
|
||||
public List<SelectListItem> DocumentTemplatesSelectListItems
|
||||
{
|
||||
get
|
||||
{
|
||||
var list = new List<SelectListItem>();
|
||||
list.Add(new SelectListItem() { Selected = true, Value = string.Empty, Text = "Generate Document" });
|
||||
list.AddRange(this.DocumentTemplates.ToSelectListItems());
|
||||
return list;
|
||||
}
|
||||
}
|
||||
}
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.Mvc;
|
||||
using Disco.BI.Extensions;
|
||||
using Disco.Models.UI.Job;
|
||||
using Disco.Web.Extensions;
|
||||
|
||||
namespace Disco.Web.Models.Job
|
||||
{
|
||||
public class ShowModel : JobShowModel
|
||||
{
|
||||
public Disco.Models.Repository.Job Job { get; set; }
|
||||
|
||||
public List<Disco.Models.Repository.DocumentTemplate> AvailableDocumentTemplates { get; set; }
|
||||
public List<Disco.Models.Repository.JobSubType> UpdatableJobSubTypes { get; set; }
|
||||
|
||||
public List<SelectListItem> DocumentTemplatesSelectListItems
|
||||
{
|
||||
get
|
||||
{
|
||||
var list = new List<SelectListItem>();
|
||||
list.Add(new SelectListItem() { Selected = true, Value = string.Empty, Text = "Generate Document" });
|
||||
list.AddRange(this.AvailableDocumentTemplates.ToSelectListItems());
|
||||
return list;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -31,5 +31,5 @@ using System.Runtime.InteropServices;
|
||||
//
|
||||
// You can specify all the values or you can default the Revision and Build Numbers
|
||||
// by using the '*' as shown below:
|
||||
[assembly: AssemblyVersion("1.2.0219.1854")]
|
||||
[assembly: AssemblyFileVersion("1.2.0219.1854")]
|
||||
[assembly: AssemblyVersion("1.2.0221.1820")]
|
||||
[assembly: AssemblyFileVersion("1.2.0221.1820")]
|
||||
|
||||
@@ -1,56 +1,56 @@
|
||||
@model Disco.Web.Models.Job.ShowModel
|
||||
@{
|
||||
ViewBag.Title = Html.ToBreadcrumb("Jobs", MVC.Job.Index(), string.Format("Job: {0}", Model.Job.Id.ToString()));
|
||||
Html.BundleDeferred("~/ClientScripts/Modules/Silverlight");
|
||||
Html.BundleDeferred("~/ClientScripts/Modules/jQueryUI-TimePicker");
|
||||
}
|
||||
<div id="Job_Show">
|
||||
<div id="Job_Show_Status">
|
||||
@{ var jobStatusInfo = Model.Job.Status();}
|
||||
<span class="icon JobStatus@(jobStatusInfo.Item1)"></span>@jobStatusInfo.Item2
|
||||
<script type="text/javascript">
|
||||
$(function () {
|
||||
$('#Job_Show_Status').appendTo('#layout_PageHeading')
|
||||
});
|
||||
</script>
|
||||
</div>
|
||||
@Html.Partial(MVC.Job.Views.JobParts._Subject, Model)
|
||||
<script type="text/javascript">
|
||||
$(function () {
|
||||
var $tabs = $('#jobDetailTabs');
|
||||
$tabs.tabs({
|
||||
activate: function (event, ui) {
|
||||
window.setTimeout(function () {
|
||||
var $window = $(window);
|
||||
var tabHeight = $tabs.height();
|
||||
var tabOffset = $tabs.offset();
|
||||
var windowScrollTop = $window.scrollTop();
|
||||
var windowHeight = $window.height();
|
||||
|
||||
var tabTopNotShown = windowScrollTop - tabOffset.top;
|
||||
if (tabTopNotShown > 0) {
|
||||
$('html').animate({ scrollTop: tabOffset.top }, 125);
|
||||
} else {
|
||||
var tabBottomNotShown = ((windowScrollTop + windowHeight) - (tabHeight + tabOffset.top)) * -1;
|
||||
if (tabBottomNotShown > 0) {
|
||||
if (tabHeight > windowHeight)
|
||||
$('html').animate({ scrollTop: tabOffset.top }, 125);
|
||||
else
|
||||
$('html').animate({ scrollTop: windowScrollTop + tabBottomNotShown }, 125);
|
||||
}
|
||||
}
|
||||
}, 1);
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<div id="jobDetailTabs">
|
||||
<ul id="jobDetailTabItems">
|
||||
<li><a href="#jobDetailTab-Resources">Log and Attachments</a></li>
|
||||
</ul>
|
||||
<div id="jobDetailTab-Resources" class="jobPart">
|
||||
@Html.Partial(MVC.Job.Views.JobParts.Resources, Model)
|
||||
</div>
|
||||
@Html.Partial(MVC.Job.Views.JobParts.JobMetaAdditions, Model)
|
||||
</div>
|
||||
</div>
|
||||
@model Disco.Web.Models.Job.ShowModel
|
||||
@{
|
||||
ViewBag.Title = Html.ToBreadcrumb("Jobs", MVC.Job.Index(), string.Format("Job: {0}", Model.Job.Id.ToString()));
|
||||
Html.BundleDeferred("~/ClientScripts/Modules/Silverlight");
|
||||
Html.BundleDeferred("~/ClientScripts/Modules/jQueryUI-TimePicker");
|
||||
}
|
||||
<div id="Job_Show">
|
||||
<div id="Job_Show_Status">
|
||||
@{ var jobStatusInfo = Model.Job.Status();}
|
||||
<span class="icon JobStatus@(jobStatusInfo.Item1)"></span>@jobStatusInfo.Item2
|
||||
<script type="text/javascript">
|
||||
$(function () {
|
||||
$('#Job_Show_Status').appendTo('#layout_PageHeading')
|
||||
});
|
||||
</script>
|
||||
</div>
|
||||
@Html.Partial(MVC.Job.Views.JobParts._Subject, Model)
|
||||
<script type="text/javascript">
|
||||
$(function () {
|
||||
var $tabs = $('#jobDetailTabs');
|
||||
$tabs.tabs({
|
||||
activate: function (event, ui) {
|
||||
window.setTimeout(function () {
|
||||
var $window = $(window);
|
||||
var tabHeight = $tabs.height();
|
||||
var tabOffset = $tabs.offset();
|
||||
var windowScrollTop = $window.scrollTop();
|
||||
var windowHeight = $window.height();
|
||||
|
||||
var tabTopNotShown = windowScrollTop - tabOffset.top;
|
||||
if (tabTopNotShown > 0) {
|
||||
$('html').animate({ scrollTop: tabOffset.top }, 125);
|
||||
} else {
|
||||
var tabBottomNotShown = ((windowScrollTop + windowHeight) - (tabHeight + tabOffset.top)) * -1;
|
||||
if (tabBottomNotShown > 0) {
|
||||
if (tabHeight > windowHeight)
|
||||
$('html').animate({ scrollTop: tabOffset.top }, 125);
|
||||
else
|
||||
$('html').animate({ scrollTop: windowScrollTop + tabBottomNotShown }, 125);
|
||||
}
|
||||
}
|
||||
}, 1);
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<div id="jobDetailTabs">
|
||||
<ul id="jobDetailTabItems">
|
||||
<li><a href="#jobDetailTab-Resources">Log and Attachments</a></li>
|
||||
</ul>
|
||||
<div id="jobDetailTab-Resources" class="jobPart">
|
||||
@Html.Partial(MVC.Job.Views.JobParts.Resources, Model)
|
||||
</div>
|
||||
@Html.Partial(MVC.Job.Views.JobParts.JobMetaAdditions, Model)
|
||||
</div>
|
||||
</div>
|
||||
@@ -1,192 +1,192 @@
|
||||
#pragma warning disable 1591
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.17929
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Disco.Web.Views.Job
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Net;
|
||||
using System.Text;
|
||||
using System.Web;
|
||||
using System.Web.Helpers;
|
||||
using System.Web.Mvc;
|
||||
using System.Web.Mvc.Ajax;
|
||||
using System.Web.Mvc.Html;
|
||||
using System.Web.Routing;
|
||||
using System.Web.Security;
|
||||
using System.Web.UI;
|
||||
using System.Web.WebPages;
|
||||
using Disco.BI.Extensions;
|
||||
using Disco.Models.Repository;
|
||||
using Disco.Web;
|
||||
using Disco.Web.Extensions;
|
||||
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("RazorGenerator", "1.5.0.0")]
|
||||
[System.Web.WebPages.PageVirtualPathAttribute("~/Views/Job/Show.cshtml")]
|
||||
public class Show : System.Web.Mvc.WebViewPage<Disco.Web.Models.Job.ShowModel>
|
||||
{
|
||||
public Show()
|
||||
{
|
||||
}
|
||||
public override void Execute()
|
||||
{
|
||||
|
||||
#line 2 "..\..\Views\Job\Show.cshtml"
|
||||
|
||||
ViewBag.Title = Html.ToBreadcrumb("Jobs", MVC.Job.Index(), string.Format("Job: {0}", Model.Job.Id.ToString()));
|
||||
Html.BundleDeferred("~/ClientScripts/Modules/Silverlight");
|
||||
Html.BundleDeferred("~/ClientScripts/Modules/jQueryUI-TimePicker");
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n<div");
|
||||
|
||||
WriteLiteral(" id=\"Job_Show\"");
|
||||
|
||||
WriteLiteral(">\r\n <div");
|
||||
|
||||
WriteLiteral(" id=\"Job_Show_Status\"");
|
||||
|
||||
WriteLiteral(">\r\n");
|
||||
|
||||
|
||||
#line 9 "..\..\Views\Job\Show.cshtml"
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 9 "..\..\Views\Job\Show.cshtml"
|
||||
var jobStatusInfo = Model.Job.Status();
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n <span");
|
||||
|
||||
WriteAttribute("class", Tuple.Create(" class=\"", 420), Tuple.Create("\"", 464)
|
||||
, Tuple.Create(Tuple.Create("", 428), Tuple.Create("icon", 428), true)
|
||||
, Tuple.Create(Tuple.Create(" ", 432), Tuple.Create("JobStatus", 433), true)
|
||||
|
||||
#line 10 "..\..\Views\Job\Show.cshtml"
|
||||
, Tuple.Create(Tuple.Create("", 442), Tuple.Create<System.Object, System.Int32>(jobStatusInfo.Item1
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
, 442), false)
|
||||
);
|
||||
|
||||
WriteLiteral("></span>");
|
||||
|
||||
|
||||
#line 10 "..\..\Views\Job\Show.cshtml"
|
||||
Write(jobStatusInfo.Item2);
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n <script");
|
||||
|
||||
WriteLiteral(" type=\"text/javascript\"");
|
||||
|
||||
WriteLiteral(">\r\n $(function () {\r\n $(\'#Job_Show_Status\').appendTo(\'#" +
|
||||
"layout_PageHeading\')\r\n });\r\n </script>\r\n </div>\r\n");
|
||||
|
||||
WriteLiteral(" ");
|
||||
|
||||
|
||||
#line 17 "..\..\Views\Job\Show.cshtml"
|
||||
Write(Html.Partial(MVC.Job.Views.JobParts._Subject, Model));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n <script");
|
||||
|
||||
WriteLiteral(" type=\"text/javascript\"");
|
||||
|
||||
WriteLiteral(@">
|
||||
$(function () {
|
||||
var $tabs = $('#jobDetailTabs');
|
||||
$tabs.tabs({
|
||||
activate: function (event, ui) {
|
||||
window.setTimeout(function () {
|
||||
var $window = $(window);
|
||||
var tabHeight = $tabs.height();
|
||||
var tabOffset = $tabs.offset();
|
||||
var windowScrollTop = $window.scrollTop();
|
||||
var windowHeight = $window.height();
|
||||
|
||||
var tabTopNotShown = windowScrollTop - tabOffset.top;
|
||||
if (tabTopNotShown > 0) {
|
||||
$('html').animate({ scrollTop: tabOffset.top }, 125);
|
||||
} else {
|
||||
var tabBottomNotShown = ((windowScrollTop + windowHeight) - (tabHeight + tabOffset.top)) * -1;
|
||||
if (tabBottomNotShown > 0) {
|
||||
if (tabHeight > windowHeight)
|
||||
$('html').animate({ scrollTop: tabOffset.top }, 125);
|
||||
else
|
||||
$('html').animate({ scrollTop: windowScrollTop + tabBottomNotShown }, 125);
|
||||
}
|
||||
}
|
||||
}, 1);
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<div");
|
||||
|
||||
WriteLiteral(" id=\"jobDetailTabs\"");
|
||||
|
||||
WriteLiteral(">\r\n <ul");
|
||||
|
||||
WriteLiteral(" id=\"jobDetailTabItems\"");
|
||||
|
||||
WriteLiteral(">\r\n <li><a");
|
||||
|
||||
WriteLiteral(" href=\"#jobDetailTab-Resources\"");
|
||||
|
||||
WriteLiteral(">Log and Attachments</a></li>\r\n </ul>\r\n <div");
|
||||
|
||||
WriteLiteral(" id=\"jobDetailTab-Resources\"");
|
||||
|
||||
WriteLiteral(" class=\"jobPart\"");
|
||||
|
||||
WriteLiteral(">\r\n");
|
||||
|
||||
WriteLiteral(" ");
|
||||
|
||||
|
||||
#line 52 "..\..\Views\Job\Show.cshtml"
|
||||
Write(Html.Partial(MVC.Job.Views.JobParts.Resources, Model));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n </div>\r\n");
|
||||
|
||||
WriteLiteral(" ");
|
||||
|
||||
|
||||
#line 54 "..\..\Views\Job\Show.cshtml"
|
||||
Write(Html.Partial(MVC.Job.Views.JobParts.JobMetaAdditions, Model));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n </div>\r\n</div>\r\n");
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
#pragma warning restore 1591
|
||||
#pragma warning disable 1591
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.17929
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Disco.Web.Views.Job
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Net;
|
||||
using System.Text;
|
||||
using System.Web;
|
||||
using System.Web.Helpers;
|
||||
using System.Web.Mvc;
|
||||
using System.Web.Mvc.Ajax;
|
||||
using System.Web.Mvc.Html;
|
||||
using System.Web.Routing;
|
||||
using System.Web.Security;
|
||||
using System.Web.UI;
|
||||
using System.Web.WebPages;
|
||||
using Disco.BI.Extensions;
|
||||
using Disco.Models.Repository;
|
||||
using Disco.Web;
|
||||
using Disco.Web.Extensions;
|
||||
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("RazorGenerator", "1.5.0.0")]
|
||||
[System.Web.WebPages.PageVirtualPathAttribute("~/Views/Job/Show.cshtml")]
|
||||
public class Show : System.Web.Mvc.WebViewPage<Disco.Web.Models.Job.ShowModel>
|
||||
{
|
||||
public Show()
|
||||
{
|
||||
}
|
||||
public override void Execute()
|
||||
{
|
||||
|
||||
#line 2 "..\..\Views\Job\Show.cshtml"
|
||||
|
||||
ViewBag.Title = Html.ToBreadcrumb("Jobs", MVC.Job.Index(), string.Format("Job: {0}", Model.Job.Id.ToString()));
|
||||
Html.BundleDeferred("~/ClientScripts/Modules/Silverlight");
|
||||
Html.BundleDeferred("~/ClientScripts/Modules/jQueryUI-TimePicker");
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n<div");
|
||||
|
||||
WriteLiteral(" id=\"Job_Show\"");
|
||||
|
||||
WriteLiteral(">\r\n <div");
|
||||
|
||||
WriteLiteral(" id=\"Job_Show_Status\"");
|
||||
|
||||
WriteLiteral(">\r\n");
|
||||
|
||||
|
||||
#line 9 "..\..\Views\Job\Show.cshtml"
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 9 "..\..\Views\Job\Show.cshtml"
|
||||
var jobStatusInfo = Model.Job.Status();
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n <span");
|
||||
|
||||
WriteAttribute("class", Tuple.Create(" class=\"", 420), Tuple.Create("\"", 464)
|
||||
, Tuple.Create(Tuple.Create("", 428), Tuple.Create("icon", 428), true)
|
||||
, Tuple.Create(Tuple.Create(" ", 432), Tuple.Create("JobStatus", 433), true)
|
||||
|
||||
#line 10 "..\..\Views\Job\Show.cshtml"
|
||||
, Tuple.Create(Tuple.Create("", 442), Tuple.Create<System.Object, System.Int32>(jobStatusInfo.Item1
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
, 442), false)
|
||||
);
|
||||
|
||||
WriteLiteral("></span>");
|
||||
|
||||
|
||||
#line 10 "..\..\Views\Job\Show.cshtml"
|
||||
Write(jobStatusInfo.Item2);
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n <script");
|
||||
|
||||
WriteLiteral(" type=\"text/javascript\"");
|
||||
|
||||
WriteLiteral(">\r\n $(function () {\r\n $(\'#Job_Show_Status\').appendTo(\'#" +
|
||||
"layout_PageHeading\')\r\n });\r\n </script>\r\n </div>\r\n");
|
||||
|
||||
WriteLiteral(" ");
|
||||
|
||||
|
||||
#line 17 "..\..\Views\Job\Show.cshtml"
|
||||
Write(Html.Partial(MVC.Job.Views.JobParts._Subject, Model));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n <script");
|
||||
|
||||
WriteLiteral(" type=\"text/javascript\"");
|
||||
|
||||
WriteLiteral(@">
|
||||
$(function () {
|
||||
var $tabs = $('#jobDetailTabs');
|
||||
$tabs.tabs({
|
||||
activate: function (event, ui) {
|
||||
window.setTimeout(function () {
|
||||
var $window = $(window);
|
||||
var tabHeight = $tabs.height();
|
||||
var tabOffset = $tabs.offset();
|
||||
var windowScrollTop = $window.scrollTop();
|
||||
var windowHeight = $window.height();
|
||||
|
||||
var tabTopNotShown = windowScrollTop - tabOffset.top;
|
||||
if (tabTopNotShown > 0) {
|
||||
$('html').animate({ scrollTop: tabOffset.top }, 125);
|
||||
} else {
|
||||
var tabBottomNotShown = ((windowScrollTop + windowHeight) - (tabHeight + tabOffset.top)) * -1;
|
||||
if (tabBottomNotShown > 0) {
|
||||
if (tabHeight > windowHeight)
|
||||
$('html').animate({ scrollTop: tabOffset.top }, 125);
|
||||
else
|
||||
$('html').animate({ scrollTop: windowScrollTop + tabBottomNotShown }, 125);
|
||||
}
|
||||
}
|
||||
}, 1);
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<div");
|
||||
|
||||
WriteLiteral(" id=\"jobDetailTabs\"");
|
||||
|
||||
WriteLiteral(">\r\n <ul");
|
||||
|
||||
WriteLiteral(" id=\"jobDetailTabItems\"");
|
||||
|
||||
WriteLiteral(">\r\n <li><a");
|
||||
|
||||
WriteLiteral(" href=\"#jobDetailTab-Resources\"");
|
||||
|
||||
WriteLiteral(">Log and Attachments</a></li>\r\n </ul>\r\n <div");
|
||||
|
||||
WriteLiteral(" id=\"jobDetailTab-Resources\"");
|
||||
|
||||
WriteLiteral(" class=\"jobPart\"");
|
||||
|
||||
WriteLiteral(">\r\n");
|
||||
|
||||
WriteLiteral(" ");
|
||||
|
||||
|
||||
#line 52 "..\..\Views\Job\Show.cshtml"
|
||||
Write(Html.Partial(MVC.Job.Views.JobParts.Resources, Model));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n </div>\r\n");
|
||||
|
||||
WriteLiteral(" ");
|
||||
|
||||
|
||||
#line 54 "..\..\Views\Job\Show.cshtml"
|
||||
Write(Html.Partial(MVC.Job.Views.JobParts.JobMetaAdditions, Model));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n </div>\r\n</div>");
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
#pragma warning restore 1591
|
||||
|
||||
@@ -1,108 +1,109 @@
|
||||
@{
|
||||
Html.BundleDeferred("~/Style/Site");
|
||||
Html.BundleDeferred("~/ClientScripts/Core");
|
||||
}
|
||||
<!doctype html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Disco - @CommonHelpers.BreadcrumbsTitle(ViewBag.Title)</title>
|
||||
<link rel="shortcut icon" href="/favicon.ico" />
|
||||
<meta name="application-name" content="Disco" />
|
||||
<meta name="msapplication-starturl" content="/" />
|
||||
<meta name="msapplication-tooltip" content="Open Disco" />
|
||||
@Html.BundleRenderDeferred()
|
||||
@RenderSection("head", false)
|
||||
</head>
|
||||
<body class="layout">
|
||||
<div class="page">
|
||||
<header>
|
||||
<div class="clearfix">
|
||||
<div id="heading">
|
||||
<a href="@Url.Action(MVC.Job.Index())">
|
||||
<img src="@Links.ClientSource.Style.Images.Heading_png" alt="DISCO - ICT Asset Management" /></a>
|
||||
</div>
|
||||
<div id="headerMenu">
|
||||
<span>Welcome @Html.ActionLink(DiscoApplication.CurrentUser.ToString(), MVC.User.Show(DiscoApplication.CurrentUser.Id))</span>
|
||||
@using (Html.BeginForm(MVC.Search.Query(), FormMethod.Get))
|
||||
{
|
||||
|
||||
@Html.TextBox("term", null, new { accesskey = "s" })
|
||||
<script type="text/javascript">
|
||||
//<!--
|
||||
$(function () {
|
||||
$('#term').watermark('Search').keypress(function (e) {
|
||||
if (e.keyCode == 13) {
|
||||
$(this).closest('form').submit();
|
||||
}
|
||||
}).focus(function () {
|
||||
$(this).select();
|
||||
});
|
||||
});
|
||||
//-->
|
||||
</script>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<nav>
|
||||
<ul id="menu">
|
||||
<li>@Html.ActionLink("Jobs", MVC.Job.Index(), accesskey: "1")
|
||||
<ul>
|
||||
<li>@Html.ActionLink("Devices Ready for Return", MVC.Job.DevicesReadyForReturn())</li>
|
||||
<li>@Html.ActionLink("Device Held Locations", MVC.Job.Locations())</li>
|
||||
<li>@Html.ActionLink("Awaiting User Action", MVC.Job.AwaitingUserAction())</li>
|
||||
<li>@Html.ActionLink("Awaiting Finance", MVC.Job.AwaitingFinance())
|
||||
<ul>
|
||||
<li>@Html.ActionLink("Accounting Charge", MVC.Job.AwaitingFinanceCharge())</li>
|
||||
<li>@Html.ActionLink("Accounting Payment", MVC.Job.AwaitingFinancePayment())</li>
|
||||
<li>@Html.ActionLink("Agreement Breach", MVC.Job.AwaitingFinanceAgreementBreach())</li>
|
||||
<li>@Html.ActionLink("Insurance Processing", MVC.Job.AwaitingFinanceInsuranceProcessing())</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>@Html.ActionLink("Awaiting Device Repair", MVC.Job.DevicesAwaitingRepair())</li>
|
||||
<li>@Html.ActionLink("All Open", MVC.Job.AllOpen())</li>
|
||||
<li>@Html.ActionLink("Recently Closed", MVC.Job.RecentlyClosed())</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="sep"></li>
|
||||
<li>@Html.ActionLink("Devices", MVC.Device.Index(), accesskey: "2")</li>
|
||||
<li class="sep"></li>
|
||||
<li>@Html.ActionLink("Users", MVC.User.Index(), accesskey: "3")</li>
|
||||
<li class="moveRight">@Html.ActionLink("Public Reports", MVC.Public.Public.Index())</li>
|
||||
<li class="sep"></li>
|
||||
<li>@Html.ActionLink("Configuration", MVC.Config.Config.Index(), accesskey: "0")</li>
|
||||
</ul>
|
||||
<script type="text/javascript">
|
||||
$(function () {
|
||||
var $menu = $('#menu');
|
||||
$menu.find('li').each(function () {
|
||||
var $menuItem = $(this);
|
||||
var $subMenu = $menuItem.children('ul').first();
|
||||
var subMenuHideToken = null;
|
||||
if ($subMenu.length > 0) {
|
||||
$menuItem.mouseover(function () {
|
||||
if (subMenuHideToken)
|
||||
window.clearTimeout(subMenuHideToken);
|
||||
if (!$subMenu.is(':visible'))
|
||||
$subMenu.show();
|
||||
}).mouseout(function () {
|
||||
subMenuHideToken = window.setTimeout(function () {
|
||||
$subMenu.hide();
|
||||
}, 250);
|
||||
}).addClass('hasSubmenu');
|
||||
};
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</nav>
|
||||
</header>
|
||||
<div id="layout_PageHeading">@CommonHelpers.Breadcrumbs(ViewBag.Title)</div>
|
||||
<section id="layout_Page">
|
||||
@RenderBody()
|
||||
</section>
|
||||
<footer>
|
||||
Disco v@(Disco.Web.DiscoApplication.Version) @@ @(Disco.Web.DiscoApplication.OrganisationName) | <a
|
||||
href="http://discoict.com.au/" target="_blank">discoict.com.au</a> | @Html.ActionLink("Credits", MVC.Public.Public.Credits()) | @Html.ActionLink("Licence", MVC.Public.Public.Licence())
|
||||
</footer>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
@{
|
||||
Html.BundleDeferred("~/Style/Site");
|
||||
Html.BundleDeferred("~/ClientScripts/Core");
|
||||
}
|
||||
<!doctype html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Disco - @CommonHelpers.BreadcrumbsTitle(ViewBag.Title)</title>
|
||||
<link rel="shortcut icon" href="/favicon.ico" />
|
||||
<meta name="application-name" content="Disco" />
|
||||
<meta name="msapplication-starturl" content="/" />
|
||||
<meta name="msapplication-tooltip" content="Open Disco" />
|
||||
@Html.BundleRenderDeferred()
|
||||
@RenderSection("head", false)
|
||||
</head>
|
||||
<body class="layout">
|
||||
<div class="page">
|
||||
<header>
|
||||
<div class="clearfix">
|
||||
<div id="heading">
|
||||
<a href="@Url.Action(MVC.Job.Index())">
|
||||
<img src="@Links.ClientSource.Style.Images.Heading_png" alt="DISCO - ICT Asset Management" /></a>
|
||||
</div>
|
||||
<div id="headerMenu">
|
||||
<span>Welcome @Html.ActionLink(DiscoApplication.CurrentUser.ToString(), MVC.User.Show(DiscoApplication.CurrentUser.Id))</span>
|
||||
@using (Html.BeginForm(MVC.Search.Query(), FormMethod.Get))
|
||||
{
|
||||
|
||||
@Html.TextBox("term", null, new { accesskey = "s" })
|
||||
<script type="text/javascript">
|
||||
//<!--
|
||||
$(function () {
|
||||
$('#term').watermark('Search').keypress(function (e) {
|
||||
if (e.keyCode == 13) {
|
||||
$(this).closest('form').submit();
|
||||
}
|
||||
}).focus(function () {
|
||||
$(this).select();
|
||||
});
|
||||
});
|
||||
//-->
|
||||
</script>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<nav>
|
||||
<ul id="menu">
|
||||
<li>@Html.ActionLink("Jobs", MVC.Job.Index(), accesskey: "1")
|
||||
<ul>
|
||||
<li>@Html.ActionLink("Devices Ready for Return", MVC.Job.DevicesReadyForReturn())</li>
|
||||
<li>@Html.ActionLink("Device Held Locations", MVC.Job.Locations())</li>
|
||||
<li>@Html.ActionLink("Awaiting User Action", MVC.Job.AwaitingUserAction())</li>
|
||||
<li>@Html.ActionLink("Awaiting Finance", MVC.Job.AwaitingFinance())
|
||||
<ul>
|
||||
<li>@Html.ActionLink("Accounting Charge", MVC.Job.AwaitingFinanceCharge())</li>
|
||||
<li>@Html.ActionLink("Accounting Payment", MVC.Job.AwaitingFinancePayment())</li>
|
||||
<li>@Html.ActionLink("Agreement Breach", MVC.Job.AwaitingFinanceAgreementBreach())</li>
|
||||
<li>@Html.ActionLink("Insurance Processing", MVC.Job.AwaitingFinanceInsuranceProcessing())</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>@Html.ActionLink("Awaiting Device Repair", MVC.Job.DevicesAwaitingRepair())</li>
|
||||
<li>@Html.ActionLink("All Open", MVC.Job.AllOpen())</li>
|
||||
<li>@Html.ActionLink("Recently Closed", MVC.Job.RecentlyClosed())</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="sep"></li>
|
||||
<li>@Html.ActionLink("Devices", MVC.Device.Index(), accesskey: "2")</li>
|
||||
<li class="sep"></li>
|
||||
<li>@Html.ActionLink("Users", MVC.User.Index(), accesskey: "3")</li>
|
||||
<li class="moveRight">@Html.ActionLink("Public Reports", MVC.Public.Public.Index())</li>
|
||||
<li class="sep"></li>
|
||||
<li>@Html.ActionLink("Configuration", MVC.Config.Config.Index(), accesskey: "0")</li>
|
||||
</ul>
|
||||
<script type="text/javascript">
|
||||
$(function () {
|
||||
var $menu = $('#menu');
|
||||
$menu.find('li').each(function () {
|
||||
var $menuItem = $(this);
|
||||
var $subMenu = $menuItem.children('ul').first();
|
||||
var subMenuHideToken = null;
|
||||
if ($subMenu.length > 0) {
|
||||
$menuItem.mouseover(function () {
|
||||
if (subMenuHideToken)
|
||||
window.clearTimeout(subMenuHideToken);
|
||||
if (!$subMenu.is(':visible'))
|
||||
$subMenu.show();
|
||||
}).mouseout(function () {
|
||||
subMenuHideToken = window.setTimeout(function () {
|
||||
$subMenu.hide();
|
||||
}, 250);
|
||||
}).addClass('hasSubmenu');
|
||||
};
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</nav>
|
||||
</header>
|
||||
<div id="layout_PageHeading">@CommonHelpers.Breadcrumbs(ViewBag.Title)</div>
|
||||
<section id="layout_Page">
|
||||
@RenderBody()
|
||||
</section>
|
||||
<footer>
|
||||
Disco v@(Disco.Web.DiscoApplication.Version) @@ @(Disco.Web.DiscoApplication.OrganisationName) | <a
|
||||
href="http://discoict.com.au/" target="_blank">discoict.com.au</a> | @Html.ActionLink("Credits", MVC.Public.Public.Credits()) | @Html.ActionLink("Licence", MVC.Public.Public.Licence())
|
||||
</footer>
|
||||
</div>
|
||||
@{ Disco.Services.UIExtensions.UIExtensions.ExecuteExtensionResult(this); }
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -1,486 +1,500 @@
|
||||
#pragma warning disable 1591
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.17929
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Disco.Web.Views.Shared
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Net;
|
||||
using System.Text;
|
||||
using System.Web;
|
||||
using System.Web.Helpers;
|
||||
using System.Web.Mvc;
|
||||
using System.Web.Mvc.Ajax;
|
||||
using System.Web.Mvc.Html;
|
||||
using System.Web.Routing;
|
||||
using System.Web.Security;
|
||||
using System.Web.UI;
|
||||
using System.Web.WebPages;
|
||||
using Disco.BI.Extensions;
|
||||
using Disco.Models.Repository;
|
||||
using Disco.Web;
|
||||
using Disco.Web.Extensions;
|
||||
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("RazorGenerator", "1.5.0.0")]
|
||||
[System.Web.WebPages.PageVirtualPathAttribute("~/Views/Shared/_Layout.cshtml")]
|
||||
public class Layout : System.Web.Mvc.WebViewPage<dynamic>
|
||||
{
|
||||
public Layout()
|
||||
{
|
||||
}
|
||||
public override void Execute()
|
||||
{
|
||||
|
||||
#line 1 "..\..\Views\Shared\_Layout.cshtml"
|
||||
|
||||
Html.BundleDeferred("~/Style/Site");
|
||||
Html.BundleDeferred("~/ClientScripts/Core");
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n<!doctype html>\r\n<html>\r\n<head>\r\n <title>Disco - ");
|
||||
|
||||
|
||||
#line 8 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(CommonHelpers.BreadcrumbsTitle(ViewBag.Title));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</title>\r\n <link");
|
||||
|
||||
WriteLiteral(" rel=\"shortcut icon\"");
|
||||
|
||||
WriteLiteral(" href=\"/favicon.ico\"");
|
||||
|
||||
WriteLiteral(" />\r\n <meta");
|
||||
|
||||
WriteLiteral(" name=\"application-name\"");
|
||||
|
||||
WriteLiteral(" content=\"Disco\"");
|
||||
|
||||
WriteLiteral(" />\r\n <meta");
|
||||
|
||||
WriteLiteral(" name=\"msapplication-starturl\"");
|
||||
|
||||
WriteLiteral(" content=\"/\"");
|
||||
|
||||
WriteLiteral(" />\r\n <meta");
|
||||
|
||||
WriteLiteral(" name=\"msapplication-tooltip\"");
|
||||
|
||||
WriteLiteral(" content=\"Open Disco\"");
|
||||
|
||||
WriteLiteral(" />\r\n");
|
||||
|
||||
WriteLiteral(" ");
|
||||
|
||||
|
||||
#line 13 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.BundleRenderDeferred());
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n");
|
||||
|
||||
WriteLiteral(" ");
|
||||
|
||||
|
||||
#line 14 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(RenderSection("head", false));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n</head>\r\n<body");
|
||||
|
||||
WriteLiteral(" class=\"layout\"");
|
||||
|
||||
WriteLiteral(">\r\n <div");
|
||||
|
||||
WriteLiteral(" class=\"page\"");
|
||||
|
||||
WriteLiteral(">\r\n <header>\r\n <div");
|
||||
|
||||
WriteLiteral(" class=\"clearfix\"");
|
||||
|
||||
WriteLiteral(">\r\n <div");
|
||||
|
||||
WriteLiteral(" id=\"heading\"");
|
||||
|
||||
WriteLiteral(">\r\n <a");
|
||||
|
||||
WriteAttribute("href", Tuple.Create(" href=\"", 672), Tuple.Create("\"", 707)
|
||||
|
||||
#line 21 "..\..\Views\Shared\_Layout.cshtml"
|
||||
, Tuple.Create(Tuple.Create("", 679), Tuple.Create<System.Object, System.Int32>(Url.Action(MVC.Job.Index())
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
, 679), false)
|
||||
);
|
||||
|
||||
WriteLiteral(">\r\n <img");
|
||||
|
||||
WriteAttribute("src", Tuple.Create(" src=\"", 739), Tuple.Create("\"", 789)
|
||||
|
||||
#line 22 "..\..\Views\Shared\_Layout.cshtml"
|
||||
, Tuple.Create(Tuple.Create("", 745), Tuple.Create<System.Object, System.Int32>(Links.ClientSource.Style.Images.Heading_png
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
, 745), false)
|
||||
);
|
||||
|
||||
WriteLiteral(" alt=\"DISCO - ICT Asset Management\"");
|
||||
|
||||
WriteLiteral(" /></a>\r\n </div>\r\n <div");
|
||||
|
||||
WriteLiteral(" id=\"headerMenu\"");
|
||||
|
||||
WriteLiteral(">\r\n <span>Welcome ");
|
||||
|
||||
|
||||
#line 25 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink(DiscoApplication.CurrentUser.ToString(), MVC.User.Show(DiscoApplication.CurrentUser.Id)));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</span>\r\n");
|
||||
|
||||
|
||||
#line 26 "..\..\Views\Shared\_Layout.cshtml"
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 26 "..\..\Views\Shared\_Layout.cshtml"
|
||||
using (Html.BeginForm(MVC.Search.Query(), FormMethod.Get))
|
||||
{
|
||||
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 29 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.TextBox("term", null, new { accesskey = "s" }));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 29 "..\..\Views\Shared\_Layout.cshtml"
|
||||
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral(" <script");
|
||||
|
||||
WriteLiteral(" type=\"text/javascript\"");
|
||||
|
||||
WriteLiteral(@">
|
||||
//<!--
|
||||
$(function () {
|
||||
$('#term').watermark('Search').keypress(function (e) {
|
||||
if (e.keyCode == 13) {
|
||||
$(this).closest('form').submit();
|
||||
}
|
||||
}).focus(function () {
|
||||
$(this).select();
|
||||
});
|
||||
});
|
||||
//-->
|
||||
</script>
|
||||
");
|
||||
|
||||
|
||||
#line 43 "..\..\Views\Shared\_Layout.cshtml"
|
||||
}
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral(" </div>\r\n </div>\r\n <nav>\r\n <u" +
|
||||
"l");
|
||||
|
||||
WriteLiteral(" id=\"menu\"");
|
||||
|
||||
WriteLiteral(">\r\n <li>");
|
||||
|
||||
|
||||
#line 48 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Jobs", MVC.Job.Index(), accesskey: "1"));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n <ul>\r\n <li>");
|
||||
|
||||
|
||||
#line 50 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Devices Ready for Return", MVC.Job.DevicesReadyForReturn()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 51 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Device Held Locations", MVC.Job.Locations()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 52 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Awaiting User Action", MVC.Job.AwaitingUserAction()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 53 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Awaiting Finance", MVC.Job.AwaitingFinance()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n <ul>\r\n <li>");
|
||||
|
||||
|
||||
#line 55 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Accounting Charge", MVC.Job.AwaitingFinanceCharge()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 56 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Accounting Payment", MVC.Job.AwaitingFinancePayment()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 57 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Agreement Breach", MVC.Job.AwaitingFinanceAgreementBreach()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 58 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Insurance Processing", MVC.Job.AwaitingFinanceInsuranceProcessing()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n </ul>\r\n </li>\r\n" +
|
||||
" <li>");
|
||||
|
||||
|
||||
#line 61 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Awaiting Device Repair", MVC.Job.DevicesAwaitingRepair()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 62 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("All Open", MVC.Job.AllOpen()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 63 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Recently Closed", MVC.Job.RecentlyClosed()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n </ul>\r\n </li>\r\n " +
|
||||
" <li");
|
||||
|
||||
WriteLiteral(" class=\"sep\"");
|
||||
|
||||
WriteLiteral("></li>\r\n <li>");
|
||||
|
||||
|
||||
#line 67 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Devices", MVC.Device.Index(), accesskey: "2"));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li");
|
||||
|
||||
WriteLiteral(" class=\"sep\"");
|
||||
|
||||
WriteLiteral("></li>\r\n <li>");
|
||||
|
||||
|
||||
#line 69 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Users", MVC.User.Index(), accesskey: "3"));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li");
|
||||
|
||||
WriteLiteral(" class=\"moveRight\"");
|
||||
|
||||
WriteLiteral(">");
|
||||
|
||||
|
||||
#line 70 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Public Reports", MVC.Public.Public.Index()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li");
|
||||
|
||||
WriteLiteral(" class=\"sep\"");
|
||||
|
||||
WriteLiteral("></li>\r\n <li>");
|
||||
|
||||
|
||||
#line 72 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Configuration", MVC.Config.Config.Index(), accesskey: "0"));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n </ul>\r\n <script");
|
||||
|
||||
WriteLiteral(" type=\"text/javascript\"");
|
||||
|
||||
WriteLiteral(@">
|
||||
$(function () {
|
||||
var $menu = $('#menu');
|
||||
$menu.find('li').each(function () {
|
||||
var $menuItem = $(this);
|
||||
var $subMenu = $menuItem.children('ul').first();
|
||||
var subMenuHideToken = null;
|
||||
if ($subMenu.length > 0) {
|
||||
$menuItem.mouseover(function () {
|
||||
if (subMenuHideToken)
|
||||
window.clearTimeout(subMenuHideToken);
|
||||
if (!$subMenu.is(':visible'))
|
||||
$subMenu.show();
|
||||
}).mouseout(function () {
|
||||
subMenuHideToken = window.setTimeout(function () {
|
||||
$subMenu.hide();
|
||||
}, 250);
|
||||
}).addClass('hasSubmenu');
|
||||
};
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</nav>
|
||||
</header>
|
||||
<div");
|
||||
|
||||
WriteLiteral(" id=\"layout_PageHeading\"");
|
||||
|
||||
WriteLiteral(">");
|
||||
|
||||
|
||||
#line 98 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(CommonHelpers.Breadcrumbs(ViewBag.Title));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</div>\r\n <section");
|
||||
|
||||
WriteLiteral(" id=\"layout_Page\"");
|
||||
|
||||
WriteLiteral(">\r\n");
|
||||
|
||||
WriteLiteral(" ");
|
||||
|
||||
|
||||
#line 100 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(RenderBody());
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n </section>\r\n <footer>\r\n Disco v");
|
||||
|
||||
|
||||
#line 103 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Disco.Web.DiscoApplication.Version);
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral(" ");
|
||||
|
||||
WriteLiteral("@ ");
|
||||
|
||||
|
||||
#line 103 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Disco.Web.DiscoApplication.OrganisationName);
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral(" | <a\r\n href=\"http://discoict.com.au/\" target=\"_blank\">discoict.co" +
|
||||
"m.au</a> | ");
|
||||
|
||||
|
||||
#line 104 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Credits", MVC.Public.Public.Credits()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral(" | ");
|
||||
|
||||
|
||||
#line 104 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Licence", MVC.Public.Public.Licence()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n </footer>\r\n </div>\r\n</body>\r\n</html>\r\n");
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
#pragma warning restore 1591
|
||||
#pragma warning disable 1591
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
// Runtime Version:4.0.30319.17929
|
||||
//
|
||||
// Changes to this file may cause incorrect behavior and will be lost if
|
||||
// the code is regenerated.
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace Disco.Web.Views.Shared
|
||||
{
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Net;
|
||||
using System.Text;
|
||||
using System.Web;
|
||||
using System.Web.Helpers;
|
||||
using System.Web.Mvc;
|
||||
using System.Web.Mvc.Ajax;
|
||||
using System.Web.Mvc.Html;
|
||||
using System.Web.Routing;
|
||||
using System.Web.Security;
|
||||
using System.Web.UI;
|
||||
using System.Web.WebPages;
|
||||
using Disco.BI.Extensions;
|
||||
using Disco.Models.Repository;
|
||||
using Disco.Web;
|
||||
using Disco.Web.Extensions;
|
||||
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("RazorGenerator", "1.5.0.0")]
|
||||
[System.Web.WebPages.PageVirtualPathAttribute("~/Views/Shared/_Layout.cshtml")]
|
||||
public class Layout : System.Web.Mvc.WebViewPage<dynamic>
|
||||
{
|
||||
public Layout()
|
||||
{
|
||||
}
|
||||
public override void Execute()
|
||||
{
|
||||
|
||||
#line 1 "..\..\Views\Shared\_Layout.cshtml"
|
||||
|
||||
Html.BundleDeferred("~/Style/Site");
|
||||
Html.BundleDeferred("~/ClientScripts/Core");
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n<!doctype html>\r\n<html>\r\n<head>\r\n <title>Disco - ");
|
||||
|
||||
|
||||
#line 8 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(CommonHelpers.BreadcrumbsTitle(ViewBag.Title));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</title>\r\n <link");
|
||||
|
||||
WriteLiteral(" rel=\"shortcut icon\"");
|
||||
|
||||
WriteLiteral(" href=\"/favicon.ico\"");
|
||||
|
||||
WriteLiteral(" />\r\n <meta");
|
||||
|
||||
WriteLiteral(" name=\"application-name\"");
|
||||
|
||||
WriteLiteral(" content=\"Disco\"");
|
||||
|
||||
WriteLiteral(" />\r\n <meta");
|
||||
|
||||
WriteLiteral(" name=\"msapplication-starturl\"");
|
||||
|
||||
WriteLiteral(" content=\"/\"");
|
||||
|
||||
WriteLiteral(" />\r\n <meta");
|
||||
|
||||
WriteLiteral(" name=\"msapplication-tooltip\"");
|
||||
|
||||
WriteLiteral(" content=\"Open Disco\"");
|
||||
|
||||
WriteLiteral(" />\r\n");
|
||||
|
||||
WriteLiteral(" ");
|
||||
|
||||
|
||||
#line 13 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.BundleRenderDeferred());
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n");
|
||||
|
||||
WriteLiteral(" ");
|
||||
|
||||
|
||||
#line 14 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(RenderSection("head", false));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n</head>\r\n<body");
|
||||
|
||||
WriteLiteral(" class=\"layout\"");
|
||||
|
||||
WriteLiteral(">\r\n <div");
|
||||
|
||||
WriteLiteral(" class=\"page\"");
|
||||
|
||||
WriteLiteral(">\r\n <header>\r\n <div");
|
||||
|
||||
WriteLiteral(" class=\"clearfix\"");
|
||||
|
||||
WriteLiteral(">\r\n <div");
|
||||
|
||||
WriteLiteral(" id=\"heading\"");
|
||||
|
||||
WriteLiteral(">\r\n <a");
|
||||
|
||||
WriteAttribute("href", Tuple.Create(" href=\"", 672), Tuple.Create("\"", 707)
|
||||
|
||||
#line 21 "..\..\Views\Shared\_Layout.cshtml"
|
||||
, Tuple.Create(Tuple.Create("", 679), Tuple.Create<System.Object, System.Int32>(Url.Action(MVC.Job.Index())
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
, 679), false)
|
||||
);
|
||||
|
||||
WriteLiteral(">\r\n <img");
|
||||
|
||||
WriteAttribute("src", Tuple.Create(" src=\"", 739), Tuple.Create("\"", 789)
|
||||
|
||||
#line 22 "..\..\Views\Shared\_Layout.cshtml"
|
||||
, Tuple.Create(Tuple.Create("", 745), Tuple.Create<System.Object, System.Int32>(Links.ClientSource.Style.Images.Heading_png
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
, 745), false)
|
||||
);
|
||||
|
||||
WriteLiteral(" alt=\"DISCO - ICT Asset Management\"");
|
||||
|
||||
WriteLiteral(" /></a>\r\n </div>\r\n <div");
|
||||
|
||||
WriteLiteral(" id=\"headerMenu\"");
|
||||
|
||||
WriteLiteral(">\r\n <span>Welcome ");
|
||||
|
||||
|
||||
#line 25 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink(DiscoApplication.CurrentUser.ToString(), MVC.User.Show(DiscoApplication.CurrentUser.Id)));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</span>\r\n");
|
||||
|
||||
|
||||
#line 26 "..\..\Views\Shared\_Layout.cshtml"
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 26 "..\..\Views\Shared\_Layout.cshtml"
|
||||
using (Html.BeginForm(MVC.Search.Query(), FormMethod.Get))
|
||||
{
|
||||
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 29 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.TextBox("term", null, new { accesskey = "s" }));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 29 "..\..\Views\Shared\_Layout.cshtml"
|
||||
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral(" <script");
|
||||
|
||||
WriteLiteral(" type=\"text/javascript\"");
|
||||
|
||||
WriteLiteral(@">
|
||||
//<!--
|
||||
$(function () {
|
||||
$('#term').watermark('Search').keypress(function (e) {
|
||||
if (e.keyCode == 13) {
|
||||
$(this).closest('form').submit();
|
||||
}
|
||||
}).focus(function () {
|
||||
$(this).select();
|
||||
});
|
||||
});
|
||||
//-->
|
||||
</script>
|
||||
");
|
||||
|
||||
|
||||
#line 43 "..\..\Views\Shared\_Layout.cshtml"
|
||||
}
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral(" </div>\r\n </div>\r\n <nav>\r\n <u" +
|
||||
"l");
|
||||
|
||||
WriteLiteral(" id=\"menu\"");
|
||||
|
||||
WriteLiteral(">\r\n <li>");
|
||||
|
||||
|
||||
#line 48 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Jobs", MVC.Job.Index(), accesskey: "1"));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n <ul>\r\n <li>");
|
||||
|
||||
|
||||
#line 50 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Devices Ready for Return", MVC.Job.DevicesReadyForReturn()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 51 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Device Held Locations", MVC.Job.Locations()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 52 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Awaiting User Action", MVC.Job.AwaitingUserAction()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 53 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Awaiting Finance", MVC.Job.AwaitingFinance()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n <ul>\r\n <li>");
|
||||
|
||||
|
||||
#line 55 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Accounting Charge", MVC.Job.AwaitingFinanceCharge()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 56 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Accounting Payment", MVC.Job.AwaitingFinancePayment()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 57 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Agreement Breach", MVC.Job.AwaitingFinanceAgreementBreach()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 58 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Insurance Processing", MVC.Job.AwaitingFinanceInsuranceProcessing()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n </ul>\r\n </li>\r\n" +
|
||||
" <li>");
|
||||
|
||||
|
||||
#line 61 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Awaiting Device Repair", MVC.Job.DevicesAwaitingRepair()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 62 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("All Open", MVC.Job.AllOpen()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li>");
|
||||
|
||||
|
||||
#line 63 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Recently Closed", MVC.Job.RecentlyClosed()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n </ul>\r\n </li>\r\n " +
|
||||
" <li");
|
||||
|
||||
WriteLiteral(" class=\"sep\"");
|
||||
|
||||
WriteLiteral("></li>\r\n <li>");
|
||||
|
||||
|
||||
#line 67 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Devices", MVC.Device.Index(), accesskey: "2"));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li");
|
||||
|
||||
WriteLiteral(" class=\"sep\"");
|
||||
|
||||
WriteLiteral("></li>\r\n <li>");
|
||||
|
||||
|
||||
#line 69 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Users", MVC.User.Index(), accesskey: "3"));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li");
|
||||
|
||||
WriteLiteral(" class=\"moveRight\"");
|
||||
|
||||
WriteLiteral(">");
|
||||
|
||||
|
||||
#line 70 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Public Reports", MVC.Public.Public.Index()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n <li");
|
||||
|
||||
WriteLiteral(" class=\"sep\"");
|
||||
|
||||
WriteLiteral("></li>\r\n <li>");
|
||||
|
||||
|
||||
#line 72 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Configuration", MVC.Config.Config.Index(), accesskey: "0"));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</li>\r\n </ul>\r\n <script");
|
||||
|
||||
WriteLiteral(" type=\"text/javascript\"");
|
||||
|
||||
WriteLiteral(@">
|
||||
$(function () {
|
||||
var $menu = $('#menu');
|
||||
$menu.find('li').each(function () {
|
||||
var $menuItem = $(this);
|
||||
var $subMenu = $menuItem.children('ul').first();
|
||||
var subMenuHideToken = null;
|
||||
if ($subMenu.length > 0) {
|
||||
$menuItem.mouseover(function () {
|
||||
if (subMenuHideToken)
|
||||
window.clearTimeout(subMenuHideToken);
|
||||
if (!$subMenu.is(':visible'))
|
||||
$subMenu.show();
|
||||
}).mouseout(function () {
|
||||
subMenuHideToken = window.setTimeout(function () {
|
||||
$subMenu.hide();
|
||||
}, 250);
|
||||
}).addClass('hasSubmenu');
|
||||
};
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</nav>
|
||||
</header>
|
||||
<div");
|
||||
|
||||
WriteLiteral(" id=\"layout_PageHeading\"");
|
||||
|
||||
WriteLiteral(">");
|
||||
|
||||
|
||||
#line 98 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(CommonHelpers.Breadcrumbs(ViewBag.Title));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("</div>\r\n <section");
|
||||
|
||||
WriteLiteral(" id=\"layout_Page\"");
|
||||
|
||||
WriteLiteral(">\r\n");
|
||||
|
||||
WriteLiteral(" ");
|
||||
|
||||
|
||||
#line 100 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(RenderBody());
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n </section>\r\n <footer>\r\n Disco v");
|
||||
|
||||
|
||||
#line 103 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Disco.Web.DiscoApplication.Version);
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral(" ");
|
||||
|
||||
WriteLiteral("@ ");
|
||||
|
||||
|
||||
#line 103 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Disco.Web.DiscoApplication.OrganisationName);
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral(" | <a\r\n href=\"http://discoict.com.au/\" target=\"_blank\">discoict.co" +
|
||||
"m.au</a> | ");
|
||||
|
||||
|
||||
#line 104 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Credits", MVC.Public.Public.Credits()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral(" | ");
|
||||
|
||||
|
||||
#line 104 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Write(Html.ActionLink("Licence", MVC.Public.Public.Licence()));
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n </footer>\r\n </div>\r\n");
|
||||
|
||||
|
||||
#line 107 "..\..\Views\Shared\_Layout.cshtml"
|
||||
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 107 "..\..\Views\Shared\_Layout.cshtml"
|
||||
Disco.Services.UIExtensions.UIExtensions.ExecuteExtensionResult(this);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
WriteLiteral("\r\n</body>\r\n</html>\r\n");
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
#pragma warning restore 1591
|
||||
|
||||
Reference in New Issue
Block a user