From d6b646323f8bd44b1fbce9eea6a7de993b824927 Mon Sep 17 00:00:00 2001 From: Tim Date: Sun, 2 Aug 2015 16:46:35 +0200 Subject: [PATCH] Move everything to Bootstrap 3. (WIP) Styling changes. Remove old unused css. Some code cleanup on notification handler. --- data/interfaces/default/base.html | 186 +- data/interfaces/default/css/bootstrap.css | 6566 ------------- data/interfaces/default/css/bootstrap.css.map | 1 - .../default/css/bootstrap3/bootstrap.css | 3 +- data/interfaces/default/css/config.less | 77 - .../default/css/dataTables.bootstrap.css | 371 + data/interfaces/default/css/font-awesome.css | 1801 ---- ...watch-tables.css => plexpy-dataTables.css} | 386 +- data/interfaces/default/css/plexpy.css | 1446 +++ data/interfaces/default/css/plexwatch.css | 8588 ----------------- data/interfaces/default/css/style.css | 96 - data/interfaces/default/css/style.less | 1186 --- data/interfaces/default/current_activity.html | 38 +- .../default/current_activity_header.html | 2 +- data/interfaces/default/edit_user.html | 48 +- data/interfaces/default/graphs.html | 104 +- data/interfaces/default/history.html | 73 +- data/interfaces/default/home_stats.html | 201 +- data/interfaces/default/images/sort_asc.png | Bin 160 -> 0 bytes .../default/images/sort_asc_disabled.png | Bin 148 -> 0 bytes data/interfaces/default/images/sort_both.png | Bin 201 -> 0 bytes data/interfaces/default/images/sort_desc.png | Bin 158 -> 0 bytes .../default/images/sort_desc_disabled.png | Bin 146 -> 0 bytes data/interfaces/default/index.html | 76 +- data/interfaces/default/info.html | 74 +- .../interfaces/default/info_episode_list.html | 5 +- data/interfaces/default/js/bootstrap.js | 2291 ----- data/interfaces/default/js/bootstrap.min.js | 7 - data/interfaces/default/js/cacher.js | 66 - data/interfaces/default/js/common.js | 17 - .../default/js/dataTables.bootstrap.js | 162 - .../default/js/dataTables.bootstrap.min.js | 8 + ....js => dataTables.bootstrap.pagination.js} | 37 +- data/interfaces/default/js/script.js | 6 +- data/interfaces/default/js/spin.min.js | 2 - .../default/js/tables/history_table.js | 30 +- data/interfaces/default/js/tables/logs.js | 6 +- .../interfaces/default/js/tables/plex_logs.js | 6 +- .../default/js/tables/sync_table.js | 20 +- data/interfaces/default/js/tables/user_ips.js | 10 +- data/interfaces/default/js/tables/users.js | 6 +- data/interfaces/default/logs.html | 90 +- .../default/notification_config.html | 71 +- data/interfaces/default/plexwatch_import.html | 72 +- data/interfaces/default/recently_added.html | 9 +- data/interfaces/default/settings.html | 1097 ++- data/interfaces/default/shutdown.html | 42 +- data/interfaces/default/stream_data.html | 140 +- data/interfaces/default/sync.html | 67 +- data/interfaces/default/user.html | 388 +- .../default/user_platform_stats.html | 10 +- .../default/user_recently_watched.html | 7 +- .../default/user_watch_time_stats.html | 6 +- data/interfaces/default/users.html | 95 +- data/interfaces/default/welcome.html | 28 +- plexpy/notification_handler.py | 67 +- 56 files changed, 3397 insertions(+), 22794 deletions(-) delete mode 100644 data/interfaces/default/css/bootstrap.css delete mode 100644 data/interfaces/default/css/bootstrap.css.map delete mode 100644 data/interfaces/default/css/config.less create mode 100644 data/interfaces/default/css/dataTables.bootstrap.css delete mode 100644 data/interfaces/default/css/font-awesome.css rename data/interfaces/default/css/{plexwatch-tables.css => plexpy-dataTables.css} (58%) create mode 100644 data/interfaces/default/css/plexpy.css delete mode 100644 data/interfaces/default/css/plexwatch.css delete mode 100644 data/interfaces/default/css/style.css delete mode 100644 data/interfaces/default/css/style.less delete mode 100644 data/interfaces/default/images/sort_asc.png delete mode 100644 data/interfaces/default/images/sort_asc_disabled.png delete mode 100644 data/interfaces/default/images/sort_both.png delete mode 100644 data/interfaces/default/images/sort_desc.png delete mode 100644 data/interfaces/default/images/sort_desc_disabled.png delete mode 100644 data/interfaces/default/js/bootstrap.js delete mode 100644 data/interfaces/default/js/bootstrap.min.js delete mode 100644 data/interfaces/default/js/cacher.js delete mode 100644 data/interfaces/default/js/common.js delete mode 100644 data/interfaces/default/js/dataTables.bootstrap.js create mode 100644 data/interfaces/default/js/dataTables.bootstrap.min.js rename data/interfaces/default/js/{jquery.dataTables.bootstrap.pagination.integration.js => dataTables.bootstrap.pagination.js} (71%) delete mode 100644 data/interfaces/default/js/spin.min.js diff --git a/data/interfaces/default/base.html b/data/interfaces/default/base.html index affe9b12..f7e52ef8 100644 --- a/data/interfaces/default/base.html +++ b/data/interfaces/default/base.html @@ -11,10 +11,10 @@ from plexpy import version - - + + - + @@ -15,51 +16,46 @@ from plexpy import helpers <%def name="body()">
-
-
-
-
-

