mirror of
https://github.com/Radarr/Radarr
synced 2024-12-26 01:38:24 +00:00
Added migration for notifications
This commit is contained in:
parent
c039aedbb9
commit
dbc20a3c31
2 changed files with 31 additions and 2 deletions
29
NzbDrone.Core/Datastore/Migration/Migration20130522.cs
Normal file
29
NzbDrone.Core/Datastore/Migration/Migration20130522.cs
Normal file
|
@ -0,0 +1,29 @@
|
|||
using FluentMigrator;
|
||||
using NzbDrone.Core.Datastore.Migration.Framework;
|
||||
|
||||
namespace NzbDrone.Core.Datastore.Migration
|
||||
{
|
||||
[Tags("")]
|
||||
[Migration(20130522)]
|
||||
public class Migration20130522 : NzbDroneMigrationBase
|
||||
{
|
||||
protected override void MainDbUpgrade()
|
||||
{
|
||||
Execute.Sql("DROP TABLE IF EXISTS NotificationDefinitions");
|
||||
|
||||
Rename.Table("IndexerDefinitions")
|
||||
.To("Indexers");
|
||||
|
||||
Create.TableForModel("Notifications")
|
||||
.WithColumn("Name").AsString()
|
||||
.WithColumn("OnGrab").AsBoolean()
|
||||
.WithColumn("OnDownload").AsBoolean()
|
||||
.WithColumn("Settings").AsString()
|
||||
.WithColumn("Implementation").AsString();
|
||||
}
|
||||
|
||||
protected override void LogDbUpgrade()
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
|
@ -33,9 +33,9 @@ public static void Map()
|
|||
Mapper.Entity<Config>().RegisterModel("Config");
|
||||
Mapper.Entity<RootFolder>().RegisterModel("RootFolders").Ignore(r => r.FreeSpace);
|
||||
|
||||
Mapper.Entity<IndexerDefinition>().RegisterModel("IndexerDefinitions");
|
||||
Mapper.Entity<IndexerDefinition>().RegisterModel("Indexers");
|
||||
Mapper.Entity<ScheduledTask>().RegisterModel("ScheduledTasks");
|
||||
Mapper.Entity<NotificationDefinition>().RegisterModel("NotificationDefinitions");
|
||||
Mapper.Entity<NotificationDefinition>().RegisterModel("Notifications");
|
||||
|
||||
Mapper.Entity<SceneMapping>().RegisterModel("SceneMappings");
|
||||
|
||||
|
|
Loading…
Reference in a new issue