comparison web/templog.py @ 283:788d713f6b87

merge
author Matt Johnston <matt@ucc.asn.au>
date Mon, 30 Nov 2015 21:45:17 +0800
parents 0a1c02160e66 6c14e0573f50
children 8441916e3095
comparison
equal deleted inserted replaced
282:d3ebdb1d6a55 283:788d713f6b87
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.