diff --git a/deluge/ui/webui/render.py b/deluge/ui/webui/render.py index b738e1bd8..671be34e1 100644 --- a/deluge/ui/webui/render.py +++ b/deluge/ui/webui/render.py @@ -129,7 +129,10 @@ def template_sort_head(id,name): return render.sort_column_head(id, name, order, active_up, active_down) def template_part_stats(): - return render.part_stats(get_stats()) + try: + return render.part_stats(get_stats()) + except Exception: + return '[not connected]' def get_config(var): return ws.config.get(var) diff --git a/deluge/ui/webui/templates/advanced/part_stats.html b/deluge/ui/webui/templates/advanced/part_stats.html index 4600dbc28..92ee49e4b 100644 --- a/deluge/ui/webui/templates/advanced/part_stats.html +++ b/deluge/ui/webui/templates/advanced/part_stats.html @@ -1,7 +1,7 @@ $def with (stats) -
| @@ -71,14 +71,14 @@ $for torrent in torrent_list: $else: 0 | - $if (torrent.download_rate): - $fspeed(torrent.download_rate) + $if (torrent.download_payload_rate): + $fspeed(torrent.download_payload_rate) $else: | - $if (torrent.upload_rate): - $fspeed(torrent.upload_rate) + $if (torrent.upload_payload_rate): + $fspeed(torrent.upload_payload_rate) $else: | diff --git a/deluge/ui/webui/templates/deluge/index.html b/deluge/ui/webui/templates/deluge/index.html index 5d2627a5c..4c192cd02 100644 --- a/deluge/ui/webui/templates/deluge/index.html +++ b/deluge/ui/webui/templates/deluge/index.html @@ -7,7 +7,7 @@ $if organize_filters:
| $torrent.queue | $torrent.num_seeds ($torrent.total_seeds) | $torrent.num_peers ($torrent.total_peers) | -$fspeed(torrent.download_rate) | -$fspeed(torrent.upload_rate) | +$fspeed(torrent.download_payload_rate) | +$fspeed(torrent.upload_payload_rate) | $ftime(torrent.eta) | $("%.3f" % torrent.distributed_copies) | $("%.3f" % torrent.ratio) | diff --git a/deluge/ui/webui/templates/deluge/tab_meta.html b/deluge/ui/webui/templates/deluge/tab_meta.html index 9055647f1..b6309f9fe 100644 --- a/deluge/ui/webui/templates/deluge/tab_meta.html +++ b/deluge/ui/webui/templates/deluge/tab_meta.html @@ -11,10 +11,10 @@ $def with (torrent)
| $_('Downloaded'): | -$torrent.calc_total_downloaded | $fsize(torrent.total_done) | |||||
| $_('Uploaded'): | -$torrent.calc_total_uploaded | +$fsize(torrent.total_payload_upload) | |||||
| $_('Seeders'): | @@ -41,10 +41,10 @@ $else:
| $_('Speed'): | -$fspeed(torrent.download_rate) |
| $_('Speed'): | -$fspeed(torrent.upload_rate) | $fspeed(torrent.upload_payload_rate) |
| $_('Peers'): | $torrent.num_peers ($torrent.total_peers ) |