#NEWLINE# def on_model_change( self , form , model ) : #NEWLINE# #INDENT# file_data = request . files . get ( form . upload . name ) #NEWLINE# if file_data : #NEWLINE# #INDENT# model . path = secure_filename ( file_data . filename ) #NEWLINE# file_data . save ( op . join ( base_path , self . path ) )