Initial Commit

pull/884/head
Moravčík, Marian 5 years ago
parent 8cd2224cb6
commit b9651d1ed0

File diff suppressed because it is too large Load Diff

@ -0,0 +1,130 @@
<!doctype html>
<html lang="en">
<head>
<title>{% block title %} {% endblock %}</title>
{% block head_meta %}
<script src="{{base_url}}static/jquery/jquery-latest.min.js"></script>
<script src="{{base_url}}static/semantic/semantic.min.js"></script>
<script src="{{base_url}}static/jquery/tablesort.js"></script>
<link rel="stylesheet" href="{{base_url}}static/semantic/semantic.min.css">
<link rel="apple-touch-icon" sizes="120x120" href="{{base_url}}static/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="{{base_url}}static/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="{{base_url}}static/favicon-16x16.png">
<link rel="manifest" href="{{base_url}}static/manifest.json">
<link rel="mask-icon" href="{{base_url}}static/safari-pinned-tab.svg" color="#5bbad5">
<link rel="shortcut icon" href="{{base_url}}static/favicon.ico">
<meta name="msapplication-config" content="{{base_url}}static/browserconfig.xml">
<meta name="theme-color" content="#ffffff">
{% endblock head_meta %}
{% block head_css %}
<!-- Bootstrap Core CSS -->
<link href="{{ url_for('static',filename='plugins/bootstrap/css/bootstrap.min.css') }}" rel="stylesheet">
<link rel="stylesheet" type="text/css" href={{ url_for("static", filename="iron.css") }}>
<!--This page css - Morris CSS -->
<link href="{{ url_for('static',filename='plugins/c3-master/c3.min.css') }}" rel="stylesheet">
<!-- Custom CSS -->
<link href="{{ url_for('static',filename='css/style.css') }}" rel="stylesheet">
<!-- You can change the theme colors from here -->
<link href="{{ url_for('static',filename='css/colors/blue.css') }}" rel="stylesheet">
<!-- SweetAlert2 -->
<link href="{{ url_for('static',filename='plugins/sweetalert2/sweetalert2.min.css') }}" rel="stylesheet">
<!--[if lt IE 9]> -->
<script src="{{ url_for('static',filename='js/html5shiv.min.js') }}"></script>
<script src="{{ url_for('static',filename='js/respond.min.js') }}"></script>
<script src="{{ url_for('static',filename='js/polyfill.min.js') }}"></script>
<script type="text/javascript"
src="https://agile.ironmountain.com/jira/s/d41d8cd98f00b204e9800998ecf8427e-CDN/eaeik7/800007/23de5049e29b4e5a8a9d712986eca8ec/2.2.4.6/_/download/batch/com.atlassian.plugins.jquery:jquery/com.atlassian.plugins.jquery:jquery.js?collectorId=c0cc47fb"></script>
<script type="text/javascript"
src="https://agile.ironmountain.com/jira/s/05b27ac9d3a09aa46f6a60b42dc992c6-T/eaeik7/800007/23de5049e29b4e5a8a9d712986eca8ec/3.0.7/_/download/batch/com.atlassian.jira.collector.plugin.jira-issue-collector-plugin:issuecollector/com.atlassian.jira.collector.plugin.jira-issue-collector-plugin:issuecollector.js?locale=en-US&collectorId=c0cc47fb"></script>
{% endblock head_css %}
{% block head %}
{% endblock head %}
{% block head_tail %}
{% endblock head_tail %}
</head>
<body class="fix-header card-no-border fix-sidebar">
{% if password %}
{% include "password_change.html" %}
{% endif %}
{% block page_body %}
{% block body %}
{% endblock body %}
</div>
{% endblock page_body %}
{% block tail_js %}
<script src="{{ url_for('static',filename='plugins/jquery/jquery.min.js') }}"></script>
<!-- Bootstrap tether Core JavaScript -->
<script src="{{ url_for('static',filename='plugins/popper/popper.min.js') }}"></script>
<script src="{{ url_for('static',filename='plugins/bootstrap/js/bootstrap.min.js') }}"></script>
<!--Wave Effects -->
<script src="{{ url_for('static',filename='js/waves.js') }}"></script>
<!--Menu sidebar -->
<script src="{{ url_for('static',filename='js/sidebarmenu.js') }}"></script>
<script src="{{ url_for('static',filename='js/validation.js') }}"></script>
<!-- Sweet-Alert -->
<script src="{{ url_for('static',filename='plugins/sweetalert2/sweetalert2.min.js') }}"></script>
<script src="{{ url_for('static',filename='plugins/session-timeout/idle/jquery.idletimeout.js') }}"></script>
<script src="{{ url_for('static',filename='plugins/session-timeout/idle/jquery.idletimer.js') }}"></script>
<script src="{{ url_for('static',filename='plugins/session-timeout/idle/session-timeout-idle-init.js') }}"></script>
<!--c3 JavaScript -->
<script src="{{ url_for('static',filename='plugins/d3/d3.min.js') }}"></script>
<script src="{{ url_for('static',filename='plugins/c3-master/c3.min.js') }}"></script>
<script src="{{ url_for('static',filename='plugins/moment/moment.js') }}"></script>
<script src="{{ url_for('static',filename='plugins/moment/locale/sk.js') }}"></script>
<!--Custom JavaScript -->
<script src="{{ url_for('static',filename='plugins/dff/dff.js') }}"></script>
<script src="{{ url_for('static',filename='plugins/sticky-kit-master/dist/sticky-kit.min.js') }}"></script>
<script src="{{ url_for('static',filename='js/jquery.slimscroll.js') }}"></script>
<script src="{{ url_for('static',filename='plugins/sparkline/jquery.sparkline.min.js') }}"></script>
<script src="{{ url_for('static',filename='js/custom.js') }}"></script>
<script>
$(document).ready(function () {
{% with messages = get_flashed_messages(with_categories=true, category_filter=('success', 'warning', 'error', 'info')) %}
{% if messages %}
{% for category, message in messages %}
var msg = "{{ message }}";
var type = "{{ category }}";
{% endfor %}
Swal.fire({
title: msg,
type: type,
timer: 5000,
allowEnterKey: true,
showConfirmButton: false
});
{% endif %}
{% endwith %}
{% if password %}
$("#passchange").modal('show');
$('#passchange').on('shown.bs.modal', function () {
$('#password1').focus();
});
{% endif %}
});
</script>
{% endblock tail_js %}
{% block tail %}
{% endblock tail %}
</body>
</html>

