version 1.10.2.3, 2005/10/10 19:10:13
|
version 1.10.2.4, 2005/10/11 13:14:01
|
Line 201 class MPIWGStaff(CatalogAware,ZSQLExtend
|
Line 201 class MPIWGStaff(CatalogAware,ZSQLExtend
|
pt=PageTemplateFile(os.path.join(package_home(globals()),'zpt','editTeaching.zpt')).__of__(self) |
pt=PageTemplateFile(os.path.join(package_home(globals()),'zpt','editTeaching.zpt')).__of__(self) |
return pt() |
return pt() |
|
|
|
def getDocTypes(self): |
|
finds = self.ZopeFind(self.metadata.main.meta.bib,obj_metatypes=["OSAS_MetadataMapping__neu"]) |
|
|
|
list= [x[0] for x in finds] |
|
return "\n".join(list) |
|
|
|
def newBibliography(self,_docType=None, _addEntry=None,RESPONSE=None,**argv): |
|
"""add an entry to the bibliography""" |
|
if not _docType: #kein docType |
|
pt=PageTemplateFile(os.path.join(package_home(globals()),'zpt','newBibliographyEntryDocType.zpt')).__of__(self) |
|
return pt() |
|
elif _docType and not _addEntry: #doctype aber keine daten |
|
self.REQUEST['_docType']=_docType |
|
pt=PageTemplateFile(os.path.join(package_home(globals()),'zpt','newBibliographyEntry.zpt')).__of__(self) |
|
return pt() |
|
else: #doctype und daten |
|
newId=self.ZSQLSimpleSearch("select nextval('id_raw')")[0].nextval |
|
bookId="b%06i" % newId |
|
|
|
self.ZSQLAdd(argv,_table="bibliography",reference_type=_docType,id=bookId) |
|
self.ZSQLAdd(_table="publications",id_gen_bib=bookId,id_main=self.getDBId(),publish='yes') |
|
self.updatePublicationDB(personId=self.getDBId()) |
|
|
|
|
|
if RESPONSE: |
|
RESPONSE.redirect("editPublications") |
|
|
|
return True |
|
|
def editBibliography(self): |
def editBibliography(self): |
"""edit the bibliography""" |
"""edit the bibliography""" |
pt=PageTemplateFile(os.path.join(package_home(globals()),'zpt','editBibliographyEntry.zpt')).__of__(self) |
pt=PageTemplateFile(os.path.join(package_home(globals()),'zpt','editBibliographyEntry.zpt')).__of__(self) |
Line 227 class MPIWGStaff(CatalogAware,ZSQLExtend
|
Line 256 class MPIWGStaff(CatalogAware,ZSQLExtend
|
"""get sorting mode""" |
"""get sorting mode""" |
return getattr(self,'sortingMode','priority') |
return getattr(self,'sortingMode','priority') |
|
|
|
def integer(self,value): |
|
try: |
|
return int(value) |
|
except: |
|
return 0 |
|
|
|
|
def changePublications(self): |
def changePublications(self): |
"""change the publication list""" |
"""change the publication list""" |
|
|
self.updatePublicationDB(personId=self.getDBId()) |
|
self.changeResearch(noredirect=True) |
self.changeResearch(noredirect=True) |
|
|
|
#self.updatePublicationDB(personId=self.getDBId()) |
self.REQUEST.RESPONSE.redirect(self.REQUEST['HTTP_REFERER']) |
self.REQUEST.RESPONSE.redirect(self.REQUEST['HTTP_REFERER']) |
|
|
|
|
|
|
def addPublications(self,submit=None,REQUEST=None,noredirect=None): |
def addPublications(self,submit=None,REQUEST=None,noredirect=None): |
"""add publications""" |
"""add publications""" |
|
|