Hide Document Templates & UI Tweaks
Flag Document Templates as hidden. UI changes aim to improve visibility of used features in lists.
This commit is contained in:
@@ -25,7 +25,8 @@ namespace Disco.Web.Areas.Config.Models.DeviceBatch
|
||||
DefaultDeviceModel = db.DefaultDeviceModel.Description,
|
||||
WarrantyExpires = db.WarrantyValidUntil,
|
||||
InsuranceSupplier = db.InsuranceSupplier,
|
||||
InsuredUntil = db.InsuredUntil
|
||||
InsuredUntil = db.InsuredUntil,
|
||||
IsLinked = db.AssignedUsersLinkedGroup != null || db.DevicesLinkedGroup != null
|
||||
}).ToArray().Cast<ConfigDeviceBatchIndexModelItem>().ToList();
|
||||
|
||||
foreach (var item in m.DeviceBatches.Where(db => db.DefaultDeviceModel == null))
|
||||
|
||||
@@ -20,5 +20,6 @@ namespace Disco.Web.Areas.Config.Models.DeviceBatch
|
||||
public DateTime? WarrantyExpires { get; set; }
|
||||
public DateTime? InsuredUntil { get; set; }
|
||||
public string InsuranceSupplier { get; set; }
|
||||
public bool IsLinked { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -21,7 +21,8 @@ namespace Disco.Web.Areas.Config.Models.DeviceProfile
|
||||
Description = dp.Description,
|
||||
DistributionType = dp.DistributionType.Value,
|
||||
DeviceCount = dp.Devices.Count,
|
||||
DeviceDecommissionedCount = dp.Devices.Count(d => d.DecommissionedDate.HasValue)
|
||||
DeviceDecommissionedCount = dp.Devices.Count(d => d.DecommissionedDate.HasValue),
|
||||
IsLinked = dp.AssignedUsersLinkedGroup != null || dp.DevicesLinkedGroup != null
|
||||
}).ToArray().Cast<ConfigDeviceProfileIndexModelItem>().ToList();
|
||||
|
||||
if (DiscoApplication.MultiSiteMode)
|
||||
|
||||
@@ -1,10 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using Disco.Web.Extensions;
|
||||
using Disco.Models.UI.Config.DeviceProfile;
|
||||
using Disco.Models.UI.Config.DeviceProfile;
|
||||
|
||||
namespace Disco.Web.Areas.Config.Models.DeviceProfile
|
||||
{
|
||||
@@ -20,5 +14,6 @@ namespace Disco.Web.Areas.Config.Models.DeviceProfile
|
||||
|
||||
public int DeviceCount { get; set; }
|
||||
public int DeviceDecommissionedCount { get; set; }
|
||||
public bool IsLinked { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -1,13 +1,10 @@
|
||||
using Disco.Models.UI.Config.DocumentTemplate;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
|
||||
namespace Disco.Web.Areas.Config.Models.DocumentTemplate
|
||||
{
|
||||
public class IndexModel : ConfigDocumentTemplateIndexModel
|
||||
{
|
||||
public List<Disco.Models.Repository.DocumentTemplate> DocumentTemplates { get; set; }
|
||||
public Dictionary<Disco.Models.Repository.DocumentTemplate, int> DocumentTemplates { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -5,6 +5,6 @@ namespace Disco.Web.Areas.Config.Models.UserFlag
|
||||
{
|
||||
public class IndexModel : ConfigUserFlagIndexModel
|
||||
{
|
||||
public List<Disco.Models.Repository.UserFlag> UserFlags { get; set; }
|
||||
public Dictionary<Disco.Models.Repository.UserFlag, int> UserFlags { get; set; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user