Skip to content
This repository has been archived by the owner on Oct 13, 2024. It is now read-only.

Commit

Permalink
fix(ui): use correct label in progress bar (#378)
Browse files Browse the repository at this point in the history
  • Loading branch information
ReenigneArcher authored Mar 15, 2024
1 parent d9a9d2e commit e373cd3
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
1 change: 1 addition & 0 deletions Contents/Code/webapp.py
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,7 @@ def cache_data():
len(collections_with_themes) / len(collections) * 100) if len(collections_with_themes) else 0,
collections_enabled=Prefs['bool_auto_update_collection_themes'],
total_count=len(all_items),
type=section.type,
)

for item in all_items:
Expand Down
15 changes: 13 additions & 2 deletions Contents/Resources/web/templates/home.html
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,19 @@ <h2><a class="text-black" role="button" data-bs-toggle="collapse"
</div>

<!-- Primary progress bar -->
{% set library_type = _('Games') if items[section]['agent'] == 'dev.lizardbyte.retroarcher-plex'
else _('Movies') %}
{% if items[section]['agent'] == 'dev.lizardbyte.retroarcher-plex' %}
{% set library_type = _('Games') %}
{% elif items[section]['type'] == 'movie' %}
{% set library_type = _('Movies') %}
{% elif items[section]['type'] == 'show' %}
{% set library_type = _('Shows') %}
{% elif items[section]['type'] == 'artist' %}
{% set library_type = _('Artists') %}
{% elif items[section]['type'] == 'photo' %}
{% set library_type = _('Photos') %}
{% else %}
{% set library_type = _('Items') %}
{% endif %}
{% if items[section]['media_percent_complete'] == 100 %}
{% set progress_bar_color = 'bg-success' %}
{% elif items[section]['media_percent_complete'] > 50 %}
Expand Down

0 comments on commit e373cd3

Please sign in to comment.