#NEWLINE# def get_date_range( self ) : #NEWLINE# #INDENT# if ( ( not hasattr ( self , 'start' ) ) or ( not hasattr ( self , 'end' ) ) ) : #NEWLINE# #INDENT# args_start = ( self . today . year , self . today . month , 1 ) #NEWLINE# args_end = ( self . today . year , self . today . month , self . today . day ) #NEWLINE# form = self . get_form ( ) #NEWLINE# if form . is_valid ( ) : #NEWLINE# #INDENT# start = form . cleaned_data [ 'start' ] #NEWLINE# end = form . cleaned_data [ 'end' ] #NEWLINE# args_start = ( start . year , start . month , start . day ) #NEWLINE# args_end = ( end . year , end . month , end . day ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if form . is_bound : #NEWLINE# #INDENT# messages . error ( self . request , _ ( 'Invalid date format: Using today as default.' ) ) #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# self . start = self . get_start ( * args_start ) #NEWLINE# self . end = self . get_end ( * args_end ) #NEWLINE# return ( self . start , self . end )