Mercurial > hg > MPIWGWeb
diff MPIWGRoot.py @ 53:e718d9a72f19
bibliographie funktionen
author | dwinter |
---|---|
date | Tue, 30 Apr 2013 16:31:57 +0200 |
parents | cacba38c268c |
children | 4600e31a0431 |
line wrap: on
line diff
--- a/MPIWGRoot.py Mon Apr 29 16:02:24 2013 +0200 +++ b/MPIWGRoot.py Tue Apr 30 16:31:57 2013 +0200 @@ -1314,6 +1314,30 @@ logging.debug(ret) return ret + + + def getAllProjectPublications(self): + """get all publications""" + fw=file("/tmp/allProjectPublications","w") + projects =self.projects.getProjectsAsList(None,active=0,archived=0) + + for project in projects: + logging.debug(project) + if hasattr(project,'publicationList'): + try: + x =project.publicationList.bibliolist.data + + except: + logging.error("Can't do: %s"%project.absolute_url()) + continue + + id=project.getId() + for l in x.split("\n"): + fw.write("%s,%s\n"%(id,l)) + fw.flush() + + fw.close() + def manage_addMPIWGRootForm(self):