Example #1
0
 def _auth_method_user(self):
     request.uid = request.session.uid
     if not request.uid:
         if not request.params.get('noredirect'):
             query = werkzeug.url_encode({
                 'redirect':
                 request.httprequest.url,
             })
             response = werkzeug.utils.redirect('/web/login?%s' % query)
             werkzeug.exceptions.abort(response)
         raise http.SessionExpiredException("Session expired")
Example #2
0
 def _auth_method_user(self):
     request.uid = request.session.uid
     if not request.uid:
         raise http.SessionExpiredException("Session expired")