#NEWLINE# @ property #NEWLINE# def url_path( self ) : #NEWLINE# #INDENT# rv = Record . url_path . __get__ ( self ) . rstrip ( '/' ) #NEWLINE# last_part = rv . rsplit ( '/' ) [ ( - 1 ) ] #NEWLINE# if ( '.' not in last_part ) : #NEWLINE# #INDENT# rv += '/' #NEWLINE# #UNINDENT# if ( self . page_num in ( 1 , None ) ) : #NEWLINE# #INDENT# return rv #NEWLINE# #UNINDENT# if ( '.' in last_part ) : #NEWLINE# #INDENT# raise RuntimeError ( 'When file extensions is provided pagination cannot be used.' ) #NEWLINE# #UNINDENT# return ( '%s%s/%d/' % ( rv , self . datamodel . pagination_config . url_suffix . strip ( '/' ) , self . page_num ) )