mirror of
https://github.com/ngfchl/ptools
synced 2023-07-10 13:41:22 +08:00
1. 优化更新规则逻辑,日志中打印规则更新记录
This commit is contained in:
@@ -174,7 +174,7 @@ def restart_container(request):
|
||||
utc_time = datetime.strptime(started_at, UTC_FORMAT)
|
||||
delta = (datetime.now() - utc_time).seconds
|
||||
except Exception as e:
|
||||
delta = ''
|
||||
delta = '请确认项目是否在容器中运行?'
|
||||
if get_update_logs():
|
||||
update = 'false'
|
||||
update_tips = '目前您使用的是最新版本!'
|
||||
@@ -210,6 +210,7 @@ def do_update(request):
|
||||
print(data[2])
|
||||
print(data[0].get('url'))
|
||||
xpath_update = []
|
||||
print('更新规则中,返回结果为True为新建,为False为更新,其他是错误了')
|
||||
for site in data:
|
||||
if site.get('pk'):
|
||||
del site['pk']
|
||||
|
||||
@@ -134,8 +134,6 @@
|
||||
type: 'success',
|
||||
message: res.data.msg
|
||||
});
|
||||
location.reload()
|
||||
|
||||
} else {
|
||||
console.log(res)
|
||||
this.$message({
|
||||
@@ -143,7 +141,6 @@
|
||||
message: res.data.msg
|
||||
});
|
||||
}
|
||||
|
||||
}).catch(res => {
|
||||
this.$message({
|
||||
type: 'error',
|
||||
|
||||
Reference in New Issue
Block a user