diff --git a/data/interfaces/default/css/plexpy.css b/data/interfaces/default/css/plexpy.css index 86866feb..a5f57438 100644 --- a/data/interfaces/default/css/plexpy.css +++ b/data/interfaces/default/css/plexpy.css @@ -2137,6 +2137,20 @@ a:hover .item-children-poster { top: 5px; left: 12px; } +#menu_link_show_advanced_settings.active { + color: #fff; + background-color: #cc7b19; +} +.advanced-setting { + display: none; +} +div.advanced-setting { + border-left: 1px solid #cc7b19; + padding-left: 10px; +} +li.advanced-setting { + border-left: 1px solid #cc7b19; +} .user-info-wrapper { } .user-info-poster-face { diff --git a/data/interfaces/default/settings.html b/data/interfaces/default/settings.html index 5f370592..218dae97 100644 --- a/data/interfaces/default/settings.html +++ b/data/interfaces/default/settings.html @@ -26,11 +26,16 @@ Settings
+ % if config['show_advanced_settings'] == 1: + + % else: + + % endif % if config['check_github']: % endif - +
@@ -43,19 +48,16 @@
  • General
  • Homepage
  • Web Interface
  • -
  • Access Control
  • Plex Media Server
  • -
  • Plex.tv Account
  • -
  • Activity Monitoring
  • Notifications
  • Notification Agents
  • -
  • Extra Settings
  • Import & Backups
  • Tautulli Remote Android App beta
  • +
    % if common.VERSION_NUMBER: @@ -78,6 +80,7 @@
    +
    @@ -102,24 +105,54 @@

    Set your preferred time format. Click here to see the parameter list.

    -
    +

    Change the "Play by day of week" graph to start on Monday. Default is start on Sunday.

    -
    +

    Group successive play history by the same user as a single entry in the tables and watch statistics.

    -
    +

    Include current activity in the history tables. Statistics will not be counted until the stream has ended.

    +
    + +

    Enable if you want Tautulli to calculate the total file size for TV Shows/Seasons and Artists/Albums on the media info tables.

    +
    +
    + +

    + Enable to mask passwords, access tokens, and public IP addresses with asterisks (*) in the logs.
    + Note: Only logs from the time this setting is enabled will be masked. Do not post your logs publically without masking sensitive information! +

    +
    + +
    +

    History Logging

    +
    + +
    + +
    +
    + +
    + +
    +

    The interval (in seconds) an item must be in a playing state before logging it. 0 to disable.

    +
    @@ -150,6 +183,20 @@

    Set the percentage for a music track to be considered as listened. Minimum 50, Maximum 95.

    +
    + +

    + Attempt to fix history logging by flushing out all of the temporary sessions in the database.
    + Warning: This will reset all currently active sessions. For emergency use only when history logging is stuck! +

    +
    +
    +
    + +
    +
    +
    +

    Updates

    @@ -168,7 +215,7 @@

    Update Tautulli automatically if an update is available.

    -
    +
    @@ -179,6 +226,41 @@
    + % if plexpy.INSTALL_TYPE == 'git': +
    + +
    +
    +
    + + + + + +
    +
    +
    +

    The git tracking remote and branch (default "origin/master"). Select to switch the git branch (requires restart).

    +
    +
    + +
    +
    + +
    +
    +

    Optional: The path to your git environment variable. Leave blank for default.

    +
    + % endif +

    @@ -331,7 +413,13 @@

    Note: Web interface changes require a restart.

    -
    +
    + +

    Launch browser pointed to Tautulli on startup.

    +
    +
    @@ -350,7 +438,7 @@

    Port to bind web server to. Note that ports below 1024 may require root.

    -
    +
    @@ -359,34 +447,27 @@

    The base URL of the web server. Used for reverse proxies.

    -
    +

    Respect the X-Forwarded-Proto header. Used for reverse proxies with SSL.

    -
    -
    - -

    Launch browser pointed to Tautulli on startup.

    -
    -
    +

    Enable HTTPS for web server for encrypted communication.

    -
    +

    Check to have Tautulli create a self-signed SSL certificate. Uncheck if you want to use your own certificate.

    -
    +
    @@ -395,7 +476,7 @@

    The domain names used to access Tautulli, separated by commas (,).

    -
    +
    @@ -405,7 +486,7 @@

    The IP addresses used to access Tautulli, separated by commas (,).

    -
    +
    @@ -414,7 +495,7 @@

    The location of the SSL certificate.

    -
    +
    @@ -423,7 +504,7 @@

    The location of the SSL certificate chain.

    -
    +
    @@ -433,17 +514,22 @@

    The location of the SSL key.

    -

    -
    - -
    +
    + +
    +
    + +
    +
    +

    Backlink protection via anonymizer service, must end in "?".

    +

    Authentication

    -

    Authentication changes require a restart.

    +

    Note: Authentication changes require a restart.

    @@ -463,23 +549,17 @@

    Password for web server authentication. Leave empty to disable.

    -
    + +

    Store a hashed password in the config file.
    Warning: Your password cannot be recovered if forgotten!

    - -
    - - -

    Allow the Plex server admin to login as a Tautulli admin using their Plex.tv account.

    -
    -
    +
    @@ -488,10 +568,13 @@ -
    -

    Guest Access

    +
    + + +

    Allow the Plex server admin to login as a Tautulli admin using their Plex.tv account.

    -
    +
    + +
    +
    +
    + + + + +
    + +
    + +
    +

    IP Address or hostname for Plex Media Server.

    +
    +
    + +
    +
    + +
    + +
    +

    Port that Plex Media Server is listening on.

    +
    +
    + +

    Check this if your Plex Server is not on the same local network as Tautulli.

    +
    +
    + +

    If you have secure connections enabled on your Plex Server, communicate with it securely.

    +
    +
    + % if config['pms_is_cloud']: + + Not available for Plex Cloud servers. + % else: + + % endif +

    Use the user defined connection details. Do not retrieve the server connection URL automatically.

    +
    +
    + +
    +
    +
    + + + + +
    +
    + +
    +

    + Optional: Manually override the Plex Web URL used for click-through links on the media info pages and notifications. Default https://app.plex.tv/desktop. +

    +
    + + + + +
    + +
    +
    + +
    + +
    +

    + Optional: Set your Plex logs folder to use Tautulli as a log viewer. Plex logs are not needed for Tautulli to function. + A complete folder path is required, shortcuts are not recognized, and the logs must be accessible from the machine where Tautulli is installed. + Click here for help. +

    +
    +
    + +

    + Enable to cache images from Plex to reduce API calls and improve loading times.
    + Note: Video preview thumbnails (BIF) are not cached. +

    +
    + +
    +

    Server Monitoring

    +
    +
    % if config['pms_is_cloud']:
    -
    - -
    -
    -
    - - - - -
    - -
    - -
    -

    IP Address or hostname for Plex Media Server.

    -
    -
    - +
    +
    - +
    - +
    -

    Port that Plex Media Server is listening on.

    +

    The interval (in hours) Tautulli will request an updated friends list from Plex.tv. Minimum 1, maximum 24, default 12.

    -
    +
    -

    Check this if your Plex Server is not on the same local network as Tautulli.

    +

    Refresh the users list when Tautulli starts.

    -
    - -

    If you have secure connections enabled on your Plex Server, communicate with it securely.

    -
    -
    - % if config['pms_is_cloud']: - - Not available for Plex Cloud servers. - % else: - - % endif -

    Use the user defined connection details. Do not retrieve the server connection URL automatically.

    -
    -
    - + +
    +
    -
    -
    - - - - -
    +
    +
    - +
    -

    - Optional: Manually override the Plex Web URL used for click-through links on the media info pages and notifications. Default https://app.plex.tv/desktop. -

    +

    The interval (in hours) Tautulli will request an updated libraries list from your Plex Media Server. Minimum 1, maximum 24, default 12.

    - - - - -
    -

    Plex Logs

    +
    + +

    Refresh the libraries list when Tautulli starts.

    -
    - -
    -
    - -
    - -
    -

    - Optional: Set your Plex logs folder to use Tautulli as a log viewer. Plex logs are not needed for Tautulli to function. - A complete folder path is required, shortcuts are not recognized, and the logs must be accessible from the machine where Tautulli is installed. - Click here for help. -

    -
    - - - -
    -
    -

    Plex.tv Authentication

    @@ -700,71 +821,14 @@

    Token for Plex.tv authentication.

    -
    -

    Friends List

    -
    - -
    - -
    -
    - -
    - -
    -

    The interval (in hours) Tautulli will request an updated friends list from Plex.tv. Minimum 1, maximum 24, default 12.

    -
    -
    - -

    Refresh the users list when Tautulli starts.

    -
    - -
    -

    Libraries List

    -
    - -
    - -
    -
    - -
    - -
    -

    The interval (in hours) Tautulli will request an updated libraries list from your Plex Media Server. Minimum 1, maximum 24, default 12.

    -
    -
    - -

    Refresh the libraries list when Tautulli starts.

    -
    -

    -
    +
    -

    History Logging

    -
    - -
    - -
    -
    - -
    - -
    -

    The interval (in seconds) an item must be in a playing state before logging it. 0 to disable.

    -
    - -
    -

    Buffer Warnings

    +

    Current Activity Notifications

    Note: Buffer warnings only work on certain Plex clients. Android and Plex Web do not report buffer events accurately or at all.

    @@ -778,7 +842,7 @@

    How many buffer events should we wait before triggering the first warning. Buffer events increment on each monitor ping if play state is buffering. 0 to disable buffer warnings.

    -
    +
    @@ -788,24 +852,13 @@

    The value (in seconds) Tautulli should wait before triggering the next buffer warning. 0 to always trigger.

    - -

    - -
    - -
    - -
    -

    Current Activity Notifications

    -
    - -
    +

    Enable to allow sending of consecutive notifications (i.e. both watched & stopped notifications).

    -
    +
    @@ -921,103 +974,6 @@
    -
    - -
    -

    Extra Settings

    -
    - -
    - -

    Enable if you want Tautulli to calculate the total file size for TV Shows/Seasons and Artists/Albums on the media info tables.

    -
    -
    - -

    - Enable to mask passwords, access tokens, and public IP addresses with asterisks (*) in the logs.
    - Note: Only logs from the time this setting is enabled will be masked. Do not post your logs publically without masking sensitive information! -

    -
    -
    - -

    - Enable to cache images from Plex to reduce API calls and improve loading times.
    - Note: Video preview thumbnails (BIF) are not cached. -

    -
    -
    - -
    -
    - -
    -
    -

    Backlink protection via anonymizer service, must end in "?".

    -
    -
    - -

    - Attempt to fix history logging by flushing out all of the temporary sessions in the database.
    - Warning: This will reset all currently active sessions. For emergency use only when history logging is stuck! -

    -
    -
    -
    - -
    -
    -
    -
    - - % if plexpy.INSTALL_TYPE == 'git': -
    -

    Git Settings

    -
    - -
    - -
    -
    -
    - - - - - -
    -
    -
    -

    The git tracking remote and branch (default "origin/master"). Select to switch the git branch (requires restart).

    -
    -
    - -
    -
    - -
    -
    -

    Optional: The path to your git environment variable. Leave blank for default.

    -
    - % endif - -

    - -
    -
    @@ -1668,6 +1624,15 @@ $(document).ready(function() { } } + function advancedSettings() { + var advanced_button = $('#menu_link_show_advanced_settings'); + if (advanced_button.hasClass('active')) { + $('.advanced-setting').show(); + } else { + $('.advanced-setting').hide(); + } + } + $('.save-button').click(function() { preSaveChecks(function () { saveSettings() }); }); @@ -1707,6 +1672,19 @@ $(document).ready(function() { window.location.href = 'restart'; }); + $('#menu_link_show_advanced_settings').click(function() { + $(this).toggleClass('active'); + if ($(this).hasClass('active')) { + $(this).html(' Hide Advanced'); + $('#show_advanced_settings').val(1); + } else { + $(this).html(' Show Advanced'); + $('#show_advanced_settings').val(0); + } + advancedSettings() + }); + + advancedSettings(); getConfigurationTable(); getSchedulerTable(); getNotifiersTable(); diff --git a/plexpy/config.py b/plexpy/config.py index 76952e7a..29645757 100644 --- a/plexpy/config.py +++ b/plexpy/config.py @@ -480,6 +480,7 @@ _CONFIG_DEFINITIONS = { 'REFRESH_USERS_ON_STARTUP': (int, 'Monitoring', 1), 'REMOTE_ACCESS_PING_THRESHOLD': (int, 'Advanced', 3), 'SESSION_DB_WRITE_ATTEMPTS': (int, 'Advanced', 5), + 'SHOW_ADVANCED_SETTINGS': (int, 'General', 0), 'SLACK_ENABLED': (int, 'Slack', 0), 'SLACK_HOOK': (str, 'Slack', ''), 'SLACK_CHANNEL': (str, 'Slack', ''), diff --git a/plexpy/webserve.py b/plexpy/webserve.py index 15562f8a..65b8e62c 100644 --- a/plexpy/webserve.py +++ b/plexpy/webserve.py @@ -2611,7 +2611,8 @@ class WebInterface(object): "tv_watched_percent": plexpy.CONFIG.TV_WATCHED_PERCENT, "music_watched_percent": plexpy.CONFIG.MUSIC_WATCHED_PERCENT, "themoviedb_lookup": checked(plexpy.CONFIG.THEMOVIEDB_LOOKUP), - "tvmaze_lookup": checked(plexpy.CONFIG.TVMAZE_LOOKUP) + "tvmaze_lookup": checked(plexpy.CONFIG.TVMAZE_LOOKUP), + "show_advanced_settings": plexpy.CONFIG.SHOW_ADVANCED_SETTINGS } return serve_template(templatename="settings.html", title="Settings", config=config, kwargs=kwargs)