mirror of
https://github.com/collinbarrett/FilterLists.git
synced 2026-03-11 09:04:27 +00:00
parent
03eb87597c
commit
67fc31b620
2 changed files with 8 additions and 6 deletions
|
|
@ -25,14 +25,15 @@ public ListDetailsDtoMappingProfile() =>
|
|||
: 0))
|
||||
.ForMember(d => d.UpdatedDate,
|
||||
o => o.MapFrom(l =>
|
||||
l.Snapshots
|
||||
.Count(s => s.WasSuccessful && s.Md5Checksum != null) >= 2
|
||||
l.DiscontinuedDate ??
|
||||
(l.Snapshots
|
||||
.Count(s => s.WasSuccessful && s.Md5Checksum != null) >= 2
|
||||
? l.Snapshots
|
||||
.Where(s => s.WasSuccessful && s.Md5Checksum != null)
|
||||
.Select(s => s.CreatedDateUtc)
|
||||
.OrderByDescending(c => c)
|
||||
.FirstOrDefault()
|
||||
: null))
|
||||
: null)))
|
||||
.ForMember(d => d.ViewUrl,
|
||||
o => o.MapFrom(l =>
|
||||
l.Snapshots
|
||||
|
|
|
|||
|
|
@ -14,14 +14,15 @@ public ListSummaryDtoMappingProfile() =>
|
|||
.ForMember(d => d.Tags, o => o.MapFrom(l => l.FilterListTags.Select(m => m.Tag)))
|
||||
.ForMember(d => d.UpdatedDate,
|
||||
o => o.MapFrom(l =>
|
||||
l.Snapshots
|
||||
.Count(s => s.WasSuccessful && s.Md5Checksum != null) >= 2
|
||||
l.DiscontinuedDate ??
|
||||
(l.Snapshots
|
||||
.Count(s => s.WasSuccessful && s.Md5Checksum != null) >= 2
|
||||
? l.Snapshots
|
||||
.Where(s => s.WasSuccessful && s.Md5Checksum != null)
|
||||
.Select(s => s.CreatedDateUtc)
|
||||
.OrderByDescending(c => c)
|
||||
.FirstOrDefault()
|
||||
: null))
|
||||
: null)))
|
||||
.ForMember(d => d.ViewUrl,
|
||||
o => o.MapFrom(l =>
|
||||
l.Snapshots
|
||||
|
|
|
|||
Loading…
Reference in a new issue