DB now stores Artists. DB schema may need small tweaks.

pull/4/head
Joseph Milazzo 7 years ago
parent f2a8336b31
commit 5ee1077e1e

@ -15,25 +15,24 @@ namespace NzbDrone.Core.Datastore.Migration
Create.TableForModel("Artist")
.WithColumn("ItunesId").AsInt32().Unique()
.WithColumn("ArtistName").AsString().Unique()
.WithColumn("ArtistSlug").AsString().Unique()
.WithColumn("CleanTitle").AsString() // Do we need this?
.WithColumn("ArtistSlug").AsString().Nullable() //.Unique()
.WithColumn("CleanTitle").AsString().Nullable() // Do we need this?
.WithColumn("Monitored").AsBoolean()
.WithColumn("AlbumFolder").AsBoolean()
.WithColumn("ArtistFolder").AsBoolean()
.WithColumn("AlbumFolder").AsBoolean().Nullable()
.WithColumn("ArtistFolder").AsBoolean().Nullable()
.WithColumn("LastInfoSync").AsDateTime().Nullable()
.WithColumn("LastDiskSync").AsDateTime().Nullable()
.WithColumn("Status").AsInt32()
.WithColumn("Status").AsInt32().Nullable()
.WithColumn("Path").AsString()
.WithColumn("Images").AsString()
.WithColumn("QualityProfileId").AsInt32()
.WithColumn("RootFolderPath").AsString()
.WithColumn("Added").AsDateTime()
.WithColumn("ProfileId").AsInt32() // This is either ProfileId or Profile
.WithColumn("Genres").AsString()
.WithColumn("Albums").AsString()
.WithColumn("Tags").AsString()
.WithColumn("AddOptions").AsString()
.WithColumn("Images").AsString().Nullable()
.WithColumn("QualityProfileId").AsInt32().Nullable()
.WithColumn("RootFolderPath").AsString().Nullable()
.WithColumn("Added").AsDateTime().Nullable()
.WithColumn("ProfileId").AsInt32().Nullable() // This is either ProfileId or Profile
.WithColumn("Genres").AsString().Nullable()
.WithColumn("Albums").AsString().Nullable()
.WithColumn("Tags").AsString().Nullable()
.WithColumn("AddOptions").AsString().Nullable()
;
Create.TableForModel("Albums")

@ -95,7 +95,7 @@ namespace NzbDrone.Core.Datastore
Mapper.Entity<Artist>().RegisterModel("Artist")
.Ignore(s => s.RootFolderPath)
.Relationship()
.HasOne(s => s.Profile, s => s.ProfileId);
.HasOne(a => a.Profile, a => a.ProfileId);
Mapper.Entity<TrackFile>().RegisterModel("TrackFiles")
.Ignore(f => f.Path)

Loading…
Cancel
Save