qol: user device assignment helper methods for expressions
This commit is contained in:
@@ -55,21 +55,6 @@ namespace Disco.Models.Repository
|
||||
[InverseProperty(nameof(DeviceComment.Device))]
|
||||
public virtual IList<DeviceComment> DeviceComments { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// A list of the current device assignments, ordered by the most recent assignment date.
|
||||
/// </summary>
|
||||
[NotMapped]
|
||||
public IList<DeviceUserAssignment> CurrentDeviceUserAssignments
|
||||
{
|
||||
get
|
||||
{
|
||||
return DeviceUserAssignments?
|
||||
.Where(dua => dua.UnassignedDate is null)
|
||||
.OrderByDescending(dua => dua.AssignedDate)
|
||||
.ToList();
|
||||
}
|
||||
}
|
||||
|
||||
public override string ToString()
|
||||
{
|
||||
if (DeviceModel != null)
|
||||
|
||||
Reference in New Issue
Block a user