Added successful completion message to tasks progress toast.

pull/1407/head
morpheus65535 4 years ago
parent e23956278b
commit 821ff13b80

@ -64,6 +64,12 @@ def sync_episodes():
else:
episodes_to_add.append(episodeParser(episode))
show_progress(id='episodes_progress',
header='Syncing episodes...',
name='Completed successfully',
value=series_count,
count=series_count)
hide_progress(id='episodes_progress')
# Remove old episodes from DB

@ -87,6 +87,12 @@ def update_movies():
movie_default_profile=movie_default_profile,
audio_profiles=audio_profiles))
show_progress(id='movies_progress',
header='Syncing movies...',
name='Completed successfully',
value=movies_count,
count=movies_count)
hide_progress(id='movies_progress')
# Remove old movies from DB

@ -67,6 +67,12 @@ def update_series():
tags_dict=tagsDict, serie_default_profile=serie_default_profile,
audio_profiles=audio_profiles))
show_progress(id='series_progress',
header='Syncing series...',
name='Completed successfully',
value=series_count,
count=series_count)
hide_progress(id='series_progress')
# Remove old series from DB

@ -811,6 +811,12 @@ def series_download_subtitles(no):
logging.info("BAZARR All providers are throttled")
break
show_progress(id='series_search_progress_{}'.format(no),
header='Searching missing subtitles...',
name='Completed successfully',
value=count_episodes_details,
count=count_episodes_details)
hide_progress(id='series_search_progress_{}'.format(no))
@ -937,6 +943,12 @@ def movies_download_subtitles(no):
logging.info("BAZARR All providers are throttled")
break
show_progress(id='movie_search_progress_{}'.format(no),
header='Searching missing subtitles...',
name='Completed successfully',
value=count_movie,
count=count_movie)
hide_progress(id='movie_search_progress_{}'.format(no))
@ -1109,6 +1121,12 @@ def wanted_search_missing_subtitles_series():
logging.info("BAZARR All providers are throttled")
return
show_progress(id='wanted_episodes_progress',
header='Searching subtitles...',
name='Completed successfully',
value=count_episodes,
count=count_episodes)
hide_progress(id='wanted_episodes_progress')
logging.info('BAZARR Finished searching for missing Series Subtitles. Check History for more information.')
@ -1135,6 +1153,12 @@ def wanted_search_missing_subtitles_movies():
logging.info("BAZARR All providers are throttled")
return
show_progress(id='wanted_movies_progress',
header='Searching subtitles...',
name='Completed successfully',
value=count_movies,
count=count_movies)
hide_progress(id='wanted_movies_progress')
logging.info('BAZARR Finished searching for missing Movies Subtitles. Check History for more information.')
@ -1357,7 +1381,7 @@ def upgrade_subtitles():
if settings.general.getboolean('use_sonarr'):
for i, episode in enumerate(episodes_to_upgrade, 1):
show_progress(id='upgrade_episodes_progress',
header='Upgrading subtitles...',
header='Upgrading episodes subtitles...',
name='{0} - S{1:02d}E{2:02d} - {3}'.format(episode['seriesTitle'],
episode['season'],
episode['episode'],
@ -1419,14 +1443,18 @@ def upgrade_subtitles():
language_code, provider, score, subs_id, subs_path)
send_notifications(episode['sonarrSeriesId'], episode['sonarrEpisodeId'], message)
hide_progress(id='upgrade_episodes_progress')
show_progress(id='upgrade_episodes_progress',
header='Upgrading episodes subtitles...',
name='Completed successfully',
value=count_episode_to_upgrade,
count=count_episode_to_upgrade)
hide_progress(id='upgrade_episodes_progress')
if settings.general.getboolean('use_radarr'):
for i, movie in enumerate(movies_to_upgrade, 1):
show_progress(id='upgrade_movies_progress',
header='Upgrading subtitles...',
header='Upgrading movies subtitles...',
name=movie['title'],
value=i,
count=count_movie_to_upgrade)
@ -1488,8 +1516,13 @@ def upgrade_subtitles():
history_log_movie(3, movie['radarrId'], message, path, language_code, provider, score, subs_id, subs_path)
send_notifications_movie(movie['radarrId'], message)
show_progress(id='upgrade_movies_progress',
header='Upgrading movies subtitles...',
name='Completed successfully',
value=count_movie_to_upgrade,
count=count_movie_to_upgrade)
hide_progress(id='upgrade_movies_progress')
logging.info('BAZARR Finished searching for Subtitles to upgrade. Check History for more information.')

@ -490,6 +490,12 @@ def series_full_scan_subtitles():
count=count_episodes)
store_subtitles(episode['path'], path_mappings.path_replace(episode['path']))
show_progress(id='episodes_disk_scan',
header='Full disk scan...',
name='Completed successfully',
value=count_episodes,
count=count_episodes)
hide_progress(id='episodes_disk_scan')
gc.collect()
@ -507,6 +513,12 @@ def movies_full_scan_subtitles():
count=count_movies)
store_subtitles_movie(movie['path'], path_mappings.path_replace_movie(movie['path']))
show_progress(id='movies_disk_scan',
header='Full disk scan...',
name='Completed successfully',
value=count_movies,
count=count_movies)
hide_progress(id='movies_disk_scan')
gc.collect()

Loading…
Cancel
Save