Esempio n. 1
0
def page_not_found(request, **kwargs):
  t = kwargs.get('template', '404.html')
  return render_response(request, t, response_class=http.HttpResponseNotFound)
Esempio n. 2
0
def server_error(request, **kwargs):
  t = kwargs.get('template', '500.html')
  return render_response(request, t, response_class=http.HttpResponseServerError)
Esempio n. 3
0
def auto(request, **kwargs):
  try:
    t = kwargs['template']
  except KeyError:
    raise http.Http404
  return render_response(request, t)