comparison web/templog.py @ 582:cebec9b40ad2

merge
author Matt Johnston <matt@ucc.asn.au>
date Mon, 30 Nov 2015 21:45:17 +0800
parents 2773400f9d64 b4d6f1ae0b9e
children 8441916e3095
comparison
equal deleted inserted replaced
580:2ab866ee4f8c 582:cebec9b40ad2
92 92
93 @route('/set') 93 @route('/set')
94 def set(): 94 def set():
95 allowed = ["false", "true"][secure.check_user_hash(config.ALLOWED_USERS)] 95 allowed = ["false", "true"][secure.check_user_hash(config.ALLOWED_USERS)]
96 response.set_header('Cache-Control', 'no-cache') 96 response.set_header('Cache-Control', 'no-cache')
97 inline_data = log.get_params()
98 if not inline_data:
99 response.status = 503 # Service Unavailable
100 return bottle.template('noparamsyet')
101
97 return bottle.template('set', 102 return bottle.template('set',
98 inline_data = log.get_params(), 103 inline_data = inline_data,
99 csrf_blob = secure.get_csrf_blob(), 104 csrf_blob = secure.get_csrf_blob(),
100 allowed = allowed) 105 allowed = allowed)
101 106
102 def get_request_zoom(): 107 def get_request_zoom():
103 """ returns (length, end) tuple. 108 """ returns (length, end) tuple.