#NEWLINE# def _model_indexes_sql( self , model ) : #NEWLINE# #INDENT# '\n        Return all index SQL statements (field indexes, index_together) for the\n        specified model, as a list.\n        ' #NEWLINE# if ( ( not model . _meta . managed ) or model . _meta . proxy or model . _meta . swapped ) : #NEWLINE# #INDENT# return [ ] #NEWLINE# #UNINDENT# output = [ ] #NEWLINE# for field in model . _meta . local_fields : #NEWLINE# #INDENT# if ( field . db_index and ( not field . unique ) ) : #NEWLINE# #INDENT# output . append ( self . _create_index_sql ( model , [ field ] , suffix = '' ) ) #NEWLINE# #UNINDENT# #UNINDENT# for field_names in model . _meta . index_together : #NEWLINE# #INDENT# fields = [ model . _meta . get_field ( field ) for field in field_names ] #NEWLINE# output . append ( self . _create_index_sql ( model , fields , suffix = '_idx' ) ) #NEWLINE# #UNINDENT# return output