--- MPIWGWeb/Attic/MPIWGRoot.py 2010/07/15 10:20:17 1.1.2.28 +++ MPIWGWeb/Attic/MPIWGRoot.py 2012/01/03 09:26:45 1.1.2.32 @@ -67,6 +67,17 @@ class MPIWGRoot(ZSQLExtendFolder): # types of objects that show up in navigation nav_meta_types = ['MPIWGTemplate','MPIWGLink','MPIWGFolder'] + manage_options = Folder.manage_options+( + {'label':'Update personal homepages','action':'updatePersonalwww_html'}, + {'label':'Reindex catalogs','action':'reindexCatalogs'}, + {'label':'Main config','action':'changeMPIWGRootForm'}, + {'label':'add e-mails','action':'showNewDBEntries'}, + #{'label':'update the institutsbibliography','action':'updateInstitutsbiliography'}, + #{'label':'Edit Historical Persons','action':'editHistoricalPersonsForm'}, + #{'label':'Store Historical Persons','action':'storeHistoricalPersons'}, + ) + + def getGetNeighbourhood(self,obj, wordStr, length=100,tagging=True): """finde umgebung um die worte in wordStr, zurueckgegeben wird eine Array mit den Umgebungen von Fundstellen der Worte alle Tags werden entfernt, die Fundstellen werden mit XX getaggt, die Umgebungen werden @@ -589,15 +600,18 @@ class MPIWGRoot(ZSQLExtendFolder): pt=PageTemplateFile(os.path.join(package_home(globals()),'zpt','changeMPIWGRootForm')).__of__(self) return pt() - def changeMPIWGRoot(self,title,disciplineList,themesList,connection_id,lang=None,RESPONSE=None): + def changeMPIWGRoot(self,title,connection_id,coneServiceURL,lang=None,autocommit=None,RESPONSE=None): """change""" self.title=title self.connection_id=connection_id - self.disciplineList=disciplineList - self.themesList=themesList + #self.disciplineList=disciplineList + #self.themesList=themesList + self.coneServiceURL=coneServiceURL + if lang is not None: self.lang = lang + self.autocommit = (autocommit == "on") if RESPONSE is not None: RESPONSE.redirect('manage_main') @@ -683,17 +697,6 @@ class MPIWGRoot(ZSQLExtendFolder): return projects - manage_options = Folder.manage_options+( - {'label':'Update personal homepages','action':'updatePersonalwww_html'}, - {'label':'Reindex catalogs','action':'reindexCatalogs'}, - {'label':'Main config','action':'changeMPIWGRootForm'}, - {'label':'add e-mails','action':'showNewDBEntries'}, - {'label':'update the institutsbibliography','action':'updateInstitutsbiliography'}, - #{'label':'Edit Historical Persons','action':'editHistoricalPersonsForm'}, - #{'label':'Store Historical Persons','action':'storeHistoricalPersons'}, - ) - - def updatePublicationDB(self,personId=None): """updates the publication db, i.e. copy year and type into the main table""" @@ -791,7 +794,7 @@ class MPIWGRoot(ZSQLExtendFolder): if ignoreEntries is None: ignoreEntries = [] - ignoreEntries.append('current_work') # TODO:updatecurrent work + #ignoreEntries.append('current_work') # TODO:updatecurrent work logging.debug("updatePersonEntry: data=%s ignoreEntries=%s"%(repr(data),repr(ignoreEntries))) if data['date_to']=="": # wenn date_to leer @@ -883,7 +886,7 @@ class MPIWGRoot(ZSQLExtendFolder): ret+="" for iE in displayIgnored: ret+=""%(iE[0].encode('utf-8'),iE[1].encode('utf-8'),iE[2].encode('utf-8')) - ret+="" + ret+="
%s%s%s
" self.updatePersonEntry(resultSet[conflict],ignoreEntries=ignoreEntries)