#NEWLINE# def document_view( request , * args , **kwargs ) : #NEWLINE# #INDENT# context = kwargs #NEWLINE# if kwargs . get ( 'current_page' , False ) : #NEWLINE# #INDENT# documents = Document . objects . filter ( page = kwargs [ 'current_page' ] ) #NEWLINE# context [ 'documents' ] = documents #NEWLINE# #UNINDENT# if ( 'document_id' in kwargs ) : #NEWLINE# #INDENT# document = Document . objects . get ( pk = int ( kwargs [ 'document_id' ] ) ) #NEWLINE# context [ 'document' ] = document #NEWLINE# #UNINDENT# context [ 'in_document_view' ] = True #NEWLINE# return render ( context , 'pages/examples/index.html' , context )