#NEWLINE# def get_issues( self , project_id = None , tracker = None , status = None , page = 0 , custom = None ) : #NEWLINE# #INDENT# "\n        Get paginated list of all issues, returns one page at a time\n        GET $base/issues.xml?page=$page&project_id=$project&tracker_id=$tracker&status_id=$status\n\n        Creating an issue should probably be part of this test...\n        >>> r = RedmineClient('http://redmine.example.com', 'test_username', 'test_password', 'test_key')\n        >>> l = r.get_issues(1)\n        >>> len(l) > 0\n        True\n        " #NEWLINE# urlArgs = { #NEWLINE# #INDENT# 'key' : self . key , #NEWLINE# 'page' : page , #NEWLINE# #UNINDENT# } #NEWLINE# if ( project_id is not None ) : #NEWLINE# #INDENT# urlArgs [ 'project_id' ] = project_id #NEWLINE# #UNINDENT# if ( tracker is not None ) : #NEWLINE# #INDENT# urlArgs [ 'tracker_id' ] = tracker #NEWLINE# #UNINDENT# if ( status is not None ) : #NEWLINE# #INDENT# urlArgs [ 'status_id' ] = status #NEWLINE# #UNINDENT# if ( custom is not None ) : #NEWLINE# #INDENT# if ( type ( custom ) . __name__ == 'dict' ) : #NEWLINE# #INDENT# for cf_id in custom : #NEWLINE# #INDENT# urlArgs [ ( 'cf_%d' % cf_id ) ] = custom [ cf_id ] #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# url = ( '%s/issues.xml?%s' % ( self . base , urllib . urlencode ( urlArgs ) ) ) #NEWLINE# ( response , content ) = self . _request ( url , 'GET' ) #NEWLINE# issues = [ ] #NEWLINE# issuesRoot = minidom . parseString ( content ) #NEWLINE# issuesList = issuesRoot . documentElement . getElementsByTagName ( 'issue' ) #NEWLINE# for issue in issuesList : #NEWLINE# #INDENT# issues . append ( RedmineIssue ( issue ) ) #NEWLINE# #UNINDENT# return issues