#NEWLINE# def post( self ) : #NEWLINE# #INDENT# ' Handler for POST requests. ' #NEWLINE# user_email = self . request . get ( 'user_email' ) . lstrip ( ) . rstrip ( ) #NEWLINE# if self . helper . login_user ( user_email , self . request . get ( 'user_password' ) , self . response ) : #NEWLINE# #INDENT# if ( self . request . get ( 'continue' ) != '' ) : #NEWLINE# #INDENT# continue_url = self . request . get ( 'continue' ) . encode ( 'ascii' , 'ignore' ) #NEWLINE# self . redirect ( continue_url , self . response ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# self . redirect ( '/' , self . response ) #NEWLINE# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# flash_message = 'Incorrect username / password combination. Please try again.' #NEWLINE# show_create_account = True #NEWLINE# if AppDashboardHelper . USE_SHIBBOLETH : #NEWLINE# #INDENT# show_create_account = False #NEWLINE# #UNINDENT# self . render_page ( page = 'users' , template_file = self . TEMPLATE , values = { #NEWLINE# #INDENT# 'continue' : self . request . get ( 'continue' ) , #NEWLINE# 'user_email' : user_email , #NEWLINE# 'flash_message' : flash_message , #NEWLINE# 'show_create_account' : show_create_account , #NEWLINE# #UNINDENT# } )