Logs

+
+
+ Logs +
+
+ +
+
+
+
+ +
+
+ + + + + + + + + + +
TimestampLevelMessage
-
- -
-
-
-
- - -
-
- - - - - - - - - - -
TimestampLevelMessage
-
-
- - - - - - - - - - -
TimestampLevelMessage
-
-
+
+ + + + + + + + + + +
TimestampLevelMessage
@@ -78,12 +74,12 @@ from plexpy import helpers
-
<%def name="javascriptIncludes()"> - + + % endfor
% else: -
There was an error communicating with your Plex Server. Please check your settings. +
There was an error communicating with your Plex Server. Please check your settings.

% endif \ No newline at end of file diff --git a/data/interfaces/default/settings.html b/data/interfaces/default/settings.html index 524091fc..f4afa2c1 100644 --- a/data/interfaces/default/settings.html +++ b/data/interfaces/default/settings.html @@ -1,410 +1,491 @@ <%inherit file="base.html"/> <%! - import plexpy - from plexpy import notifiers +import plexpy +from plexpy import notifiers - available_notification_agents = notifiers.available_notification_agents() +available_notification_agents = notifiers.available_notification_agents() %> <%def name="headerIncludes()"> - <%def name="body()"> -
-
-
-
-
-
-

Settings

-
-
- % if config['check_github']: - - % endif - - -
+
+
+
+
+
+ Settings
-
- - -
-
-
-
-
-
-

Software Updates

-
-
- Enable Updates -

If you have Git installed, allow periodic checks for updates.

-
- % if plexpy.CURRENT_VERSION: -

Current version: ${plexpy.CURRENT_VERSION}

- % endif -
-
-
-

Display Settings

-
-
- - -

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

-
-
- - -

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

-
-
- -
-
-
-
-

Web Interface

-
-

Web interface changes require a restart.

-
- - -

e.g. localhost or an IP, such as 0.0.0.0

-
-
- - -

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

-
-
- Launch Browser on Startup -

Launch browser pointed to PlexPy, on startup.

-
-
- Enable HTTPS -

Enable HTTPS for web server for encrypted communication.

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

Authentication

-
-

Authentication changes require a restart.

-
- - -

Username for web server authentication. Leave empty to disable.

-
-
- - -

Password for web server authentication. Leave empty to disable.

-
-
-
-
-

API

-
-
- Enable API -

Allow remote applications to interface with PlexPy.

-
-
- - - -

Current API key:
${config['api_key']}

-
-
- -
-
-
-
-

Plex Media Server

-
-
- - - -

IP Address or hostname for Plex Media Server.

-
-
- - -

Port that Plex Media Server is listening on.

-
-
- Remote Server -

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

-
-
- Force SSL -

Force PlexPy to connect to your Plex Server via SSL. Your server needs to have remote access enabled.

-
- -
- -
-
-
-
-

Plex.tv Authentication

-
-
- - -  Fetch Token -

Token for Plex.tv authentication.

-
-
-
-
-

Friends List

-
-
- - -

The interval (in hours) PlexPy will request an updated friends list from Plex.tv. 1 minimum, 24 maximum.

-
-
- Refresh user list on startup -

Refresh the user list when PlexPy starts.

-
-
- -
-
-
-

Extra Settings

-
-
-
- Use BIF thumbs -

If you have media indexing enabled on your server, use these on the activity pane.

-
-
-
-

Plex Logs

-
-
-
- - -

Set the folder where your Plex Server logs are. This is required if you enable IP logging.
Click here for help.

-
-
-
-
-

PlexWatch Import Tool

-
-

Click here to Import an existing Plexwatch database.

-
- -
-
-
-
-

Monitoring Settings

-
-
- - -

The interval (in seconds) PlexPy will ping your Plex Server. Min 30 seconds, Recommended 60 seconds.

-
-
-
-
-

History Logging

-
-
- Log Movies and TV -

Keep records of all video items played from your Plex Media Server.

-
-
- - -

The interval (in seconds) PlexPy will wait for a video item to be active before logging it. 0 to disable.

-
-
- Log Music -

Keep records of all audio items played from your Plex Media Server. VERY experimental.

-
-
-
-
-

IP Logging

-
-
- Enable IP Logging - -

- Enable this to attempt to log the IP address of the user. -

-
-
- -
-
-
-
-

