mirror of
https://github.com/ngfchl/ptools
synced 2023-07-10 13:41:22 +08:00
1. 修复容器名称与环境变量已正确显示无法重启的bug
2. 发布更新说明
This commit is contained in:
@@ -3,6 +3,7 @@ import os
|
||||
import subprocess
|
||||
from datetime import datetime
|
||||
|
||||
import markdown
|
||||
from django.http import JsonResponse
|
||||
from django.shortcuts import render
|
||||
|
||||
@@ -126,10 +127,10 @@ def do_update(request):
|
||||
|
||||
|
||||
def restart_container(request):
|
||||
# scraper = pt_spider.get_scraper()
|
||||
# res = scraper.get('https://gitee.com/ngfchl/ptools/raw/master/update.md')
|
||||
# update_notes = markdown.markdown(res.text, extensions=['tables'])
|
||||
# print(update_notes)
|
||||
scraper = pt_spider.get_scraper()
|
||||
res = scraper.get('https://gitee.com/ngfchl/ptools/raw/master/update.md')
|
||||
update_notes = markdown.markdown(res.text, extensions=['tables'])
|
||||
print(update_notes)
|
||||
return render(request, 'auto_pt/restart.html',
|
||||
# context={'update_notes': update_notes}
|
||||
context={'update_notes': update_notes}
|
||||
)
|
||||
|
||||
@@ -770,7 +770,7 @@ class PtSpider:
|
||||
# leech = self.get_user_torrent(leeching_html, site.leech_rule)
|
||||
# seed = self.get_user_torrent(seeding_html, site.seed_rule)
|
||||
leech = ''.join(details_html.xpath(site.leech_rule)).strip()
|
||||
seed = ''.join(details_html.xpath(site.leech_rule)).strip()
|
||||
seed = ''.join(details_html.xpath(site.seed_rule)).strip()
|
||||
# seed = len(seed_vol_list)
|
||||
ratio = ''.join(details_html.xpath(site.ratio_rule)).replace(',', '').strip(']:').strip()
|
||||
if ratio == '无限' or ratio == '∞' or ratio == '---':
|
||||
|
||||
@@ -18,7 +18,12 @@
|
||||
<ul v-for="item in update_note">
|
||||
<li v-text="item"></li>
|
||||
</ul>
|
||||
{# {{ update_notes|safe }}#}
|
||||
<el-card class="box-card">
|
||||
<div class="text item">
|
||||
{{ update_notes|safe }}
|
||||
</div>
|
||||
</el-card>
|
||||
|
||||
</div>
|
||||
</el-card>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user