Movies can now be added monitored or unmonitored.

pull/497/head
Leonardo Galli 8 years ago
parent 82f29cdc70
commit 80e53f209d

@ -21,6 +21,7 @@ namespace NzbDrone.Api.NetImport
resource.EnableAuto = definition.EnableAuto;
resource.ProfileId = definition.ProfileId;
resource.RootFolderPath = definition.RootFolderPath;
resource.ShouldMonitor = definition.ShouldMonitor;
}
protected override void MapToModel(NetImportDefinition definition, NetImportResource resource)
@ -31,6 +32,7 @@ namespace NzbDrone.Api.NetImport
definition.EnableAuto = resource.EnableAuto;
definition.ProfileId = resource.ProfileId;
definition.RootFolderPath = resource.RootFolderPath;
definition.ShouldMonitor = resource.ShouldMonitor;
}
protected override void Validate(NetImportDefinition definition, bool includeWarnings)

@ -6,6 +6,7 @@ namespace NzbDrone.Api.NetImport
{
public bool Enabled { get; set; }
public bool EnableAuto { get; set; }
public bool ShouldMonitor { get; set; }
public string RootFolderPath { get; set; }
public int ProfileId { get; set; }
}

@ -19,6 +19,7 @@ namespace NzbDrone.Core.Datastore.Migration
.WithColumn("Settings").AsString().Nullable()
.WithColumn("EnableAuto").AsInt32()
.WithColumn("RootFolderPath").AsString()
.WithColumn("ShouldMonitor").AsInt32()
.WithColumn("ProfileId").AsInt32();
}
}

@ -593,6 +593,7 @@ namespace NzbDrone.Core.MetadataSource.SkyHook
newMovie.Path = movie.Path;
newMovie.RootFolderPath = movie.RootFolderPath;
newMovie.ProfileId = movie.ProfileId;
newMovie.Monitored = movie.Monitored;
return newMovie;
}

@ -218,6 +218,7 @@ namespace NzbDrone.Core.NetImport
{
m.RootFolderPath = ((NetImportDefinition) Definition).RootFolderPath;
m.ProfileId = ((NetImportDefinition) Definition).ProfileId;
m.Monitored = ((NetImportDefinition) Definition).ShouldMonitor;
return m;
}).ToList();
}

@ -8,6 +8,7 @@ namespace NzbDrone.Core.NetImport
{
public bool Enabled { get; set; }
public bool EnableAuto { get; set; }
public bool ShouldMonitor { get; set; }
public int ProfileId { get; set; }
public LazyLoaded<Profile> Profile { get; set; }
public string RootFolderPath { get; set; }

@ -39,6 +39,28 @@
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">Add Movies Monitored</label>
<div class="col-sm-5">
<div class="input-group">
<label class="checkbox toggle well">
<input type="checkbox" name="shouldMonitor" {{#if shouldMonitor}} checked="checked" {{/if}} />
<p>
<span>Yes</span>
<span>No</span>
</p>
<div class="btn btn-primary slide-button"></div>
</label>
<span class="help-inline-checkbox">
<i class="icon-sonarr-form-info" title="" data-original-title="If enabled, movies found by this list are added and monitored."></i>
</span>
</div>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">Quality Profile</label>

Loading…
Cancel
Save