@ -782,14 +782,14 @@
<div class='field' hidden>
<select name="settings_subliminal_providers" id="settings_providers" multiple="" class="ui fluid search selection dropdown">
<option value="">Providers</option>
%enabled_providers = []
%providers = settings.general.enabled_providers.lower().split(',')
%for provider in settings_providers:
{% set enabled_providers = [] %}
{% set providers = settings.general.enabled_providers.lower().split(',') %}
{% for provider in settings_providers %}
<option value="{{provider}}">{{provider}}</option>
%end
%for provider in providers:
%enabled_providers.append(str(provider))
%end
{% endfor %}
{% for provider in providers %}
{{ enabled_providers.append(provider) }}
{% endfor %}
</select>
</div>
</div>
@ -823,7 +823,7 @@
}
$('#settings_providers').dropdown('clear');
$('#settings_providers').dropdown('set selected',{{!enabled_providers}});
$('#settings_providers').dropdown('set selected',{{ enabled_providers|safe }});
$('#settings_providers').dropdown();
$('#settings_providers').dropdown('setting', 'onChange', function(){

@ -42,7 +42,7 @@
<div id='loader' class="ui page dimmer">
<div id="loader_text" class="ui indeterminate text loader">Saving settings...</div>
</div>
% include('menu.tpl')
{% include 'menu.html' %}
<div id="fondblanc" class="ui container">
<form name="settings_form" id="settings_form" action="{{base_url}}save_settings" method="post" class="ui form" autocomplete="off">
@ -58,27 +58,27 @@
</div>
<div class="ui bottom attached tab segment active" data-tab="general">
<div class="ui container"><button class="submit ui blue right floated button" type="submit" value="Submit" form="settings_form">Save</button></div>
% include('settings_general.tpl')
{% include 'settings_general.html' %}
</div>
<div class="ui bottom attached tab segment" data-tab="sonarr">
<div class="ui container"><button class="submit ui blue right floated button" type="submit" value="Submit" form="settings_form">Save</button></div>
% include('settings_sonarr.tpl')
{% include 'settings_sonarr.html' %}
</div>
<div class="ui bottom attached tab segment" data-tab="radarr">
<div class="ui container"><button class="submit ui blue right floated button" type="submit" value="Submit" form="settings_form">Save</button></div>
% include('settings_radarr.tpl')
{% include 'settings_radarr.html' %}
</div>
<div class="ui bottom attached tab segment" data-tab="subtitles">
<div class="ui container"><button class="submit ui blue right floated button" type="submit" value="Submit" form="settings_form">Save</button></div>
% include('settings_subtitles.tpl')
{% include 'settings_subtitles.html' %}
</div>
<div class="ui bottom attached tab segment" data-tab="notifier">
<div class="ui container"><button class="submit ui blue right floated button" type="submit" value="Submit" form="settings_form">Save</button></div>
% include('settings_notifications.tpl')
{% include 'settings_notifications.html' %}
</div>
</form>
</div>
% include('footer.tpl')
{% include 'footer.tpl' %}
</body>
</html>

@ -0,0 +1,935 @@
<div class="ui dividing header">Start-Up</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Listening IP Address</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input name="settings_general_ip" type="text" value="{{ settings.general.ip }}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires restart to take effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Valid IP4 Address or '0.0.0.0' for all interfaces"
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Listening Port</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input name="settings_general_port" type="text" value="{{ settings.general.port }}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires restart to take effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Valid TCP port (default: 6767)" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Base URL</label>
</div>
<div class="five wide column">
<div class="ui fluid input">
{% if settings.general.base_url == None %}
{% set base_url = "/" %}
{% else %}
{% set base_url = settings.general.base_url %}
{% endif %}
<input name="settings_general_baseurl" type="text" value="{{ base_url }}">
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires restart to take effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="For reverse proxy support, default is '/'" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Enable Debug Logging</label>
</div>
<div class="five wide column">
<div id="settings_debug" class="ui toggle checkbox"
data-debug={{ settings.general.getboolean('debug') }}>
<input name="settings_general_debug" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Debug logging should only be enabled temporarily"
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div id="chmod_enabled" class="middle aligned row">
<div class="right aligned four wide column">
<label>Enable CHMOD</label>
</div>
<div class="five wide column">
<div id="settings_chmod_enabled" class="ui toggle checkbox"
data-chmod={{ settings.general.getboolean('chmod_enabled') }}>
<input name="settings_general_chmod_enabled" type="checkbox">
<label></label>
</div>
</div>
</div>
<div id="chmod" class="middle aligned row">
<div class="right aligned four wide column">
<label>Set Subtitle file permissions to</label>
</div>
<div class="five wide column">
<div class='field'>
<div id="settings_chmod" class="ui fluid input">
<input name="settings_general_chmod" type="text"
value={{ settings.general.chmod }}>
<label></label>
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Must be 4 digit octal, e.g.: 0775" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Page Size</label>
</div>
<div class="five wide column">
<select name="settings_page_size" id="settings_page_size" class="ui fluid selection dropdown">
<option value="">Page Size</option>
<option value="-1">Unlimited</option>
<option value="25">25</option>
<option value="50">50</option>
<option value="100">100</option>
<option value="250">250</option>
<option value="500">500</option>
<option value="1000">1000</option>
</select>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="How many items to show in a list." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Proxy settings</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Proxy Type</label>
</div>
<div class="five wide column">
<select name="settings_proxy_type" id="settings_proxy_type" class="ui fluid selection dropdown">
<option value="None">None</option>
<option value="http">HTTP(S)</option>
<option value="socks4">Socks4</option>
<option value="socks5">Socks5</option>
</select>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires restart to take effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Type of your proxy." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="proxy_option middle aligned row">
<div class="right aligned four wide column">
<label>Hostname</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_proxy_url" name="settings_proxy_url" type="text"
value="{{ settings.proxy.url }}">
</div>
</div>
</div>
</div>
<div class="proxy_option middle aligned row">
<div class="right aligned four wide column">
<label>Port</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_proxy_port" name="settings_proxy_port" type="text"
value="{{ settings.proxy.port }}">
</div>
</div>
</div>
</div>
<div class="proxy_option middle aligned row">
<div class="right aligned four wide column">
<label>Username</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_proxy_username" name="settings_proxy_username" type="text"
value="{{ settings.proxy.username }}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="UYou only need to enter a username and password if one is required. Leave them blank otherwise"
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="proxy_option middle aligned row">
<div class="right aligned four wide column">
<label>Password</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_proxy_password" name="settings_proxy_password" type="password"
value="{{ settings.proxy.password }}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="You only need to enter a username and password if one is required. Leave them blank otherwise"
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="proxy_option middle aligned row">
<div class="right aligned four wide column">
<label>Ignored Addresses</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_proxy_exclude" name="settings_proxy_exclude" type="text"
value="{{ settings.proxy.exclude }}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Use ',' as a separator, and '*.' as a wildcard for subdomains"
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Security Settings</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Authentication</label>
</div>
<div class="five wide column">
<select name="settings_auth_type" id="settings_auth_type" class="ui fluid selection dropdown">
<option value="None">None</option>
<option value="basic">Basic (Browser Popup)</option>
<option value="form">Forms (Login Page)</option>
</select>
<label></label>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires restart to take effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Require Username and Password to access Bazarr."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="auth_option middle aligned row">
<div class="right aligned four wide column">
<label>Username</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_auth_username" name="settings_auth_username" type="text" autocomplete="nope"
value="{{ settings.auth.username }}">
</div>
</div>
</div>
</div>
<div class="auth_option middle aligned row">
<div class="right aligned four wide column">
<label>Password</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_auth_password" name="settings_auth_password" type="password"
autocomplete="new-password" value="{{ settings.auth.password }}">
</div>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Authentication send username and password in clear text over the network. You should add SSL encryption through a reverse proxy."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>API Key</label>
</div>
<div class="six wide column">
<div class='field'>
<div class="ui action input">
<input id="settings_auth_apikey" name="settings_auth_apikey" type="text" readonly
value="{{ settings.auth.apikey }}">
<button class="no_loader ui red icon button" type="button" onclick="generate_apikey()">
<i class="sync icon"></i>
</button>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Integration settings</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Use Sonarr</label>
</div>
<div class="one wide column">
<div id="settings_use_sonarr" class="ui toggle checkbox"
data-enabled={{ settings.general.getboolean('use_sonarr') }}>
<input name="settings_general_use_sonarr" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Enable Sonarr Integration." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Use Radarr</label>
</div>
<div class="one wide column">
<div id="settings_use_radarr" class="ui toggle checkbox"
data-enabled={{ settings.general.getboolean('use_radarr') }}>
<input name="settings_general_use_radarr" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Enable Radarr Integration." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Path Mappings For TV Shows</div>
<div class="twelve wide column">
<div class="ui grid">
{% if settings.general.path_mappings != None %}
{% set path_substitutions = ast.literal_eval(settings.general.path_mappings) %}
{% else %}
{% set path_substitutions = [] %}
{% endif %}
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Sonarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Root path to the directory Sonarr accesses."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="two wide center aligned column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Bazarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Path that Bazarr should use to access the same directory remotely."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
{% for x in range(0, 5) %}
{% set path = [] %}
{% if path_substitutions[x] %}
{% set path = path_substitutions[x] %}
{% else %}
{% set path = ["", ""] %}
{% endif %}
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_sourcepath" type="text" value="{{ path[0] }}">
</div>
</div>
<div class="center aligned column">
<i class="arrow circle right icon"></i>
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_destpath" type="text" value="{{ path[1] }}">
</div>
</div>
</div>
{% endfor %}
</div>
</div>
<div class="ui dividing header">Path Mappings For Movies</div>
<div class="twelve wide column">
<div class="ui grid">
{% if settings.general.path_mappings_movie != None %}
{% set path_substitutions_movie = ast.literal_eval(settings.general.path_mappings_movie) %}
{% else %}
{% set path_substitutions_movie = [] %}
{% endif %}
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Radarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Root path to the directory Radarr accesses."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="two wide center aligned column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Bazarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Path that Bazarr should use to access the same directory remotely."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
{% for x in range(0, 5) %}
{% set path_movie = [] %}
{% if path_substitutions_movie[x] %}
{% set path_movie = path_substitutions_movie[x] %}
{% else %}
{% set path_movie = ["", ""] %}
{% endif %}
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_sourcepath_movie" type="text" value="{{ path_movie[0] }}">
</div>
</div>
<div class="center aligned column">
<i class="arrow circle right icon"></i>
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_destpath_movie" type="text" value="{{ path_movie[1] }}">
</div>
</div>
</div>
{% endfor %}
</div>
</div>
<div class="ui dividing header">Post-processing</div>
<div class="twelve wide column">
<div class="ui orange message">
<p>Be aware that the execution of post-processing command will prevent the user interface from being accessible
until completion, when downloading subtitles in interactive mode (meaning you'll see a loader during
post-processing).</p>
</div>
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Use post-processing</label>
</div>
<div class="one wide column">
<div id="settings_use_postprocessing" class="ui toggle checkbox"
data-postprocessing={{ settings.general.getboolean('use_postprocessing') }}>
<input name="settings_general_use_postprocessing" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Enable the post-processing execution after downloading a subtitles."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row postprocessing">
<div class="right aligned four wide column">
<label>Post-processing command</label>
</div>
<div class="five wide column">
<div id="settings_general_postprocessing_cmd_div" class="ui fluid input">
<input name="settings_general_postprocessing_cmd" type="text"
value="{{ settings.general.postprocessing_cmd if settings.general.postprocessing_cmd != None else '' }}">
</div>
</div>
</div>
<div class="middle aligned row postprocessing">
<div class="right aligned four wide column">
<label>Variables you can use in your command (include the double curly brace):</label>
</div>
<div class="ten wide column">
<div class="ui list">
<div class="item">
<div class="header">&lbrace;&lbrace;directory&rbrace;&rbrace;</div>
The full path of the episode file parent directory.
</div>
<div class="item">
<div class="header">&lbrace;&lbrace;episode&rbrace;&rbrace;</div>
The full path of the episode file.
</div>
<div class="item">
<div class="header">&lbrace;&lbrace;episode_name&rbrace;&rbrace;</div>
The filename of the episode without parent directory or extension.
</div>
<div class="item">
<div class="header">&lbrace;&lbrace;subtitles&rbrace;&rbrace;</div>
The full path of the subtitles file.
</div>
<div class="item">
<div class="header">&lbrace;&lbrace;subtitles_language&rbrace;&rbrace;</div>
The language of the subtitles file.
</div>
<div class="item">
<div class="header">&lbrace;&lbrace;subtitles_language_code2&rbrace;&rbrace;</div>
The 2-letter ISO-639 language code of the subtitles language.
</div>
<div class="item">
<div class="header">&lbrace;&lbrace;subtitles_language_code3&rbrace;&rbrace;</div>
The 3-letter ISO-639 language code of the subtitles language.
</div>
</div>
</div>
</div>
</div>
</div>
<div id="div_update">
<div class="ui dividing header">Updates</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row" id="div_branch">
<div class="right aligned four wide column">
<label>Branch</label>
</div>
<div class="five wide column">
<select name="settings_general_branch" id="settings_branch" class="ui fluid selection dropdown">
<option value="">Branch</option>
<option value="master">master</option>
<option value="development">development</option>
</select>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Only select development branch if you want to live on the edge."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Automatic</label>
</div>
<div class="one wide column">
<div id="settings_automatic_div" class="ui toggle checkbox"
data-automatic={{ settings.general.getboolean('auto_update') }}>
<input name="settings_general_automatic" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Automatically download and install updates. You will still be able to install from System: Tasks"
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Restart after update</label>
</div>
<div class="one wide column">
<div id="settings_update_restart" class="ui toggle checkbox"
data-update-restart={{ settings.general.getboolean('update_restart') }}>
<input name="settings_general_update_restart" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Automatically restart after downloading and installing updates. You will still be able to restart manually"
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Analytics</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Enable</label>
</div>
<div class="one wide column">
<div id="settings_analytics_enabled" class="ui toggle checkbox"
data-analytics={{ settings.analytics.getboolean('enabled') }}>
<input name="settings_analytics_enabled" type="checkbox">
<label></label>
</div>
</div>
</div>
<div class="middle align row">
<div class="right aligned four wide column">
</div>
<div class="one wide column">
<i class="help circle large icon"></i>
</div>
<div class="ten wide column">
Send anonymous usage information, nothing that can identify you. This includes information on which
providers you use, what languages you search for, Bazarr, Python, Sonarr, Radarr and what OS version you
are using. We will use this information to prioritize features and bug fixes. Please, keep this enabled
as this is the only way we have to better understand how you use Bazarr.
</div>
</div>
</div>
</div>
<script>
{% if args.no_update %}
$("#div_update").hide();
{% elif args.release_update %}
$("#div_branch").hide();
{% endif %}
{%if sys.platform.startswith('win')%}
$("#chmod").hide();
$("#chmod_enabled").hide();
{%endif%}
if ($('#settings_automatic_div').data("automatic") === "True") {
$("#settings_automatic_div").checkbox('check');
} else {
$("#settings_automatic_div").checkbox('uncheck');
}
if ($('#settings_update_restart').data("update-restart") === "True") {
$("#settings_update_restart").checkbox('check');
} else {
$("#settings_update_restart").checkbox('uncheck');
}
if ($('#settings_debug').data("debug") === "True") {
$("#settings_debug").checkbox('check');
} else {
$("#settings_debug").checkbox('uncheck');
}
if ($('#settings_chmod_enabled').data("chmod") === "True") {
$("#settings_chmod_enabled").checkbox('check');
} else {
$("#settings_chmod_enabled").checkbox('uncheck');
}
if ($('#settings_analytics_enabled').data("analytics") === "True") {
$("#settings_analytics_enabled").checkbox('check');
} else {
$("#settings_analytics_enabled").checkbox('uncheck');
}
if ($('#settings_use_postprocessing').data("postprocessing") === "True") {
$("#settings_use_postprocessing").checkbox('check');
$("#settings_general_postprocessing_cmd_div").removeClass('disabled');
} else {
$("#settings_use_postprocessing").checkbox('uncheck');
$("#settings_general_postprocessing_cmd_div").addClass('disabled');
}
$("#settings_use_postprocessing").on('change', function (i, obj) {
if ($("#settings_use_postprocessing").checkbox('is checked')) {
$("#settings_general_postprocessing_cmd_div").removeClass('disabled');
} else {
$("#settings_general_postprocessing_cmd_div").addClass('disabled');
}
});
if ($('#settings_use_postprocessing').data("postprocessing") === "True") {
$('.postprocessing').show();
} else {
$('.postprocessing').hide();
}
$('#settings_use_postprocessing').checkbox({
onChecked: function () {
$('.postprocessing').show();
},
onUnchecked: function () {
$('.postprocessing').hide();
}
});
if ($('#settings_use_sonarr').data("enabled") === "True") {
$("#settings_use_sonarr").checkbox('check');
$("#sonarr_tab").removeClass('disabled');
} else {
$("#settings_use_sonarr").checkbox('uncheck');
$("#sonarr_tab").addClass('disabled');
}
$('#settings_use_sonarr').checkbox({
onChecked: function () {
$("#sonarr_tab").removeClass('disabled');
$('#sonarr_validated').checkbox('uncheck');
$('.form').form('validate form');
$('#loader').removeClass('active');
},
onUnchecked: function () {
$("#sonarr_tab").addClass('disabled');
}
});
if ($('#settings_use_radarr').data("enabled") === "True") {
$("#settings_use_radarr").checkbox('check');
$("#radarr_tab").removeClass('disabled');
} else {
$("#settings_use_radarr").checkbox('uncheck');
$("#radarr_tab").addClass('disabled');
}
$('#settings_use_radarr').checkbox({
onChecked: function () {
$("#radarr_tab").removeClass('disabled');
$('#radarr_validated').checkbox('uncheck');
$('.form').form('validate form');
$('#loader').removeClass('active');
},
onUnchecked: function () {
$("#radarr_tab").addClass('disabled');
}
});
if ($('#settings_chmod_enabled').data("chmod") === "True") {
$('#chmod').show();
} else {
$('#chmod').hide();
}
$('#settings_chmod_enabled').checkbox({
onChecked: function () {
$('#chmod').show();
},
onUnchecked: function () {
$('#chmod').hide();
}
});
if ($('#settings_auth_type').val() === "None") {
$('.auth_option').hide();
}
$('#settings_auth_type').dropdown('setting', 'onChange', function () {
if ($('#settings_auth_type').val() === "None") {
$('.auth_option').hide();
} else {
$('.auth_option').show();
}
});
// Load default value for Settings_auth_type
$('#settings_auth_type').dropdown('clear');
$('#settings_auth_type').dropdown('set selected', '{{settings.auth.type|safe}}');
// Remove value from Password input when changing to Form login to prevent bad password saving
$("#settings_auth_type").on('change', function () {
if ($(this).val() === 'form') {
$('#settings_auth_password').val('');
} else {
$('#settings_auth_password').val('{{settings.auth.password}}');
}
});
$('#settings_loglevel').dropdown('clear');
$('#settings_loglevel').dropdown('set selected', '{{settings.general.getboolean('debug')|safe}}');
$('#settings_page_size').dropdown('clear');
$('#settings_page_size').dropdown('set selected', '{{settings.general.page_size|safe}}');
$('#settings_proxy_type').dropdown('clear');
$('#settings_proxy_type').dropdown('set selected', '{{settings.proxy.type|safe}}');
$('#settings_branch').dropdown('clear');
$('#settings_branch').dropdown('set selected', '{{settings.general.branch|safe}}');
$('#settings_auth_username').on('keyup', function () {
$('#settings_auth_password').val('');
$('.form').form('validate form');
$('#loader').removeClass('active');
});
</script>
<script>
function generate_apikey() {
var result = '';
var characters = 'abcdef0123456789';
var charactersLength = characters.length;
for (var i = 0; i < 32; i++) {
result += characters.charAt(Math.floor(Math.random() * charactersLength));
}
$("#settings_auth_apikey").val(result);
}
</script>

@ -1,896 +0,0 @@
<div class="ui dividing header">Start-Up</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Listening IP Address</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input name="settings_general_ip" type="text" value="{{settings.general.ip}}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires restart to take effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Valid IP4 Address or '0.0.0.0' for all interfaces" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Listening Port</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input name="settings_general_port" type="text" value="{{settings.general.port}}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires restart to take effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Valid TCP port (default: 6767)" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Base URL</label>
</div>
<div class="five wide column">
<div class="ui fluid input">
%if settings.general.base_url is None:
% base_url = "/"
%else:
% base_url = settings.general.base_url
%end
<input name="settings_general_baseurl" type="text" value="{{base_url}}">
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires restart to take effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="For reverse proxy support, default is '/'" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Enable Debug Logging</label>
</div>
<div class="five wide column">
<div id="settings_debug" class="ui toggle checkbox" data-debug={{settings.general.getboolean('debug')}}>
<input name="settings_general_debug" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Debug logging should only be enabled temporarily" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div id="chmod_enabled" class="middle aligned row">
<div class="right aligned four wide column">
<label>Enable CHMOD</label>
</div>
<div class="five wide column">
<div id="settings_chmod_enabled" class="ui toggle checkbox" data-chmod={{settings.general.getboolean('chmod_enabled')}}>
<input name="settings_general_chmod_enabled" type="checkbox">
<label></label>
</div>
</div>
</div>
<div id="chmod" class="middle aligned row">
<div class="right aligned four wide column">
<label>Set Subtitle file permissions to</label>
</div>
<div class="five wide column">
<div class='field'>
<div id="settings_chmod" class="ui fluid input">
<input name="settings_general_chmod" type="text"
value={{ settings.general.chmod }}>
<label></label>
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Must be 4 digit octal, e.g.: 0775" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Page Size</label>
</div>
<div class="five wide column">
<select name="settings_page_size" id="settings_page_size" class="ui fluid selection dropdown">
<option value="">Page Size</option>
<option value="-1">Unlimited</option>
<option value="25">25</option>
<option value="50">50</option>
<option value="100">100</option>
<option value="250">250</option>
<option value="500">500</option>
<option value="1000">1000</option>
</select>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="How many items to show in a list." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Proxy settings</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Proxy Type</label>
</div>
<div class="five wide column">
<select name="settings_proxy_type" id="settings_proxy_type" class="ui fluid selection dropdown">
<option value="None">None</option>
<option value="http">HTTP(S)</option>
<option value="socks4">Socks4</option>
<option value="socks5">Socks5</option>
</select>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires restart to take effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Type of your proxy." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="proxy_option middle aligned row">
<div class="right aligned four wide column">
<label>Hostname</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_proxy_url" name="settings_proxy_url" type="text" value="{{settings.proxy.url}}">
</div>
</div>
</div>
</div>
<div class="proxy_option middle aligned row">
<div class="right aligned four wide column">
<label>Port</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_proxy_port" name="settings_proxy_port" type="text" value="{{settings.proxy.port}}">
</div>
</div>
</div>
</div>
<div class="proxy_option middle aligned row">
<div class="right aligned four wide column">
<label>Username</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_proxy_username" name="settings_proxy_username" type="text" value="{{settings.proxy.username}}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="UYou only need to enter a username and password if one is required. Leave them blank otherwise" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="proxy_option middle aligned row">
<div class="right aligned four wide column">
<label>Password</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_proxy_password" name="settings_proxy_password" type="password" value="{{settings.proxy.password}}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="You only need to enter a username and password if one is required. Leave them blank otherwise" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="proxy_option middle aligned row">
<div class="right aligned four wide column">
<label>Ignored Addresses</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_proxy_exclude" name="settings_proxy_exclude" type="text" value="{{settings.proxy.exclude}}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Use ',' as a separator, and '*.' as a wildcard for subdomains" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Security Settings</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Authentication</label>
</div>
<div class="five wide column">
<select name="settings_auth_type" id="settings_auth_type" class="ui fluid selection dropdown">
<option value="None">None</option>
<option value="basic">Basic (Browser Popup)</option>
<option value="form">Forms (Login Page)</option>
</select>
<label></label>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires restart to take effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Require Username and Password to access Bazarr." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="auth_option middle aligned row">
<div class="right aligned four wide column">
<label>Username</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_auth_username" name="settings_auth_username" type="text" autocomplete="nope" value="{{settings.auth.username}}">
</div>
</div>
</div>
</div>
<div class="auth_option middle aligned row">
<div class="right aligned four wide column">
<label>Password</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_auth_password" name="settings_auth_password" type="password" autocomplete="new-password" value="{{settings.auth.password}}">
</div>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Authentication send username and password in clear text over the network. You should add SSL encryption through a reverse proxy." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>API Key</label>
</div>
<div class="six wide column">
<div class='field'>
<div class="ui action input">
<input id="settings_auth_apikey" name="settings_auth_apikey" type="text" readonly value="{{settings.auth.apikey}}">
<button class="no_loader ui red icon button" type="button" onclick="generate_apikey()">
<i class="sync icon"></i>
</button>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Integration settings</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Use Sonarr</label>
</div>
<div class="one wide column">
<div id="settings_use_sonarr" class="ui toggle checkbox" data-enabled={{settings.general.getboolean('use_sonarr')}}>
<input name="settings_general_use_sonarr" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Enable Sonarr Integration." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Use Radarr</label>
</div>
<div class="one wide column">
<div id="settings_use_radarr" class="ui toggle checkbox" data-enabled={{settings.general.getboolean('use_radarr')}}>
<input name="settings_general_use_radarr" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Enable Radarr Integration." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Path Mappings For TV Shows</div>
<div class="twelve wide column">
<div class="ui grid">
%import ast
%if settings.general.path_mappings is not None:
% path_substitutions = ast.literal_eval(settings.general.path_mappings)
%else:
% path_substitutions = []
%end
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Sonarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Root path to the directory Sonarr accesses." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="two wide center aligned column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Bazarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Path that Bazarr should use to access the same directory remotely." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
%for x in range(0, 5):
% path = []
% try:
% path = path_substitutions[x]
% except IndexError:
% path = ["", ""]
% end
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_sourcepath" type="text" value="{{path[0]}}">
</div>
</div>
<div class="center aligned column">
<i class="arrow circle right icon"></i>
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_destpath" type="text" value="{{path[1]}}">
</div>
</div>
</div>
%end
</div>
</div>
<div class="ui dividing header">Path Mappings For Movies</div>
<div class="twelve wide column">
<div class="ui grid">
%import ast
%if settings.general.path_mappings_movie is not None:
% path_substitutions_movie = ast.literal_eval(settings.general.path_mappings_movie)
%else:
% path_substitutions_movie = []
%end
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Radarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Root path to the directory Radarr accesses." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="two wide center aligned column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Bazarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Path that Bazarr should use to access the same directory remotely." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
%for x in range(0, 5):
% path_movie = []
% try:
% path_movie = path_substitutions_movie[x]
% except IndexError:
% path_movie = ["", ""]
% end
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_sourcepath_movie" type="text" value="{{path_movie[0]}}">
</div>
</div>
<div class="center aligned column">
<i class="arrow circle right icon"></i>
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_destpath_movie" type="text" value="{{path_movie[1]}}">
</div>
</div>
</div>
%end
</div>
</div>
<div class="ui dividing header">Post-processing</div>
<div class="twelve wide column">
<div class="ui orange message">
<p>Be aware that the execution of post-processing command will prevent the user interface from being accessible until completion, when downloading subtitles in interactive mode (meaning you'll see a loader during post-processing).</p>
</div>
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Use post-processing</label>
</div>
<div class="one wide column">
<div id="settings_use_postprocessing" class="ui toggle checkbox" data-postprocessing={{settings.general.getboolean('use_postprocessing')}}>
<input name="settings_general_use_postprocessing" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Enable the post-processing execution after downloading a subtitles." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row postprocessing">
<div class="right aligned four wide column">
<label>Post-processing command</label>
</div>
<div class="five wide column">
<div id="settings_general_postprocessing_cmd_div" class="ui fluid input">
<input name="settings_general_postprocessing_cmd" type="text" value="{{settings.general.postprocessing_cmd if settings.general.postprocessing_cmd != None else ''}}">
</div>
</div>
</div>
<div class="middle aligned row postprocessing">
<div class="right aligned four wide column">
<label>Variables you can use in your command (include the double curly brace):</label>
</div>
<div class="ten wide column">
<div class="ui list">
<div class="item">
<div class="header">&lbrace;&lbrace;directory&rbrace;&rbrace;</div>
The full path of the episode file parent directory.
</div>
<div class="item">
<div class="header">&lbrace;&lbrace;episode&rbrace;&rbrace;</div>
The full path of the episode file.
</div>
<div class="item">
<div class="header">&lbrace;&lbrace;episode_name&rbrace;&rbrace;</div>
The filename of the episode without parent directory or extension.
</div>
<div class="item">
<div class="header">&lbrace;&lbrace;subtitles&rbrace;&rbrace;</div>
The full path of the subtitles file.
</div>
<div class="item">
<div class="header">&lbrace;&lbrace;subtitles_language&rbrace;&rbrace;</div>
The language of the subtitles file.
</div>
<div class="item">
<div class="header">&lbrace;&lbrace;subtitles_language_code2&rbrace;&rbrace;</div>
The 2-letter ISO-639 language code of the subtitles language.
</div>
<div class="item">
<div class="header">&lbrace;&lbrace;subtitles_language_code3&rbrace;&rbrace;</div>
The 3-letter ISO-639 language code of the subtitles language.
</div>
</div>
</div>
</div>
</div>
</div>
<div id="div_update">
<div class="ui dividing header">Updates</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row" id="div_branch">
<div class="right aligned four wide column">
<label>Branch</label>
</div>
<div class="five wide column">
<select name="settings_general_branch" id="settings_branch" class="ui fluid selection dropdown">
<option value="">Branch</option>
<option value="master">master</option>
<option value="development">development</option>
</select>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Only select development branch if you want to live on the edge." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Automatic</label>
</div>
<div class="one wide column">
<div id="settings_automatic_div" class="ui toggle checkbox" data-automatic={{settings.general.getboolean('auto_update')}}>
<input name="settings_general_automatic" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Automatically download and install updates. You will still be able to install from System: Tasks" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Restart after update</label>
</div>
<div class="one wide column">
<div id="settings_update_restart" class="ui toggle checkbox"
data-update-restart={{settings.general.getboolean('update_restart')}}>
<input name="settings_general_update_restart" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Automatically restart after downloading and installing updates. You will still be able to restart manually"
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Analytics</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Enable</label>
</div>
<div class="one wide column">
<div id="settings_analytics_enabled" class="ui toggle checkbox" data-analytics={{settings.analytics.getboolean('enabled')}}>
<input name="settings_analytics_enabled" type="checkbox">
<label></label>
</div>
</div>
</div>
<div class="middle align row">
<div class="right aligned four wide column">
</div>
<div class="one wide column">
<i class="help circle large icon"></i>
</div>
<div class="ten wide column">
Send anonymous usage information, nothing that can identify you. This includes information on which providers you use, what languages you search for, Bazarr, Python, Sonarr, Radarr and what OS version you are using. We will use this information to prioritize features and bug fixes. Please, keep this enabled as this is the only way we have to better understand how you use Bazarr.
</div>
</div>
</div>
</div>
<script>
% from get_args import args
% if args.no_update:
$("#div_update").hide();
% elif args.release_update:
$("#div_branch").hide();
% end
% import sys
% if sys.platform.startswith('win'):
$("#chmod").hide();
$("#chmod_enabled").hide();
% end
if ($('#settings_automatic_div').data("automatic") === "True") {
$("#settings_automatic_div").checkbox('check');
} else {
$("#settings_automatic_div").checkbox('uncheck');
}
if ($('#settings_update_restart').data("update-restart") === "True") {
$("#settings_update_restart").checkbox('check');
} else {
$("#settings_update_restart").checkbox('uncheck');
}
if ($('#settings_debug').data("debug") === "True") {
$("#settings_debug").checkbox('check');
} else {
$("#settings_debug").checkbox('uncheck');
}
if ($('#settings_chmod_enabled').data("chmod") === "True") {
$("#settings_chmod_enabled").checkbox('check');
} else {
$("#settings_chmod_enabled").checkbox('uncheck');
}
if ($('#settings_analytics_enabled').data("analytics") === "True") {
$("#settings_analytics_enabled").checkbox('check');
} else {
$("#settings_analytics_enabled").checkbox('uncheck');
}
if ($('#settings_use_postprocessing').data("postprocessing") === "True") {
$("#settings_use_postprocessing").checkbox('check');
$("#settings_general_postprocessing_cmd_div").removeClass('disabled');
} else {
$("#settings_use_postprocessing").checkbox('uncheck');
$("#settings_general_postprocessing_cmd_div").addClass('disabled');
}
$("#settings_use_postprocessing").on('change', function(i, obj) {
if ($("#settings_use_postprocessing").checkbox('is checked')) {
$("#settings_general_postprocessing_cmd_div").removeClass('disabled');
} else {
$("#settings_general_postprocessing_cmd_div").addClass('disabled');
}
});
if ($('#settings_use_postprocessing').data("postprocessing") === "True") {
$('.postprocessing').show();
} else {
$('.postprocessing').hide();
}
$('#settings_use_postprocessing').checkbox({
onChecked: function() {
$('.postprocessing').show();
},
onUnchecked: function() {
$('.postprocessing').hide();
}
});
if ($('#settings_use_sonarr').data("enabled") === "True") {
$("#settings_use_sonarr").checkbox('check');
$("#sonarr_tab").removeClass('disabled');
} else {
$("#settings_use_sonarr").checkbox('uncheck');
$("#sonarr_tab").addClass('disabled');
}
$('#settings_use_sonarr').checkbox({
onChecked: function() {
$("#sonarr_tab").removeClass('disabled');
$('#sonarr_validated').checkbox('uncheck');
$('.form').form('validate form');
$('#loader').removeClass('active');
},
onUnchecked: function() {
$("#sonarr_tab").addClass('disabled');
}
});
if ($('#settings_use_radarr').data("enabled") === "True") {
$("#settings_use_radarr").checkbox('check');
$("#radarr_tab").removeClass('disabled');
} else {
$("#settings_use_radarr").checkbox('uncheck');
$("#radarr_tab").addClass('disabled');
}
$('#settings_use_radarr').checkbox({
onChecked: function() {
$("#radarr_tab").removeClass('disabled');
$('#radarr_validated').checkbox('uncheck');
$('.form').form('validate form');
$('#loader').removeClass('active');
},
onUnchecked: function() {
$("#radarr_tab").addClass('disabled');
}
});
if ($('#settings_chmod_enabled').data("chmod") === "True") {
$('#chmod').show();
} else {
$('#chmod').hide();
}
$('#settings_chmod_enabled').checkbox({
onChecked: function() {
$('#chmod').show();
},
onUnchecked: function() {
$('#chmod').hide();
}
});
if ($('#settings_auth_type').val() === "None") {
$('.auth_option').hide();
}
$('#settings_auth_type').dropdown('setting', 'onChange', function(){
if ($('#settings_auth_type').val() === "None") {
$('.auth_option').hide();
} else {
$('.auth_option').show();
}
});
// Load default value for Settings_auth_type
$('#settings_auth_type').dropdown('clear');
$('#settings_auth_type').dropdown('set selected','{{!settings.auth.type}}');
// Remove value from Password input when changing to Form login to prevent bad password saving
$("#settings_auth_type").on('change', function() {
if ($(this).val() === 'form'){
$('#settings_auth_password').val('');
} else {
$('#settings_auth_password').val('{{settings.auth.password}}');
}
});
$('#settings_loglevel').dropdown('clear');
$('#settings_loglevel').dropdown('set selected','{{!settings.general.getboolean('debug')}}');
$('#settings_page_size').dropdown('clear');
$('#settings_page_size').dropdown('set selected','{{!settings.general.page_size}}');
$('#settings_proxy_type').dropdown('clear');
$('#settings_proxy_type').dropdown('set selected','{{!settings.proxy.type}}');
$('#settings_branch').dropdown('clear');
$('#settings_branch').dropdown('set selected','{{!settings.general.branch}}');
$('#settings_auth_username').on('keyup', function() {
$('#settings_auth_password').val('');
$('.form').form('validate form');
$('#loader').removeClass('active');
});
</script>
<script>
function generate_apikey() {
var result = '';
var characters = 'abcdef0123456789';
var charactersLength = characters.length;
for ( var i = 0; i < 32; i++ ) {
result += characters.charAt(Math.floor(Math.random() * charactersLength));
}
$( "#settings_auth_apikey" ).val( result );
}
</script>

@ -0,0 +1,78 @@
<div class="ui dividing header">Notifications settings</div>
<div class="twelve wide column">
<div class="ui info message">
<p>Thanks to caronc for his work on <a href="https://github.com/caronc/apprise" target="_blank">apprise</a>,
which is based the notifications system.</p>
</div>
<div class="ui info message">
<p>Please follow instructions on his <a href="https://github.com/caronc/apprise/wiki" target="_blank">Wiki</a>
to configure your notification providers.</p>
</div>
<div class="ui grid">
{% for notifier in settings_notifier %}
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>{{ notifier['name'] }}</label>
</div>
<div class="one wide column">
<div id="settings_notifier_{{ notifier['name'] }}_enabled"
class="notifier_enabled ui toggle checkbox"
data-notifier-url-div="settings_notifier_{{ notifier['name'] }}_url_div"
data-enabled={{ notifier['enabled'] }}>
<input name="settings_notifier_{{ notifier['name'] }}_enabled" type="checkbox">
<label></label>
</div>
</div>
<div class="eight wide column">
<div class='field'>
<div id="settings_notifier_{{ notifier['name'] }}_url_div" class="ui fluid input">
<input name="settings_notifier_{{ notifier['name'] }}_url" type="text"
value="{{ notifier['url'] if notifier['url'] != None else '' }}">
<div class="test_notification ui blue button" data-notification="{{ notifier['url'] }}">Test
Notification
</div>
</div>
</div>
</div>
</div>
{% endfor %}
</div>
</div>
<script>
$('.test_notification').on('click', function () {
const url_field = $(this).prev().val();
const url_protocol = url_field.split(':')[0];
const url_string = url_field.split('://')[1];
$.ajax({
url: "{{base_url}}test_notification/" + url_protocol + "/" + encodeURIComponent(url_string),
beforeSend: function () {
$('#loader').addClass('active');
},
complete: function () {
$('#loader').removeClass('active');
},
cache: false
});
});
$('.notifier_enabled').each(function () {
if ($(this).data("enabled") === 1) {
$(this).checkbox('check');
$('[id=\"' + $(this).data("notifier-url-div") + '\"]').removeClass('disabled');
} else {
$(this).checkbox('uncheck');
$('[id=\"' + $(this).data("notifier-url-div") + '\"]').addClass('disabled');
}
});
$('.notifier_enabled').on('change', function () {
if ($(this).checkbox('is checked')) {
$('[id=\"' + $(this).data("notifier-url-div") + '\"]').removeClass('disabled');
} else {
$('[id=\"' + $(this).data("notifier-url-div") + '\"]').addClass('disabled');
}
});
</script>

@ -1,72 +0,0 @@
<div class="ui dividing header">Notifications settings</div>
<div class="twelve wide column">
<div class="ui info message">
<p>Thanks to caronc for his work on <a href="https://github.com/caronc/apprise" target="_blank">apprise</a>, which is based the notifications system.</p>
</div>
<div class="ui info message">
<p>Please follow instructions on his <a href="https://github.com/caronc/apprise/wiki" target="_blank">Wiki</a> to configure your notification providers.</p>
</div>
<div class="ui grid">
%for notifier in settings_notifier:
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>{{notifier['name']}}</label>
</div>
<div class="one wide column">
<div id="settings_notifier_{{notifier['name']}}_enabled" class="notifier_enabled ui toggle checkbox" data-notifier-url-div="settings_notifier_{{notifier['name']}}_url_div" data-enabled={{notifier['enabled']}}>
<input name="settings_notifier_{{notifier['name']}}_enabled" type="checkbox">
<label></label>
</div>
</div>
<div class="eight wide column">
<div class='field'>
<div id="settings_notifier_{{notifier['name']}}_url_div" class="ui fluid input">
<input name="settings_notifier_{{notifier['name']}}_url" type="text" value="{{notifier['url'] if notifier['url'] != None else ''}}">
<div class="test_notification ui blue button" data-notification="{{notifier['url']}}">Test Notification</div>
</div>
</div>
</div>
</div>
%end
</div>
</div>
<script>
$('.test_notification').on('click', function() {
const url_field = $(this).prev().val();
const url_protocol = url_field.split(':')[0];
const url_string = url_field.split('://')[1];
$.ajax({
url: "{{base_url}}test_notification/" + url_protocol + "/" + encodeURIComponent(url_string),
beforeSend: function () {
$('#loader').addClass('active');
},
complete: function () {
$('#loader').removeClass('active');
},
cache: false
});
});
$('.notifier_enabled').each(function() {
if ($(this).data("enabled") === 1) {
$(this).checkbox('check');
$('[id=\"' + $(this).data("notifier-url-div") + '\"]').removeClass('disabled');
} else {
$(this).checkbox('uncheck');
$('[id=\"' + $(this).data("notifier-url-div") + '\"]').addClass('disabled');
}
});
$('.notifier_enabled').on('change', function() {
if ($(this).checkbox('is checked')) {
$('[id=\"' + $(this).data("notifier-url-div") + '\"]').removeClass('disabled');
} else {
$('[id=\"' + $(this).data("notifier-url-div") + '\"]').addClass('disabled');
}
});
</script>

@ -187,13 +187,13 @@
});
$('#settings_radarr_sync').dropdown('clear');
$('#settings_radarr_sync').dropdown('set selected','{{!settings.radarr.full_update}}');
$('#settings_radarr_sync').dropdown('set selected','{{settings.radarr.full_update|safe}}');
$('#settings_radarr_sync').dropdown('refresh');
$('#settings_radarr_sync_day').dropdown('clear');
$('#settings_radarr_sync_day').dropdown('set selected','{{!settings.radarr.full_update_day}}');
$('#settings_radarr_sync_day').dropdown('set selected','{{settings.radarr.full_update_day|safe}}');
$('#settings_radarr_sync_day').dropdown('refresh');
$('#settings_radarr_sync_hour').dropdown('clear');
$('#settings_radarr_sync_hour').dropdown('set selected','{{!settings.radarr.full_update_hour}}');
$('#settings_radarr_sync_hour').dropdown('set selected','{{settings.radarr.full_update_hour|safe}}');
$('#settings_radarr_sync_hour').dropdown('refresh');
$('#radarr_validate').on('click', function() {

@ -187,13 +187,13 @@
});
$('#settings_sonarr_sync').dropdown('clear');
$('#settings_sonarr_sync').dropdown('set selected','{{!settings.sonarr.full_update}}');
$('#settings_sonarr_sync').dropdown('set selected','{{settings.sonarr.full_update|safe}}');
$('#settings_sonarr_sync').dropdown('refresh');
$('#settings_sonarr_sync_day').dropdown('clear');
$('#settings_sonarr_sync_day').dropdown('set selected','{{!settings.sonarr.full_update_day}}');
$('#settings_sonarr_sync_day').dropdown('set selected','{{settings.sonarr.full_update_day|safe}}');
$('#settings_sonarr_sync_day').dropdown('refresh');
$('#settings_sonarr_sync_hour').dropdown('clear');
$('#settings_sonarr_sync_hour').dropdown('set selected','{{!settings.sonarr.full_update_hour}}');
$('#settings_sonarr_sync_hour').dropdown('set selected','{{settings.sonarr.full_update_hour|safe}}');
$('#settings_sonarr_sync_hour').dropdown('refresh');
$('#sonarr_validate').on('click', function() {

@ -0,0 +1,876 @@
<div class="ui dividing header">Subtitle Options</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Search for missing Subtitles frequency (in hours)</label>
</div>
<div class="five wide column">
<div class='field'>
<select name="settings_general_wanted_search_frequency"
id="settings_general_wanted_search_frequency" class="ui fluid selection dropdown">
% for i in [3,6,12,24]:
<option value="{{ i }}">{{ i }}</option>
%end
</select>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Use Scene name when available</label>
</div>
<div class="one wide column">
<div id="settings_scenename" class="ui toggle checkbox"
data-scenename={{ settings.general.getboolean('use_scenename') }}>
<input name="settings_general_scenename" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Use the Scene name from Sonarr/Radarr if available to circumvent usage of episode file renaming."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Minimum Score For Episodes</label>
</div>
<div class="two wide column">
<div class='field'>
<div class="ui input">
<input name="settings_general_minimum_score" type="number" min="0" max="100" step="1"
onkeydown="return false" value="{{ settings.general.minimum_score }}">
</div>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Minimum score for an Episodes Subtitle to be downloaded (0 to 100)."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Minimum Score For Movies</label>
</div>
<div class="two wide column">
<div class='field'>
<div class="ui input">
<input name="settings_general_minimum_score_movies" type="number" min="0" max="100" step="1"
onkeydown="return false" value="{{ settings.general.minimum_score_movie }}">
</div>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Minimum score for a Movie Subtitle to be downloaded (0 to 100)."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Subtitle Folder</label>
</div>
<div class="five wide column">
<select name="settings_subfolder" id="settings_subfolder"
class="ui fluid selection dropdown">
<option value="current">Alongside Media File</option>
<option value="relative">Relative Path To Media File</option>
<option value="absolute">Absolute Path</option>
</select>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip='Choose the folder you wish to store/read the Subtitles'
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row subfolder">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Custom Subtitle Folder</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_subfolder_custom" name="settings_subfolder_custom"
type="text" value="{{ settings.general.subfolder_custom }}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip='Choose your own folder for Subtitles' data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Upgrade Previously Downloaded Subtitles</label>
</div>
<div class="one wide column">
<div id="settings_upgrade_subs" class="ui toggle checkbox"
data-upgrade={{ settings.general.getboolean('upgrade_subs') }}>
<input name="settings_upgrade_subs" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip='Schedule a task to upgrade Subtitles previously downloaded by Bazarr.'
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row upgrade_subs">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Upgrade Frequency (In Hours)</label>
</div>
<div class="five wide column">
<div class='field'>
<select name="settings_upgrade_subs_frequency" id="settings_upgrade_subs_frequency"
class="ui fluid selection dropdown">
% for i in [1,3,6,12,24]:
<option value="{{ i }}">{{ i }}</option>
%end
</select>
</div>
</div>
</div>
<div class="middle aligned row upgrade_subs">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Number of days to go back in history to upgrade Subtitles (up to 30)</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_days_to_upgrade_subs" name="settings_days_to_upgrade_subs"
type="text" value="{{ settings.general.days_to_upgrade_subs }}">
</div>
</div>
</div>
</div>
<div class="middle aligned row upgrade_subs">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Upgrade Manually Downloaded Subtitles</label>
</div>
<div class="one wide column">
<div id="settings_upgrade_manual" class="ui toggle checkbox"
data-upgrade-manual={{ settings.general.getboolean('upgrade_manual') }}>
<input name="settings_upgrade_manual" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip='Enable or disable upgrade of manually searched and downloaded Subtitles.'
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Use Embedded Subtitles</label>
</div>
<div class="one wide column">
<div id="settings_embedded" class="ui toggle checkbox"
data-embedded={{ settings.general.getboolean('use_embedded_subs') }}>
<input name="settings_general_embedded" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Use embedded Subtitles in media files when determining missing ones."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Ignore Embedded PGS Subtitles</label>
</div>
<div class="one wide column">
<div id="settings_ignore_pgs" class="ui toggle checkbox"
data-ignorepgs={{ settings.general.getboolean('ignore_pgs_subs') }}>
<input name="settings_general_ignore_pgs" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Ignores PGS Subtitles in Embedded Subtitles detection. Only relevant if 'Use embedded Subtitles' is enabled."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Adaptive Searching</label>
</div>
<div class="one wide column">
<div id="settings_adaptive_searching" class="ui toggle checkbox"
data-adaptive={{ settings.general.getboolean('adaptive_searching') }}>
<input name="settings_general_adaptive_searching" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="When searching for Subtitles, Bazarr will search less frequently to limit call to providers."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Search Enabled Providers Simultaneously</label>
</div>
<div class="one wide column">
<div id="settings_multithreading" class="ui toggle checkbox"
data-multithreading={{ settings.general.getboolean('multithreading') }}>
<input name="settings_general_multithreading" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Search multiple providers at once (Don't choose this on low powered devices)"
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Encode Subtitles To UTF8</label>
</div>
<div class="one wide column">
<div id="settings_utf8_encode" class="ui toggle checkbox"
data-utf8encode={{ settings.general.getboolean('utf8_encode') }}>
<input name="settings_general_utf8_encode" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Re-encode downloaded Subtitles to UTF8. Should be left enabled in most case."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Anti-Captcha Options</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Provider</label>
</div>
<div class="five wide column">
<select name="settings_anti_captcha_provider" id="settings_anti_captcha_provider"
class="ui fluid selection dropdown">
<option value="None">None</option>
<option value="anti-captcha">Anti-Captcha</option>
<option value="death-by-captcha">Death by Captcha</option>
</select>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip='Choose the Anti-Captcha provider you want to use.'
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row anticaptcha">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Provider Website</label>
</div>
<div class="five wide column">
<a href="http://getcaptchasolution.com/eixxo1rsnw" target="_blank">Anti-Captcha.com</a>
</div>
</div>
<div class="middle aligned row anticaptcha">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Account Key</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_anti_captcha_key" name="settings_anti_captcha_key"
type="text" value="{{ settings.anticaptcha.anti_captcha_key }}">
</div>
</div>
</div>
</div>
<div class="middle aligned row deathbycaptcha">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Provider Website</label>
</div>
<div class="five wide column">
<a href="https://www.deathbycaptcha.com" target="_blank">DeathByCaptcha.com</a>
</div>
</div>
<div class="middle aligned row deathbycaptcha">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Username</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_death_by_captcha_username" name="settings_death_by_captcha_username"
type="text" value="{{ settings.deathbycaptcha.username }}">
</div>
</div>
</div>
</div>
<div class="middle aligned row deathbycaptcha">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Password</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_death_by_captcha_password" name="settings_death_by_captcha_password"
type="password" value="{{ settings.deathbycaptcha.password }}">
</div>
</div>
</div>
</div>
</div>
</div>
% include('providers.tpl')
<div class="ui dividing header">Subtitles languages</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Single Language</label>
</div>
<div class="one wide column">
<div id="settings_single_language" class="ui toggle checkbox"
data-single-language={{ settings.general.getboolean('single_language') }}>
<input name="settings_general_single_language" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Download a single Subtitles file without adding the language code to the filename."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Enabled Languages</label>
</div>
<div class="eleven wide column">
<div class='field'>
<select name="settings_subliminal_languages" id="settings_languages" multiple=""
class="ui fluid search selection dropdown">
<option value="">Languages</option>
{% set enabled_languages = [] %}
{%for language in settings_languages%}
<option value="{{ language['code2'] }}">{{ language['name'] }}</option>
{%if language['enabled'] == True%}
{{ enabled_languages.append(str(language['code2']))}}
{%endif%}
{%endfor%}
</select>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Series Default Settings</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Default Enabled</label>
</div>
<div class="one wide column">
<div class="nine wide column">
<div id="settings_serie_default_enabled_div" class="ui toggle checkbox"
data-enabled="{{ settings.general.getboolean('serie_default_enabled') }}">
<input name="settings_serie_default_enabled" id="settings_serie_default_enabled"
type="checkbox">
<label></label>
</div>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Apply only to series added to Bazarr after enabling this option."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Languages</label>
</div>
<div class="eleven wide column">
<div class='field'>
<select name="settings_serie_default_languages" id="settings_serie_default_languages" multiple=""
class="ui fluid search selection dropdown">
%if settings.general.getboolean('single_language') is False:
<option value="">Languages</option>
%else:
<option value="None">None</option>
%end
</select>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Hearing-Impaired</label>
</div>
<div class="eleven wide column">
<div class="nine wide column">
<div id="settings_serie_default_hi_div" class="ui toggle checkbox"
data-hi="{{ settings.general.getboolean('serie_default_hi') }}">
<input name="settings_serie_default_hi" id="settings_serie_default_hi" type="checkbox">
<label></label>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Forced</label>
</div>
<div class="eleven wide column">
<div class='field'>
<select name="settings_serie_default_forced" id="settings_serie_default_forced"
class="ui fluid selection dropdown">
<option value="False">False</option>
<option value="True">True</option>
<option value="Both">Both</option>
</select>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Movie Default Settings</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Default Enabled</label>
</div>
<div class="one wide column">
<div class="nine wide column">
<div id="settings_movie_default_enabled_div" class="ui toggle checkbox"
data-enabled="{{ settings.general.getboolean('movie_default_enabled') }}">
<input name="settings_movie_default_enabled" id="settings_movie_default_enabled"
type="checkbox">
<label></label>
</div>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Apply only to Movies added to Bazarr after enabling this option."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div id="movie_default_languages_label" class="right aligned four wide column">
<label>Languages</label>
</div>
<div class="eleven wide column">
<div class='field'>
<select name="settings_movie_default_languages" id="settings_movie_default_languages" multiple=""
class="ui fluid search selection dropdown">
%if settings.general.getboolean('single_language') is False:
<option value="">Languages</option>
%else:
<option value="None">None</option>
%end
</select>
</div>
</div>
</div>
<div class="middle aligned row">
<div id="movie_default_hi_label" class="right aligned four wide column">
<label>Hearing-Impaired</label>
</div>
<div class="eleven wide column">
<div class="nine wide column">
<div id="settings_movie_default_hi_div" class="ui toggle checkbox"
data-hi="{{ settings.general.getboolean('movie_default_hi') }}">
<input name="settings_movie_default_hi" id="settings_movie_default_hi" type="checkbox">
<label></label>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div id="movie_default_forced_label" class="right aligned four wide column">
<label>Forced</label>
</div>
<div class="eleven wide column">
<div class='field'>
<select name="settings_movie_default_forced" id="settings_movie_default_forced"
class="ui fluid selection dropdown">
<option value="False">False</option>
<option value="True">True</option>
<option value="Both">Both</option>
</select>
</div>
</div>
</div>
</div>
</div>
<script>
$('#settings_general_wanted_search_frequency').dropdown('clear');
$('#settings_general_wanted_search_frequency').dropdown('set selected', '{{settings.general.wanted_search_frequency|safe}}');
$('#settings_general_wanted_search_frequency').dropdown('refresh');
if ($('#settings_single_language').data("single-language") === "True") {
$("#settings_single_language").checkbox('check');
} else {
$("#settings_single_language").checkbox('uncheck');
}
if ($('#settings_scenename').data("scenename") === "True") {
$("#settings_scenename").checkbox('check');
} else {
$("#settings_scenename").checkbox('uncheck');
}
if ($('#settings_upgrade_subs').data("upgrade") === "True") {
$("#settings_upgrade_subs").checkbox('check');
} else {
$("#settings_upgrade_subs").checkbox('uncheck');
}
$('#settings_upgrade_subs_frequency').dropdown('clear');
$('#settings_upgrade_subs_frequency').dropdown('set selected', '{{settings.general.upgrade_frequency|safe}}');
$('#settings_upgrade_subs_frequency').dropdown('refresh');
if ($('#settings_upgrade_manual').data("upgrade-manual") === "True") {
$("#settings_upgrade_manual").checkbox('check');
} else {
$("#settings_upgrade_manual").checkbox('uncheck');
}
if ($('#settings_embedded').data("embedded") === "True") {
$("#settings_embedded").checkbox('check');
} else {
$("#settings_embedded").checkbox('uncheck');
}
if ($('#settings_ignore_pgs').data("ignorepgs") === "True") {
$("#settings_ignore_pgs").checkbox('check');
} else {
$("#settings_ignore_pgs").checkbox('uncheck');
}
if ($('#settings_adaptive_searching').data("adaptive") === "True") {
$("#settings_adaptive_searching").checkbox('check');
} else {
$("#settings_adaptive_searching").checkbox('uncheck');
}
if ($('#settings_multithreading').data("multithreading") === "True") {
$("#settings_multithreading").checkbox('check');
} else {
$("#settings_multithreading").checkbox('uncheck');
}
if ($('#settings_utf8_encode').data("utf8encode") === "True") {
$("#settings_utf8_encode").checkbox('check');
} else {
$("#settings_utf8_encode").checkbox('uncheck');
}
if (($('#settings_subfolder').val() !== "relative") && ($('#settings_subfolder').val() !== "absolute")) {
$('.subfolder').hide();
}
$('#settings_subfolder').dropdown('setting', 'onChange', function () {
if (($('#settings_subfolder').val() !== "relative") && ($('#settings_subfolder').val() !== "absolute")) {
$('.subfolder').hide();
} else {
$('.subfolder').show();
}
});
if ($('#settings_anti_captcha_provider').val() === "None") {
$('.anticaptcha').hide();
$('.deathbycaptcha').hide();
} else if ($('#settings_anti_captcha_provider').val() === "anti-captcha") {
$('.anticaptcha').show();
$('.deathbycaptcha').hide();
} else if ($('#settings_anti_captcha_provider').val() === "death-by-cCaptcha") {
$('.deathbycaptcha').show();
$('.anticaptcha').hide();
}
$('#settings_anti_captcha_provider').dropdown('setting', 'onChange', function () {
if ($('#settings_anti_captcha_provider').val() === "None") {
$('.anticaptcha').hide();
$('.deathbycaptcha').hide();
} else if ($('#settings_anti_captcha_provider').val() === "anti-captcha") {
$('.anticaptcha').show();
$('.deathbycaptcha').hide();
} else if ($('#settings_anti_captcha_provider').val() === "death-by-captcha") {
$('.deathbycaptcha').show();
$('.anticaptcha').hide();
}
});
if ($('#settings_upgrade_subs').data("upgrade") === "True") {
$('.upgrade_subs').show();
} else {
$('.upgrade_subs').hide();
}
$('#settings_upgrade_subs').checkbox({
onChecked: function () {
$('.upgrade_subs').show();
},
onUnchecked: function () {
$('.upgrade_subs').hide();
}
});
$('#settings_languages').dropdown('setting', 'onAdd', function (val, txt) {
$("#settings_serie_default_languages").append(
$("<option></option>").attr("value", val).text(txt)
);
$("#settings_movie_default_languages").append(
$("<option></option>").attr("value", val).text(txt)
)
});
$('#settings_languages').dropdown('setting', 'onRemove', function (val, txt) {
$("#settings_serie_default_languages").dropdown('remove selected', val);
$("#settings_serie_default_languages option[value='" + val + "']").remove();
$("#settings_movie_default_languages").dropdown('remove selected', val);
$("#settings_movie_default_languages option[value='" + val + "']").remove();
});
if ($('#settings_serie_default_enabled_div').data("enabled") === "True") {
$("#settings_serie_default_enabled_div").checkbox('check');
} else {
$("#settings_serie_default_enabled_div").checkbox('uncheck');
}
if ($('#settings_serie_default_enabled_div').data("enabled") === "True") {
$("#settings_serie_default_languages").removeClass('disabled');
$("#settings_serie_default_hi_div").removeClass('disabled');
$("#settings_serie_default_forced_div").removeClass('disabled');
} else {
$("#settings_serie_default_languages").addClass('disabled');
$("#settings_serie_default_hi_div").addClass('disabled');
$("#settings_serie_default_forced_div").addClass('disabled');
}
$('#settings_serie_default_enabled_div').checkbox({
onChecked: function () {
$("#settings_serie_default_languages").parent().removeClass('disabled');
$("#settings_serie_default_hi_div").removeClass('disabled');
$("#settings_serie_default_forced").parent().removeClass('disabled');
},
onUnchecked: function () {
$("#settings_serie_default_languages").parent().addClass('disabled');
$("#settings_serie_default_hi_div").addClass('disabled');
$("#settings_serie_default_forced").parent().addClass('disabled');
}
});
if ($('#settings_serie_default_hi_div').data("hi") === "True") {
$("#settings_serie_default_hi_div").checkbox('check');
} else {
$("#settings_serie_default_hi_div").checkbox('uncheck');
}
if ($('#settings_movie_default_enabled_div').data("enabled") === "True") {
$("#settings_movie_default_enabled_div").checkbox('check');
} else {
$("#settings_movie_default_enabled_div").checkbox('uncheck');
}
if ($('#settings_movie_default_enabled_div').data("enabled") === "True") {
$("#settings_movie_default_languages").removeClass('disabled');
$("#settings_movie_default_hi_div").removeClass('disabled');
$("#settings_movie_default_forced_div").removeClass('disabled');
} else {
$("#settings_movie_default_languages").addClass('disabled');
$("#settings_movie_default_hi_div").addClass('disabled');
$("#settings_movie_default_forced_div").addClass('disabled');
}
$('#settings_movie_default_enabled_div').checkbox({
onChecked: function () {
$("#settings_movie_default_languages").parent().removeClass('disabled');
$("#settings_movie_default_hi_div").removeClass('disabled');
$("#settings_movie_default_forced").parent().removeClass('disabled');
},
onUnchecked: function () {
$("#settings_movie_default_languages").parent().addClass('disabled');
$("#settings_movie_default_hi_div").addClass('disabled');
$("#settings_movie_default_forced").parent().addClass('disabled');
}
});
if ($('#settings_movie_default_hi_div').data("hi") === "True") {
$("#settings_movie_default_hi_div").checkbox('check');
} else {
$("#settings_movie_default_hi_div").checkbox('uncheck');
}
if ($("#settings_single_language").checkbox('is checked')) {
$("#settings_serie_default_languages").parent().removeClass('multiple');
$("#settings_serie_default_languages").removeAttr('multiple');
$("#settings_movie_default_languages").parent().removeClass('multiple');
$("#settings_movie_default_languages").removeAttr('multiple');
} else {
$("#settings_serie_default_languages").parent().addClass('multiple');
$("#settings_serie_default_languages").attr('multiple');
$("#settings_movie_default_languages").parent().addClass('multiple');
$("#settings_movie_default_languages").attr('multiple');
}
$("#settings_single_language").on('change', function () {
if ($("#settings_single_language").checkbox('is checked')) {
$("#settings_serie_default_languages").dropdown('clear');
$("#settings_movie_default_languages").dropdown('clear');
$("#settings_serie_default_languages").prepend("<option value='None' selected='selected'>None</option>");
$("#settings_movie_default_languages").prepend("<option value='None' selected='selected'>None</option>");
$("#settings_serie_default_languages").parent().removeClass('multiple');
$("#settings_serie_default_languages").removeAttr('multiple');
$("#settings_movie_default_languages").parent().removeClass('multiple');
$("#settings_movie_default_languages").removeAttr('multiple');
} else {
$("#settings_serie_default_languages").dropdown('clear');
$("#settings_movie_default_languages").dropdown('clear');
$("#settings_serie_default_languages option[value='None']").remove();
$("#settings_movie_default_languages option[value='None']").remove();
$("#settings_serie_default_languages").parent().addClass('multiple');
$("#settings_serie_default_languages").attr('multiple');
$("#settings_movie_default_languages").parent().addClass('multiple');
$("#settings_movie_default_languages").attr('multiple');
}
});
$('#settings_subfolder').dropdown('clear');
$('#settings_subfolder').dropdown('set selected', '{{settings.general.subfolder|safe}}');
$('#settings_anti_captcha_provider').dropdown('clear');
$('#settings_anti_captcha_provider').dropdown('set selected', '{{settings.general.anti_captcha_provider|safe}}');
$('#settings_languages').dropdown('clear');
$('#settings_languages').dropdown('set selected', {{enabled_languages|safe}});
{%if settings.general.serie_default_language != 'None'%}
$('#settings_serie_default_languages').dropdown('set selected', {{settings.general.serie_default_language|safe}});
{%endif%}
{%if settings.general.movie_default_language != 'None'%}
$('#settings_movie_default_languages').dropdown('set selected', {{settings.general.movie_default_language|safe}});
{%endif%}
$('#settings_serie_default_forced').dropdown('set selected', '{{settings.general.serie_default_forced|safe}}');
$('#settings_movie_default_forced').dropdown('set selected', '{{settings.general.movie_default_forced|safe}}');
$('#settings_languages').dropdown('setting', 'onChange', function () {
$('.form').form('validate field', 'settings_subliminal_languages');
});
</script>

@ -1,831 +0,0 @@
<div class="ui dividing header">Subtitle Options</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Search for missing Subtitles frequency (in hours)</label>
</div>
<div class="five wide column">
<div class='field'>
<select name="settings_general_wanted_search_frequency" id="settings_general_wanted_search_frequency" class="ui fluid selection dropdown">
% for i in [3,6,12,24]:
<option value="{{i}}">{{i}}</option>
%end
</select>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Use Scene name when available</label>
</div>
<div class="one wide column">
<div id="settings_scenename" class="ui toggle checkbox" data-scenename={{settings.general.getboolean('use_scenename')}}>
<input name="settings_general_scenename" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Use the Scene name from Sonarr/Radarr if available to circumvent usage of episode file renaming." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Minimum Score For Episodes</label>
</div>
<div class="two wide column">
<div class='field'>
<div class="ui input">
<input name="settings_general_minimum_score" type="number" min="0" max="100" step="1" onkeydown="return false" value="{{settings.general.minimum_score}}">
</div>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Minimum score for an Episodes Subtitle to be downloaded (0 to 100)." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Minimum Score For Movies</label>
</div>
<div class="two wide column">
<div class='field'>
<div class="ui input">
<input name="settings_general_minimum_score_movies" type="number" min="0" max="100" step="1" onkeydown="return false" value="{{settings.general.minimum_score_movie}}">
</div>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Minimum score for a Movie Subtitle to be downloaded (0 to 100)." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Subtitle Folder</label>
</div>
<div class="five wide column">
<select name="settings_subfolder" id="settings_subfolder"
class="ui fluid selection dropdown">
<option value="current">Alongside Media File</option>
<option value="relative">Relative Path To Media File</option>
<option value="absolute">Absolute Path</option>
</select>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip='Choose the folder you wish to store/read the Subtitles'
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row subfolder">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Custom Subtitle Folder</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_subfolder_custom" name="settings_subfolder_custom"
type="text" value="{{ settings.general.subfolder_custom }}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip='Choose your own folder for Subtitles' data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Upgrade Previously Downloaded Subtitles</label>
</div>
<div class="one wide column">
<div id="settings_upgrade_subs" class="ui toggle checkbox" data-upgrade={{settings.general.getboolean('upgrade_subs')}}>
<input name="settings_upgrade_subs" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip='Schedule a task to upgrade Subtitles previously downloaded by Bazarr.'
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row upgrade_subs">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Upgrade Frequency (In Hours)</label>
</div>
<div class="five wide column">
<div class='field'>
<select name="settings_upgrade_subs_frequency" id="settings_upgrade_subs_frequency" class="ui fluid selection dropdown">
% for i in [1,3,6,12,24]:
<option value="{{i}}">{{i}}</option>
%end
</select>
</div>
</div>
</div>
<div class="middle aligned row upgrade_subs">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Number of days to go back in history to upgrade Subtitles (up to 30)</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_days_to_upgrade_subs" name="settings_days_to_upgrade_subs"
type="text" value="{{ settings.general.days_to_upgrade_subs }}">
</div>
</div>
</div>
</div>
<div class="middle aligned row upgrade_subs">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Upgrade Manually Downloaded Subtitles</label>
</div>
<div class="one wide column">
<div id="settings_upgrade_manual" class="ui toggle checkbox" data-upgrade-manual={{settings.general.getboolean('upgrade_manual')}}>
<input name="settings_upgrade_manual" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip='Enable or disable upgrade of manually searched and downloaded Subtitles.'
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Use Embedded Subtitles</label>
</div>
<div class="one wide column">
<div id="settings_embedded" class="ui toggle checkbox" data-embedded={{settings.general.getboolean('use_embedded_subs')}}>
<input name="settings_general_embedded" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Use embedded Subtitles in media files when determining missing ones." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Ignore Embedded PGS Subtitles</label>
</div>
<div class="one wide column">
<div id="settings_ignore_pgs" class="ui toggle checkbox" data-ignorepgs={{settings.general.getboolean('ignore_pgs_subs')}}>
<input name="settings_general_ignore_pgs" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Ignores PGS Subtitles in Embedded Subtitles detection. Only relevant if 'Use embedded Subtitles' is enabled." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Adaptive Searching</label>
</div>
<div class="one wide column">
<div id="settings_adaptive_searching" class="ui toggle checkbox" data-adaptive={{settings.general.getboolean('adaptive_searching')}}>
<input name="settings_general_adaptive_searching" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="When searching for Subtitles, Bazarr will search less frequently to limit call to providers." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Search Enabled Providers Simultaneously</label>
</div>
<div class="one wide column">
<div id="settings_multithreading" class="ui toggle checkbox"
data-multithreading={{ settings.general.getboolean('multithreading') }}>
<input name="settings_general_multithreading" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Search multiple providers at once (Don't choose this on low powered devices)" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Encode Subtitles To UTF8</label>
</div>
<div class="one wide column">
<div id="settings_utf8_encode" class="ui toggle checkbox" data-utf8encode={{ settings.general.getboolean('utf8_encode') }}>
<input name="settings_general_utf8_encode" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Re-encode downloaded Subtitles to UTF8. Should be left enabled in most case." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Anti-Captcha Options</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Provider</label>
</div>
<div class="five wide column">
<select name="settings_anti_captcha_provider" id="settings_anti_captcha_provider" class="ui fluid selection dropdown">
<option value="None">None</option>
<option value="anti-captcha">Anti-Captcha</option>
<option value="death-by-captcha">Death by Captcha</option>
</select>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip='Choose the Anti-Captcha provider you want to use.'
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row anticaptcha">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Provider Website</label>
</div>
<div class="five wide column">
<a href="http://getcaptchasolution.com/eixxo1rsnw" target="_blank">Anti-Captcha.com</a>
</div>
</div>
<div class="middle aligned row anticaptcha">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Account Key</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_anti_captcha_key" name="settings_anti_captcha_key"
type="text" value="{{ settings.anticaptcha.anti_captcha_key }}">
</div>
</div>
</div>
</div>
<div class="middle aligned row deathbycaptcha">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Provider Website</label>
</div>
<div class="five wide column">
<a href="https://www.deathbycaptcha.com" target="_blank">DeathByCaptcha.com</a>
</div>
</div>
<div class="middle aligned row deathbycaptcha">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Username</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_death_by_captcha_username" name="settings_death_by_captcha_username"
type="text" value="{{ settings.deathbycaptcha.username }}">
</div>
</div>
</div>
</div>
<div class="middle aligned row deathbycaptcha">
<div class="two wide column"></div>
<div class="right aligned four wide column">
<label>Password</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input id="settings_death_by_captcha_password" name="settings_death_by_captcha_password"
type="password" value="{{ settings.deathbycaptcha.password }}">
</div>
</div>
</div>
</div>
</div>
</div>
% include('providers.tpl')
<div class="ui dividing header">Subtitles languages</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Single Language</label>
</div>
<div class="one wide column">
<div id="settings_single_language" class="ui toggle checkbox" data-single-language={{settings.general.getboolean('single_language')}}>
<input name="settings_general_single_language" type="checkbox">
<label></label>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Download a single Subtitles file without adding the language code to the filename." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Enabled Languages</label>
</div>
<div class="eleven wide column">
<div class='field'>
<select name="settings_subliminal_languages" id="settings_languages" multiple="" class="ui fluid search selection dropdown">
<option value="">Languages</option>
%enabled_languages = []
%for language in settings_languages:
<option value="{{language['code2']}}">{{language['name']}}</option>
%if language['enabled'] == True:
% enabled_languages.append(str(language['code2']))
%end
%end
</select>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Series Default Settings</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Default Enabled</label>
</div>
<div class="one wide column">
<div class="nine wide column">
<div id="settings_serie_default_enabled_div" class="ui toggle checkbox" data-enabled="{{settings.general.getboolean('serie_default_enabled')}}">
<input name="settings_serie_default_enabled" id="settings_serie_default_enabled" type="checkbox">
<label></label>
</div>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Apply only to series added to Bazarr after enabling this option." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Languages</label>
</div>
<div class="eleven wide column">
<div class='field'>
<select name="settings_serie_default_languages" id="settings_serie_default_languages" multiple="" class="ui fluid search selection dropdown">
%if settings.general.getboolean('single_language') is False:
<option value="">Languages</option>
%else:
<option value="None">None</option>
%end
</select>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Hearing-Impaired</label>
</div>
<div class="eleven wide column">
<div class="nine wide column">
<div id="settings_serie_default_hi_div" class="ui toggle checkbox" data-hi="{{settings.general.getboolean('serie_default_hi')}}">
<input name="settings_serie_default_hi" id="settings_serie_default_hi" type="checkbox">
<label></label>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Forced</label>
</div>
<div class="eleven wide column">
<div class='field'>
<select name="settings_serie_default_forced" id="settings_serie_default_forced" class="ui fluid selection dropdown">
<option value="False">False</option>
<option value="True">True</option>
<option value="Both">Both</option>
</select>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Movie Default Settings</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Default Enabled</label>
</div>
<div class="one wide column">
<div class="nine wide column">
<div id="settings_movie_default_enabled_div" class="ui toggle checkbox" data-enabled="{{settings.general.getboolean('movie_default_enabled')}}">
<input name="settings_movie_default_enabled" id="settings_movie_default_enabled" type="checkbox">
<label></label>
</div>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Apply only to Movies added to Bazarr after enabling this option." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div id="movie_default_languages_label" class="right aligned four wide column">
<label>Languages</label>
</div>
<div class="eleven wide column">
<div class='field'>
<select name="settings_movie_default_languages" id="settings_movie_default_languages" multiple="" class="ui fluid search selection dropdown">
%if settings.general.getboolean('single_language') is False:
<option value="">Languages</option>
%else:
<option value="None">None</option>
%end
</select>
</div>
</div>
</div>
<div class="middle aligned row">
<div id="movie_default_hi_label" class="right aligned four wide column">
<label>Hearing-Impaired</label>
</div>
<div class="eleven wide column">
<div class="nine wide column">
<div id="settings_movie_default_hi_div" class="ui toggle checkbox" data-hi="{{settings.general.getboolean('movie_default_hi')}}">
<input name="settings_movie_default_hi" id="settings_movie_default_hi" type="checkbox">
<label></label>
</div>
</div>
</div>
</div>
<div class="middle aligned row">
<div id="movie_default_forced_label" class="right aligned four wide column">
<label>Forced</label>
</div>
<div class="eleven wide column">
<div class='field'>
<select name="settings_movie_default_forced" id="settings_movie_default_forced" class="ui fluid selection dropdown">
<option value="False">False</option>
<option value="True">True</option>
<option value="Both">Both</option>
</select>
</div>
</div>
</div>
</div>
</div>
<script>
$('#settings_general_wanted_search_frequency').dropdown('clear');
$('#settings_general_wanted_search_frequency').dropdown('set selected','{{!settings.general.wanted_search_frequency}}');
$('#settings_general_wanted_search_frequency').dropdown('refresh');
if ($('#settings_single_language').data("single-language") === "True") {
$("#settings_single_language").checkbox('check');
} else {
$("#settings_single_language").checkbox('uncheck');
}
if ($('#settings_scenename').data("scenename") === "True") {
$("#settings_scenename").checkbox('check');
} else {
$("#settings_scenename").checkbox('uncheck');
}
if ($('#settings_upgrade_subs').data("upgrade") === "True") {
$("#settings_upgrade_subs").checkbox('check');
} else {
$("#settings_upgrade_subs").checkbox('uncheck');
}
$('#settings_upgrade_subs_frequency').dropdown('clear');
$('#settings_upgrade_subs_frequency').dropdown('set selected','{{!settings.general.upgrade_frequency}}');
$('#settings_upgrade_subs_frequency').dropdown('refresh');
if ($('#settings_upgrade_manual').data("upgrade-manual") === "True") {
$("#settings_upgrade_manual").checkbox('check');
} else {
$("#settings_upgrade_manual").checkbox('uncheck');
}
if ($('#settings_embedded').data("embedded") === "True") {
$("#settings_embedded").checkbox('check');
} else {
$("#settings_embedded").checkbox('uncheck');
}
if ($('#settings_ignore_pgs').data("ignorepgs") === "True") {
$("#settings_ignore_pgs").checkbox('check');
} else {
$("#settings_ignore_pgs").checkbox('uncheck');
}
if ($('#settings_adaptive_searching').data("adaptive") === "True") {
$("#settings_adaptive_searching").checkbox('check');
} else {
$("#settings_adaptive_searching").checkbox('uncheck');
}
if ($('#settings_multithreading').data("multithreading") === "True") {
$("#settings_multithreading").checkbox('check');
} else {
$("#settings_multithreading").checkbox('uncheck');
}
if ($('#settings_utf8_encode').data("utf8encode") === "True") {
$("#settings_utf8_encode").checkbox('check');
} else {
$("#settings_utf8_encode").checkbox('uncheck');
}
if (($('#settings_subfolder').val() !== "relative") && ($('#settings_subfolder').val() !== "absolute")) {
$('.subfolder').hide();
}
$('#settings_subfolder').dropdown('setting', 'onChange', function(){
if (($('#settings_subfolder').val() !== "relative") && ($('#settings_subfolder').val() !== "absolute")) {
$('.subfolder').hide();
}
else {
$('.subfolder').show();
}
});
if ($('#settings_anti_captcha_provider').val() === "None") {
$('.anticaptcha').hide();
$('.deathbycaptcha').hide();
} else if ($('#settings_anti_captcha_provider').val() === "anti-captcha") {
$('.anticaptcha').show();
$('.deathbycaptcha').hide();
} else if ($('#settings_anti_captcha_provider').val() === "death-by-cCaptcha") {
$('.deathbycaptcha').show();
$('.anticaptcha').hide();
}
$('#settings_anti_captcha_provider').dropdown('setting', 'onChange', function(){
if ($('#settings_anti_captcha_provider').val() === "None") {
$('.anticaptcha').hide();
$('.deathbycaptcha').hide();
} else if ($('#settings_anti_captcha_provider').val() === "anti-captcha") {
$('.anticaptcha').show();
$('.deathbycaptcha').hide();
} else if ($('#settings_anti_captcha_provider').val() === "death-by-captcha") {
$('.deathbycaptcha').show();
$('.anticaptcha').hide();
}
});
if ($('#settings_upgrade_subs').data("upgrade") === "True") {
$('.upgrade_subs').show();
} else {
$('.upgrade_subs').hide();
}
$('#settings_upgrade_subs').checkbox({
onChecked: function() {
$('.upgrade_subs').show();
},
onUnchecked: function() {
$('.upgrade_subs').hide();
}
});
$('#settings_languages').dropdown('setting', 'onAdd', function(val, txt){
$("#settings_serie_default_languages").append(
$("<option></option>").attr("value", val).text(txt)
);
$("#settings_movie_default_languages").append(
$("<option></option>").attr("value", val).text(txt)
)
});
$('#settings_languages').dropdown('setting', 'onRemove', function(val, txt){
$("#settings_serie_default_languages").dropdown('remove selected', val);
$("#settings_serie_default_languages option[value='" + val + "']").remove();
$("#settings_movie_default_languages").dropdown('remove selected', val);
$("#settings_movie_default_languages option[value='" + val + "']").remove();
});
if ($('#settings_serie_default_enabled_div').data("enabled") === "True") {
$("#settings_serie_default_enabled_div").checkbox('check');
} else {
$("#settings_serie_default_enabled_div").checkbox('uncheck');
}
if ($('#settings_serie_default_enabled_div').data("enabled") === "True") {
$("#settings_serie_default_languages").removeClass('disabled');
$("#settings_serie_default_hi_div").removeClass('disabled');
$("#settings_serie_default_forced_div").removeClass('disabled');
} else {
$("#settings_serie_default_languages").addClass('disabled');
$("#settings_serie_default_hi_div").addClass('disabled');
$("#settings_serie_default_forced_div").addClass('disabled');
}
$('#settings_serie_default_enabled_div').checkbox({
onChecked: function() {
$("#settings_serie_default_languages").parent().removeClass('disabled');
$("#settings_serie_default_hi_div").removeClass('disabled');
$("#settings_serie_default_forced").parent().removeClass('disabled');
},
onUnchecked: function() {
$("#settings_serie_default_languages").parent().addClass('disabled');
$("#settings_serie_default_hi_div").addClass('disabled');
$("#settings_serie_default_forced").parent().addClass('disabled');
}
});
if ($('#settings_serie_default_hi_div').data("hi") === "True") {
$("#settings_serie_default_hi_div").checkbox('check');
} else {
$("#settings_serie_default_hi_div").checkbox('uncheck');
}
if ($('#settings_movie_default_enabled_div').data("enabled") === "True") {
$("#settings_movie_default_enabled_div").checkbox('check');
} else {
$("#settings_movie_default_enabled_div").checkbox('uncheck');
}
if ($('#settings_movie_default_enabled_div').data("enabled") === "True") {
$("#settings_movie_default_languages").removeClass('disabled');
$("#settings_movie_default_hi_div").removeClass('disabled');
$("#settings_movie_default_forced_div").removeClass('disabled');
} else {
$("#settings_movie_default_languages").addClass('disabled');
$("#settings_movie_default_hi_div").addClass('disabled');
$("#settings_movie_default_forced_div").addClass('disabled');
}
$('#settings_movie_default_enabled_div').checkbox({
onChecked: function() {
$("#settings_movie_default_languages").parent().removeClass('disabled');
$("#settings_movie_default_hi_div").removeClass('disabled');
$("#settings_movie_default_forced").parent().removeClass('disabled');
},
onUnchecked: function() {
$("#settings_movie_default_languages").parent().addClass('disabled');
$("#settings_movie_default_hi_div").addClass('disabled');
$("#settings_movie_default_forced").parent().addClass('disabled');
}
});
if ($('#settings_movie_default_hi_div').data("hi") === "True") {
$("#settings_movie_default_hi_div").checkbox('check');
} else {
$("#settings_movie_default_hi_div").checkbox('uncheck');
}
if ($("#settings_single_language").checkbox('is checked')) {
$("#settings_serie_default_languages").parent().removeClass('multiple');
$("#settings_serie_default_languages").removeAttr('multiple');
$("#settings_movie_default_languages").parent().removeClass('multiple');
$("#settings_movie_default_languages").removeAttr('multiple');
} else {
$("#settings_serie_default_languages").parent().addClass('multiple');
$("#settings_serie_default_languages").attr('multiple');
$("#settings_movie_default_languages").parent().addClass('multiple');
$("#settings_movie_default_languages").attr('multiple');
}
$("#settings_single_language").on('change', function() {
if ($("#settings_single_language").checkbox('is checked')) {
$("#settings_serie_default_languages").dropdown('clear');
$("#settings_movie_default_languages").dropdown('clear');
$("#settings_serie_default_languages").prepend("<option value='None' selected='selected'>None</option>");
$("#settings_movie_default_languages").prepend("<option value='None' selected='selected'>None</option>");
$("#settings_serie_default_languages").parent().removeClass('multiple');
$("#settings_serie_default_languages").removeAttr('multiple');
$("#settings_movie_default_languages").parent().removeClass('multiple');
$("#settings_movie_default_languages").removeAttr('multiple');
} else {
$("#settings_serie_default_languages").dropdown('clear');
$("#settings_movie_default_languages").dropdown('clear');
$("#settings_serie_default_languages option[value='None']").remove();
$("#settings_movie_default_languages option[value='None']").remove();
$("#settings_serie_default_languages").parent().addClass('multiple');
$("#settings_serie_default_languages").attr('multiple');
$("#settings_movie_default_languages").parent().addClass('multiple');
$("#settings_movie_default_languages").attr('multiple');
}
});
$('#settings_subfolder').dropdown('clear');
$('#settings_subfolder').dropdown('set selected', '{{!settings.general.subfolder}}');
$('#settings_anti_captcha_provider').dropdown('clear');
$('#settings_anti_captcha_provider').dropdown('set selected', '{{!settings.general.anti_captcha_provider}}');
$('#settings_languages').dropdown('clear');
$('#settings_languages').dropdown('set selected',{{!enabled_languages}});
%if settings.general.serie_default_language != 'None':
$('#settings_serie_default_languages').dropdown('set selected',{{!settings.general.serie_default_language}});
%end
%if settings.general.movie_default_language != 'None':
$('#settings_movie_default_languages').dropdown('set selected',{{!settings.general.movie_default_language}});
%end
$('#settings_serie_default_forced').dropdown('set selected','{{!settings.general.serie_default_forced}}');
$('#settings_movie_default_forced').dropdown('set selected','{{!settings.general.movie_default_forced}}');
$('#settings_languages').dropdown('setting', 'onChange', function(){
$('.form').form('validate field', 'settings_subliminal_languages');
});
</script>

@ -96,7 +96,7 @@
Next
</button></div>
% include('wizard_general.tpl')
{% include 'wizard_general.html' %}
</div>
<div class="ui bottom attached tab segment" data-tab="subtitles" id="subtitles">
@ -111,7 +111,7 @@
</button>
</div>
% include('wizard_subtitles')
{% include 'wizard_subtitles.html' %}
</div>
<div class="ui bottom attached tab segment" data-tab="sonarr" id="sonarr">
<div class="ui container"><button class="submit ui blue right floated right labeled icon button next3">
@ -123,7 +123,7 @@
Prev
</button></div>
% include('wizard_sonarr.tpl')
{% include 'wizard_sonarr.html' %}
</div>
<div class="ui bottom attached tab segment" data-tab="radarr" id="radarr">
@ -133,11 +133,11 @@
Prev
</button></div>
% include('wizard_radarr')
{% include 'wizard_radarr.html' %}
</div>
</form>
</div>
% include('footer.tpl')
{% include 'footer.tpl' %}
</body>
</html>

@ -0,0 +1,201 @@
<div class="ui dividing header">Start-Up</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Listening IP Address</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input name="settings_general_ip" type="text" value="{{ settings.general.ip }}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires A Restart To Take Effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Valid IP4 Address or '0.0.0.0' for all interfaces"
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Listening Port</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input name="settings_general_port" type="text" value="{{ settings.general.port }}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires A Restart To Take Effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Valid TCP Port (default: 6767)" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Base URL</label>
</div>
<div class="five wide column">
<div class="ui fluid input">
{% if settings.general.base_url == None %}
{% set base_url = "/" %}
{% else %}
{% set base_url = settings.general.base_url %}
{% endif %}
<input name="settings_general_baseurl" type="text">
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires A Restart To Take Effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="For Reverse Proxy Support, Default Is '/'" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Path Mappings For TV Shows</div>
<div class="twelve wide column">
<div class="ui grid">
{% if settings.general.path_mappings != None %}
{% set path_substitutions = ast.literal_eval(settings.general.path_mappings) %}
{% else %}
{% set path_substitutions = [] %}
{% endif %}<div class="middle aligned row"><div class="right aligned four wide column">
</div><div class="two wide column"><div class="ui fluid input"><h4 class="ui header">Path for Sonarr:</h4></div></div><div class="collapsed column"><div class="collapsed center aligned column"><div class="ui basic icon" data-tooltip="Root path to the directory Sonarr accesses." data-inverted=""><i class="help circle large icon"></i></div></div></div><div class="two wide center aligned column">
</div><div class="two wide column"><div class="ui fluid input"><h4 class="ui header">Path for Bazarr:</h4></div></div><div class="collapsed column"><div class="collapsed center aligned column"><div class="ui basic icon" data-tooltip="Path that Bazarr should use to access the same directory remotely." data-inverted=""><i class="help circle large icon"></i></div></div></div></div>
{% for x in range(0, 5) %}
{% set path = [] %}
{% if path_substitutions[x] %}
{% set path = path_substitutions[x] %}
{% else %}
{% set path = ["", ""] %}
{% endif %}
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_sourcepath[]" type="text">
</div>
</div>
<div class="center aligned column">
<i class="arrow circle right icon"></i>
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_destpath[]" type="text">
</div>
</div>
</div>
{% endfor %}
</div>
</div>
<div class="ui dividing header">Path Mappings For Movies</div>
<div class="twelve wide column">
<div class="ui grid">
{% if settings.general.path_mappings_movie != None %}
{% set path_substitutions_movie = ast.literal_eval(settings.general.path_mappings_movie) %}
{% else %}
{% set path_substitutions_movie = [] %}
{% endif %}
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Radarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Root path to the directory Radarr accesses."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="two wide center aligned column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Bazarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon"
data-tooltip="Path that Bazarr should use to access the same directory remotely."
data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
{% for x in range(0, 5) %}
{% set path_movie = [] %}
{% if path_substitutions_movie[x] %}
{% set path_movie = path_substitutions_movie[x] %}
{% else %}
{% set path_movie = ["", ""] %}
{% endif %}
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_sourcepath_movie[]" type="text">
</div>
</div>
<div class="center aligned column">
<i class="arrow circle right icon"></i>
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_destpath_movie[]" type="text">
</div>
</div>
</div>
{% endfor %}
</div>
</div>
<script>
</script>

@ -1,231 +0,0 @@
<div class="ui dividing header">Start-Up</div>
<div class="twelve wide column">
<div class="ui grid">
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Listening IP Address</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input name="settings_general_ip" type="text" value="{{settings.general.ip}}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires A Restart To Take Effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Valid IP4 Address or '0.0.0.0' for all interfaces" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Listening Port</label>
</div>
<div class="five wide column">
<div class='field'>
<div class="ui fluid input">
<input name="settings_general_port" type="text" value="{{settings.general.port}}">
</div>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires A Restart To Take Effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Valid TCP Port (default: 6767)" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="middle aligned row">
<div class="right aligned four wide column">
<label>Base URL</label>
</div>
<div class="five wide column">
<div class="ui fluid input">
%if settings.general.base_url is None:
% base_url = "/"
%else:
% base_url = settings.general.base_url
%end
<input name="settings_general_baseurl" type="text">
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Requires A Restart To Take Effect" data-inverted="">
<i class="yellow warning sign icon"></i>
</div>
</div>
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="For Reverse Proxy Support, Default Is '/'" data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
</div>
<div class="ui dividing header">Path Mappings For TV Shows</div>
<div class="twelve wide column">
<div class="ui grid">
%import ast
%if settings.general.path_mappings is not None:
% path_substitutions = ast.literal_eval(settings.general.path_mappings)
%else:
% path_substitutions = []
%end
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Sonarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Root path to the directory Sonarr accesses." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="two wide center aligned column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Bazarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Path that Bazarr should use to access the same directory remotely." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
%for x in range(0, 5):
% path = []
% try:
% path = path_substitutions[x]
% except IndexError:
% path = ["", ""]
% end
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_sourcepath" type="text">
</div>
</div>
<div class="center aligned column">
<i class="arrow circle right icon"></i>
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_destpath" type="text">
</div>
</div>
</div>
%end
</div>
</div>
<div class="ui dividing header">Path Mappings For Movies</div>
<div class="twelve wide column">
<div class="ui grid">
%import ast
%if settings.general.path_mappings_movie is not None:
% path_substitutions_movie = ast.literal_eval(settings.general.path_mappings_movie)
%else:
% path_substitutions_movie = []
%end
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Radarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Root path to the directory Radarr accesses." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
<div class="two wide center aligned column">
</div>
<div class="two wide column">
<div class="ui fluid input">
<h4 class="ui header">
Path for Bazarr:
</h4>
</div>
</div>
<div class="collapsed column">
<div class="collapsed center aligned column">
<div class="ui basic icon" data-tooltip="Path that Bazarr should use to access the same directory remotely." data-inverted="">
<i class="help circle large icon"></i>
</div>
</div>
</div>
</div>
%for x in range(0, 5):
% path_movie = []
% try:
% path_movie = path_substitutions_movie[x]
% except IndexError:
% path_movie = ["", ""]
% end
<div class="middle aligned row">
<div class="right aligned four wide column">
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_sourcepath_movie" type="text">
</div>
</div>
<div class="center aligned column">
<i class="arrow circle right icon"></i>
</div>
<div class="four wide column">
<div class="ui fluid input">
<input name="settings_general_destpath_movie" type="text">
</div>
</div>
</div>
%end
</div>
</div>
<script>
</script>

@ -71,7 +71,7 @@
</div>
</div>
% include('providers.tpl')
{% include('providers.html') %}
<div class="ui dividing header">Subtitles languages</div>
<div class="twelve wide column">
@ -103,13 +103,13 @@
<div class='field'>
<select name="settings_subliminal_languages" id="settings_languages" multiple="" class="ui fluid search selection dropdown">
<option value="">Languages</option>
%enabled_languages = []
%for language in settings_languages:
{% set enabled_languages = [] %}
{% for language in settings_languages %}
<option value="{{language['code2']}}">{{language['name']}}</option>
%if language['enabled'] == True:
% enabled_languages.append(str(language['code2']))
%end
%end
{% if language['enabled'] == True %}
{{ enabled_languages.append(str(language['code2'])) }}
{% endif %}
{% endfor %}
</select>
</div>
</div>
@ -148,11 +148,11 @@
<div class="eleven wide column">
<div class='field'>
<select name="settings_serie_default_languages" id="settings_serie_default_languages" multiple="" class="ui fluid search selection dropdown">
%if not settings.general.getboolean('single_language'):
{% if not settings.general.getboolean('single_language') %}
<option value="">Languages</option>
%else:
{% else %}
<option value="None">None</option>
%end
{% endif %}
</select>
</div>
</div>
@ -396,19 +396,19 @@
});
$('#settings_languages').dropdown('clear');
$('#settings_languages').dropdown('set selected',{{!enabled_languages}});
$('#settings_languages').dropdown('set selected',{{ enabled_languages }});
$('#settings_subfolder').dropdown('clear');
$('#settings_subfolder').dropdown('set selected', '{{!settings.general.subfolder}}');
$('#settings_subfolder').dropdown('set selected', '{{ settings.general.subfolder }}');
%if settings.general.serie_default_language != 'None':
$('#settings_serie_default_languages').dropdown('set selected',{{!settings.general.serie_default_language}});
%end
%if settings.general.movie_default_language != 'None':
$('#settings_movie_default_languages').dropdown('set selected',{{!settings.general.movie_default_language}});
%end
{% if settings.general.serie_default_language != 'None' %}
$('#settings_serie_default_languages').dropdown('set selected',{{ settings.general.serie_default_language }});
{% endif %}
{% if settings.general.movie_default_language != 'None' %}
$('#settings_movie_default_languages').dropdown('set selected',{{ settings.general.movie_default_language }});
{% endif %}
$('#settings_serie_default_forced').dropdown('set selected','{{!settings.general.serie_default_forced}}');
$('#settings_movie_default_forced').dropdown('set selected','{{!settings.general.movie_default_forced}}');
$('#settings_serie_default_forced').dropdown('set selected','{{ settings.general.serie_default_forced }}');
$('#settings_movie_default_forced').dropdown('set selected','{{ settings.general.movie_default_forced }}');
$('#settings_languages').dropdown('setting', 'onChange', function(){
$('.form').form('validate field', 'settings_subliminal_languages');
Loading…
Cancel
Save