def check_config(request):
mimetype = 'application/json'
data = {}
if request.method == 'POST' and 'entity' in request.POST and request.POST['entity'] != '':
client_name, check_name = request.POST['entity'].split(':')
#check_name = 'check_gw_tomcat_errors_1h'
#data = cache.get('check_' + check_name)
data = cache.get('check_' + request.POST['entity'])
return HttpResponse(json.dumps(data), mimetype)
#@login_required(login_url=reverse_lazy('login'))
评论列表
文章目录