From b7c4ee746dafd27fd0e4e1099fa6f85d9786bc1b Mon Sep 17 00:00:00 2001 From: ngfchl Date: Sun, 2 Oct 2022 08:41:12 +0800 Subject: [PATCH] =?UTF-8?q?=E6=A0=B9=E6=8D=AEtracker=E5=9C=B0=E5=9D=80?= =?UTF-8?q?=E8=BF=94=E5=9B=9E=E7=AB=99=E7=82=B9=E5=90=8D=E7=A7=B0=EF=BC=8C?= =?UTF-8?q?=E5=B9=B6=E5=AE=9E=E7=8E=B0=E7=AD=9B=E9=80=89=E7=AD=9B=E9=80=89?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- auto_pt/views.py | 4 +-- templates/auto_pt/downloading.html | 51 +++++++++++++++++++++++++----- 2 files changed, 45 insertions(+), 10 deletions(-) diff --git a/auto_pt/views.py b/auto_pt/views.py index 137f474..56b9d9a 100644 --- a/auto_pt/views.py +++ b/auto_pt/views.py @@ -97,7 +97,7 @@ def get_downloading(request): id = request.GET.get('id') print(id) downloader = Downloader.objects.filter(id=id).first() - tracker_filters = Site.objects.all().values('id', 'name', 'tracker') + tracker_list = Site.objects.all().values('id', 'name', 'tracker') qb_client = qbittorrentapi.Client( host=downloader.host, port=downloader.port, @@ -163,7 +163,7 @@ def get_downloading(request): print(len(torrents)) main_data['torrents'] = torrents # print(tracker_filters) - main_data['tracker_filters'] = list(tracker_filters) + main_data['tracker_list'] = list(tracker_list) # return JsonResponse(CommonResponse.success(data=torrents).to_dict(), safe=False) return JsonResponse(CommonResponse.success(data=main_data).to_dict(), safe=False) except Exception as e: diff --git a/templates/auto_pt/downloading.html b/templates/auto_pt/downloading.html index 80a068e..f401217 100644 --- a/templates/auto_pt/downloading.html +++ b/templates/auto_pt/downloading.html @@ -58,7 +58,10 @@ @click="handleButtonClick(downloader.id)"> - 停止刷新 + 停止刷新 + + 停止刷新 + 操作 @@ -153,6 +156,13 @@ :filter-method="filterStateMethod" :filter-multiple="false" title="分类"> + @@ -198,9 +208,6 @@ show-header-overflow show-overflow="tooltip" show-footer-overflow title="添加时间"> - -