version 1.10.2.50, 2008/08/26 15:01:41
|
version 1.10.2.53, 2008/08/28 18:20:09
|
Line 13 from Products.versionedFile.extVersioned
|
Line 13 from Products.versionedFile.extVersioned
|
import os |
import os |
import logging |
import logging |
import bibliography |
import bibliography |
|
import email |
from Globals import package_home |
from Globals import package_home |
from Products.PythonScripts.standard import sql_quote |
from Products.PythonScripts.standard import sql_quote |
from types import * |
from types import * |
from AccessControl import ClassSecurityInfo |
from AccessControl import ClassSecurityInfo |
import time |
import time |
import logging |
import logging |
|
import email |
#ersetzt logging |
#ersetzt logging |
def logger(txt,method,txt2): |
def logger(txt,method,txt2): |
"""logging""" |
"""logging""" |
Line 91 class MPIWGStaff(CatalogAware,ZSQLExtend
|
Line 92 class MPIWGStaff(CatalogAware,ZSQLExtend
|
addStr="&time=%s" |
addStr="&time=%s" |
else: |
else: |
addStr="?time=%s" |
addStr="?time=%s" |
|
|
|
RESPONSE.setHeader('Last-Modified',email.Utils.formatdate().split("-")[0]+'GMT') |
|
logging.error(email.Utils.formatdate()+' GMT') |
RESPONSE.redirect(url+addStr%timeStamp) |
RESPONSE.redirect(url+addStr%timeStamp) |
|
|
def getKey(self): |
def getKey(self): |
Line 149 class MPIWGStaff(CatalogAware,ZSQLExtend
|
Line 153 class MPIWGStaff(CatalogAware,ZSQLExtend
|
self.publicationSelectionMode=publicationSelectionMode |
self.publicationSelectionMode=publicationSelectionMode |
|
|
if RESPONSE: |
if RESPONSE: |
self.redirect(RESPONSE,"editPublications") |
self.redirect(RESPONSE,"<Publications") |
|
|
|
|
def downloadCV(self,RESPONSE): |
def downloadCV(self,RESPONSE): |
Line 370 class MPIWGStaff(CatalogAware,ZSQLExtend
|
Line 374 class MPIWGStaff(CatalogAware,ZSQLExtend
|
# self.REQUEST.RESPONSE.redirect(redURL) |
# self.REQUEST.RESPONSE.redirect(redURL) |
|
|
pt=PageTemplateFile(os.path.join(package_home(globals()),'zpt','editMPIWGStaff.zpt')).__of__(self) |
pt=PageTemplateFile(os.path.join(package_home(globals()),'zpt','editMPIWGStaff.zpt')).__of__(self) |
|
|
|
|
|
logging.error("XX:"+email.Utils.formatdate().split("-")[0]+'GMT') |
return pt() |
return pt() |
|
|
mainEditFile=PageTemplateFile(os.path.join(package_home(globals()),'zpt','editMPIWGStaff_main.zpt')) |
mainEditFile=PageTemplateFile(os.path.join(package_home(globals()),'zpt','editMPIWGStaff_main.zpt')) |
Line 384 class MPIWGStaff(CatalogAware,ZSQLExtend
|
Line 391 class MPIWGStaff(CatalogAware,ZSQLExtend
|
return style |
return style |
|
|
|
|
|
def getLabel(self): |
|
"""returns a label for this object""" |
|
return self.title |
|
|
|
def getBreadcrumbs(self): |
|
"""return list of breadcrumbs from here to the root""" |
|
crumbs = [] |
|
# skip direct parent Folder /members/ |
|
parent = self.aq_parent.aq_parent |
|
# get parents breadcrumbs |
|
logging.debug("getbreadcrumbs-: title=%s self=%s parent=%s"%(self.title, repr(self), repr(parent))) |
|
if hasattr(parent, 'getBreadcrumbs'): |
|
logging.debug("getbreadcrumbs: recurse to %s"%parent) |
|
crumbs = parent.getBreadcrumbs() |
|
|
|
# try to get acquisition URL from parent |
|
if hasattr(parent, 'absolute_url'): |
|
baseUrl = "%s/%s/"%(parent.absolute_url(), 'members') |
|
else: |
|
baseUrl = "/en/staff/members/" |
|
|
|
# add this |
|
crumbs.append((self.getLabel(), baseUrl+self.getId(), self)) |
|
|
|
return crumbs |
|
|
|
|
def changeCurrentWork(self,current_work,key,publish="yes",RESPONSE=None): |
def changeCurrentWork(self,current_work,key,publish="yes",RESPONSE=None): |
"""change current work""" |
"""change current work""" |
|
|
Line 468 class MPIWGStaff(CatalogAware,ZSQLExtend
|
Line 502 class MPIWGStaff(CatalogAware,ZSQLExtend
|
|
|
def getProfile(self): |
def getProfile(self): |
"""get the profile""" |
"""get the profile""" |
|
self.REQUEST.RESPONSE.setHeader('Last-Modified',email.Utils.formatdate().split("-")[0]+'GMT') |
|
|
founds=self.ZSQLInlineSearchU(_table='personal_www',key=self.getKey()) |
founds=self.ZSQLInlineSearchU(_table='personal_www',key=self.getKey()) |
html="""<html><body>%s</body></html>""" |
html="""<html><body>%s</body></html>""" |
if founds.profile and founds.profile != "": |
if founds.profile and founds.profile != "": |