feat: add CreatedAt to albums (#159)

This change will make the GetAlbumList views with the "newest" type
work as expected.
This commit is contained in:
Duncan Overbruck
2021-10-04 20:12:49 +02:00
committed by GitHub
parent ea141cf7d0
commit 848d85d26a
16 changed files with 189 additions and 165 deletions

View File

@@ -15,6 +15,7 @@ func NewAlbumByFolder(f *db.Album) *Album {
Title: f.RightPath,
TrackCount: f.ChildCount,
Duration: f.Duration,
Created: f.CreatedAt,
}
if f.Cover != "" {
a.CoverID = f.SID()
@@ -28,7 +29,7 @@ func NewTCAlbumByFolder(f *db.Album) *TrackChild {
IsDir: true,
Title: f.RightPath,
ParentID: f.ParentSID(),
CreatedAt: f.UpdatedAt,
CreatedAt: f.CreatedAt,
}
if f.Cover != "" {
trCh.CoverID = f.SID()