Global Notification Toggles

-
-
- Enable Movie and TV Notifications -
-
- Enable Music Notifications -
-
-
-

Notification Tuning

-
-
-
- - -

Set the progress percentage of when a watched notification should be triggered. Minimum 50, Maximum 95.

-
-
-
-
-
-

Custom Notification Messages

-
-

- You can set custom formatted text for each type of notification. - Click here for a list of available parameters which can be used. -

-

- You can also add tags to exclude certain text depending on the media type. Click - here to view usage information. -

-
-
    -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
-
- -
-
-
-
-

Notification Agents

-
-

- Toggle the desired notification option and configure it by selecting the settings icon to the right. - Watched notifications are only applicable for video items. -

-
-
    - % for agent in available_notification_agents: -
  • - - - - - - ${agent['name']} - % if agent['has_config']: - - % endif - -
  • - % endfor -
-
-
-
-
-
+
+ % if config['check_github']: + + % endif + +
+
+
+
+ + +
+
+
+
+
+

Software Updates

+
+
+ +

If you have Git installed, allow periodic checks for updates.

+
+ % if plexpy.CURRENT_VERSION: +

Current version: ${plexpy.CURRENT_VERSION}

+ % endif +
+

Display Settings

+
+
+ +
+
+ +
+
+

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

+
+
+ +
+
+ +
+
+

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

+
+ +
+
+
+

Web Interface

+
+

Web interface changes require a restart.

+
+ +
+
+ +
+
+

e.g. localhost or an IP, such as 0.0.0.0

+
+
+ +
+
+ +
+
+

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

+
+
+ +

Launch browser pointed to PlexPy, on startup.

+
+
+ +

Enable HTTPS for web server for encrypted communication.

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

Authentication

+
+

Authentication changes require a restart.

+
+ +
+
+ +
+
+

Username for web server authentication. Leave empty to disable.

+
+
+ +
+
+ +
+
+

Password for web server authentication. Leave empty to disable.

+
+ + +
+

API

+
+
+ +

Allow remote applications to interface with PlexPy.

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

Current API key:
${config['api_key']}

+
+ + +
+
+ +
+

Plex Media Server

+
+
+ +
+
+ + +
+
+

IP Address or hostname for Plex Media Server.

+
+
+ +
+
+ +
+
+

Port that Plex Media Server is listening on.

+
+
+ +

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

+
+
+ +

Force PlexPy to connect to your Plex Server via SSL. Your server needs to have remote access enabled.

+
+ + + +
+
+ +
+

Plex.tv Authentication

+
+
+ +
+
+ +
+
+  Fetch Token +

Token for Plex.tv authentication.

+
+ +
+

Friends List

+
+
+ +
+
+ +
+
+

The interval (in hours) PlexPy will request an updated friends list from Plex.tv. 1 minimum, 24 maximum.

+
+
+ +

Refresh the user list when PlexPy starts.

+
+ + +
+
+
+

Extra Settings

+
+ +
+ +

If you have media indexing enabled on your server, use these on the activity pane.

+
+ +
+

Plex Logs

+
+ +
+ +
+
+ +
+
+

Set the folder where your Plex Server logs are. This is required if you enable IP logging.
Click here for help.

+
+ + +
+

PlexWatch Import Tool

+
+

Click here to Import an existing Plexwatch database.

+ + +
+
+ +
+

Monitoring Settings

+
+
+ +
+
+ +
+
+

The interval (in seconds) PlexPy will ping your Plex Server. Min 30 seconds, Recommended 60 seconds.

+
+ +
+

History Logging

+
+
+ +

Keep records of all video items played from your Plex Media Server.

+
+
+ +
+
+ +
+
+

The interval (in seconds) PlexPy will wait for a video item to be active before logging it. 0 to disable.

+
+
+ +

Keep records of all audio items played from your Plex Media Server. VERY experimental.

+
+ +
+

IP Logging

+
+
+ + +

+ Enable this to attempt to log the IP address of the user. +

+
+ + +
+
+ +
+

Global Notification Toggles

+
+
+ +
+
+ +
+ +
+

Notification Tuning

+
+ +
+ +
+
+ +
+
+

Set the progress percentage of when a watched notification should be triggered. Minimum 50, Maximum 95.

+
+ +
+

Custom Notification Messages

+
+

+ You can set custom formatted text for each type of notification. + Click here for a list of available parameters which can be used. +

+

+ You can also add tags to exclude certain text depending on the media type. Click + here to view usage information. +

+
+
    +
  • + + +
  • +
  • + + +
  • +
  • + + +
  • +
+ + +
+
+ +
+

Notification Agents

+
+

+ Toggle the desired notification option and configure it by selecting the settings icon to the right. + Watched notifications are only applicable for video items. +

+
+
    + % for agent in available_notification_agents: +
  • + + + + + + ${agent['name']} + % if agent['has_config']: + + % endif + +
  • + % endfor +
+ +
+
+ +
+
+ + +