Feature #42: Active Directory Interop Upgrade
AD Interop moved to Disco.Services; Supports multi-domain environments, sites, and searching restricted with OUs.
This commit is contained in:
@@ -22,8 +22,8 @@ namespace Disco.Models.Repository
|
||||
public int DeviceProfileId { get; set; }
|
||||
public int? DeviceBatchId { get; set; }
|
||||
|
||||
[StringLength(24)]
|
||||
public string ComputerName { get; set; }
|
||||
[StringLength(50), Column("ComputerName")]
|
||||
public string DeviceDomainId { get; set; }
|
||||
public string AssignedUserId { get; set; }
|
||||
public DateTime? LastNetworkLogonDate { get; set; }
|
||||
|
||||
@@ -67,6 +67,26 @@ namespace Disco.Models.Repository
|
||||
return this.SerialNumber;
|
||||
}
|
||||
|
||||
[NotMapped]
|
||||
public string ComputerName
|
||||
{
|
||||
get
|
||||
{
|
||||
var index = DeviceDomainId.IndexOf('\\');
|
||||
return index < 0 ? DeviceDomainId : DeviceDomainId.Substring(index + 1);
|
||||
}
|
||||
}
|
||||
|
||||
[NotMapped]
|
||||
public string ComputerDomainName
|
||||
{
|
||||
get
|
||||
{
|
||||
var index = DeviceDomainId.IndexOf('\\');
|
||||
return index < 0 ? null : DeviceDomainId.Substring(0, index);
|
||||
}
|
||||
}
|
||||
|
||||
public enum DecommissionReasons
|
||||
{
|
||||
EndOfLife = 0,
|
||||
|
||||
Reference in New Issue
Block a user