mirror of
https://github.com/ngfchl/ptools
synced 2023-07-10 13:41:22 +08:00
1. 优化更新提示
This commit is contained in:
@@ -193,14 +193,6 @@ def do_update(request):
|
||||
result.append(i.decode('utf8'))
|
||||
print(result)
|
||||
# 更新数据库
|
||||
# with open('main_pt_site_site.sql', encoding='utf-8') as sql_file:
|
||||
# contents = sql_file.readlines()
|
||||
# print(contents[0])
|
||||
# with connection.cursor() as cursor:
|
||||
# for statement in contents:
|
||||
# cursor.execute(statement)
|
||||
# Site.objects.raw()
|
||||
# 更新数据库
|
||||
with open('./pt_site_site.json', 'r') as f:
|
||||
# print(f.readlines())
|
||||
data = json.load(f)
|
||||
|
||||
Reference in New Issue
Block a user