From fc2dcdb4e3fac7c47fba2904e655d01d77f56d97 Mon Sep 17 00:00:00 2001 From: ngfchl Date: Wed, 28 Sep 2022 09:24:40 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BB=BB=E5=8A=A1=E7=8A=B6=E6=80=81=E8=B0=83?= =?UTF-8?q?=E6=95=B4=E4=B8=BA=E5=89=8D=E7=AB=AF=E8=BF=87=E6=BB=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- auto_pt/views.py | 2 +- templates/auto_pt/downloading.html | 82 +++++++++++++++++++++++------- 2 files changed, 64 insertions(+), 20 deletions(-) diff --git a/auto_pt/views.py b/auto_pt/views.py index e108629..f86392e 100644 --- a/auto_pt/views.py +++ b/auto_pt/views.py @@ -141,7 +141,7 @@ def get_downloading(request): 'day,', '天' ).replace(':', '小时', 1).replace(':', '分', 1).split('.')[0] + '秒' # 大小与速度处理 - torrent['state'] = TorrentBaseInfo.download_state.get(torrent.get('state')) + # torrent['state'] = TorrentBaseInfo.download_state.get(torrent.get('state')) torrent['ratio'] = '%.4f' % torrent.get('ratio') if torrent['ratio'] >= 0.0001 else 0 torrent['progress'] = '%.4f' % torrent.get('progress') if float(torrent['progress']) < 1 else 1 torrent['uploaded'] = '' if torrent['uploaded'] == 0 else torrent['uploaded'] diff --git a/templates/auto_pt/downloading.html b/templates/auto_pt/downloading.html index 7ff3ffb..1ded367 100644 --- a/templates/auto_pt/downloading.html +++ b/templates/auto_pt/downloading.html @@ -60,7 +60,7 @@
#}