mirror of
https://github.com/morpheus65535/bazarr
synced 2025-01-03 05:25:28 +00:00
Added exclusion settings for season 0 to prevent automatic downloading of extras subtitles.
This commit is contained in:
parent
896239b34c
commit
bd7b2eb471
3 changed files with 19 additions and 4 deletions
|
@ -94,7 +94,8 @@ defaults = {
|
||||||
'episodes_sync': '60',
|
'episodes_sync': '60',
|
||||||
'excluded_tags': '[]',
|
'excluded_tags': '[]',
|
||||||
'excluded_series_types': '[]',
|
'excluded_series_types': '[]',
|
||||||
'use_ffprobe_cache': 'True'
|
'use_ffprobe_cache': 'True',
|
||||||
|
'exclude_season_zero': 'False'
|
||||||
},
|
},
|
||||||
'radarr': {
|
'radarr': {
|
||||||
'ip': '127.0.0.1',
|
'ip': '127.0.0.1',
|
||||||
|
@ -395,12 +396,12 @@ def save_settings(settings_items):
|
||||||
configure_proxy = True
|
configure_proxy = True
|
||||||
|
|
||||||
if key in ['settings-sonarr-excluded_tags', 'settings-sonarr-only_monitored',
|
if key in ['settings-sonarr-excluded_tags', 'settings-sonarr-only_monitored',
|
||||||
'settings-sonarr-excluded_series_types', 'settings.radarr.excluded_tags',
|
'settings-sonarr-excluded_series_types', 'settings-sonarr-exclude_season_zero',
|
||||||
'settings-radarr-only_monitored']:
|
'settings.radarr.excluded_tags', 'settings-radarr-only_monitored']:
|
||||||
exclusion_updated = True
|
exclusion_updated = True
|
||||||
|
|
||||||
if key in ['settings-sonarr-excluded_tags', 'settings-sonarr-only_monitored',
|
if key in ['settings-sonarr-excluded_tags', 'settings-sonarr-only_monitored',
|
||||||
'settings-sonarr-excluded_series_types']:
|
'settings-sonarr-excluded_series_types', 'settings-sonarr-exclude_season_zero']:
|
||||||
sonarr_exclusion_updated = True
|
sonarr_exclusion_updated = True
|
||||||
|
|
||||||
if key in ['settings.radarr.excluded_tags', 'settings-radarr-only_monitored']:
|
if key in ['settings.radarr.excluded_tags', 'settings-radarr-only_monitored']:
|
||||||
|
|
|
@ -390,6 +390,10 @@ def get_exclusion_clause(exclusion_type):
|
||||||
for item in typesList:
|
for item in typesList:
|
||||||
where_clause.append((TableShows.seriesType != item))
|
where_clause.append((TableShows.seriesType != item))
|
||||||
|
|
||||||
|
exclude_season_zero = settings.sonarr.getboolean('exclude_season_zero')
|
||||||
|
if exclude_season_zero:
|
||||||
|
where_clause.append((TableEpisodes.season != 0))
|
||||||
|
|
||||||
return where_clause
|
return where_clause
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -97,6 +97,16 @@ const SettingsSonarrView: FunctionComponent<Props> = () => {
|
||||||
episodes in Sonarr.
|
episodes in Sonarr.
|
||||||
</Message>
|
</Message>
|
||||||
</Input>
|
</Input>
|
||||||
|
<Input>
|
||||||
|
<Check
|
||||||
|
label="Exclude season zero (extras)"
|
||||||
|
settingKey="settings-sonarr-exclude_season_zero"
|
||||||
|
></Check>
|
||||||
|
<Message>
|
||||||
|
Episodes from season zero (extras) from automatic download of
|
||||||
|
subtitles.
|
||||||
|
</Message>
|
||||||
|
</Input>
|
||||||
</Group>
|
</Group>
|
||||||
<Group header="Path Mappings">
|
<Group header="Path Mappings">
|
||||||
<PathMappingTable type="sonarr"></PathMappingTable>
|
<PathMappingTable type="sonarr"></PathMappingTable>
|
||||||
|
|
Loading…
Reference in a new issue