--- ECHO_content/ECHO_collection.py 2004/12/06 17:48:39 1.200 +++ ECHO_content/ECHO_collection.py 2005/01/18 15:40:03 1.202 @@ -74,7 +74,7 @@ regexpPage = re.compile(patternPage, re. -def setECHO_collectionInformation(self,title,label,description,contentType,responsible,credits,weight,coordstrs="",viewClassification=""): +def setECHO_collectionInformation(self,title,label,description,contentType,responsible,credits,weight,coordstrs=""): """Allegemeine Informationen zu einer ECHO Collection""" @@ -151,8 +151,6 @@ class ECHO_layoutTemplate(ZopePageTempla def __init__(self, id, text=None, content_type=None,EchoType=None): self.id = str(id) - - self.ZBindings_edit(self._default_bindings) if text is None: self._default_content_fn = os.path.join(package_home(globals()), @@ -160,9 +158,6 @@ class ECHO_layoutTemplate(ZopePageTempla text = open(self._default_content_fn).read() self.pt_edit(text, content_type) - - """change form""" - def manage_addECHO_layoutTemplateForm(self): """Form for adding""" @@ -263,7 +258,7 @@ class ECHO_resource(Folder,Persistent,EC security=ClassSecurityInfo() meta_type='ECHO_resource' - viewClassificationList=viewClassificationListMaster +# viewClassificationList=viewClassificationListMaster getSubCols = ECHO_helpers.getSubCols @@ -665,11 +660,11 @@ class ECHO_resource(Folder,Persistent,EC """template fuer content""" return ECHO_basis.content_html(self,'resource') - def getViewClassification(self): - if hasattr(self,'viewClassification'): - return self.viewClassification - else: - return "" +# def getViewClassification(self): +# if hasattr(self,'viewClassification'): +# return self.viewClassification +# else: +# return "" def getFullTextXML(self,noredirect=None): """getFullTextXML; gives the FullText as an XML Document, and if somthing goes wrong.""" @@ -823,7 +818,7 @@ class ECHO_resource(Folder,Persistent,EC coordsnew=[] self.coords=coordsnew - self.viewClassification="" +# self.viewClassification="" @@ -1005,7 +1000,7 @@ class ECHO_resource(Folder,Persistent,EC self.REQUEST.RESPONSE.setHeader('Content-Type','text/xml') return writeMetadata(self.metalink,self.metaDataHash) - def changeECHO_resource(self,metalink,link,title,label,description,contentType,responsible,weight,viewClassification="",coords=None,credits=None,RESPONSE=None): + def changeECHO_resource(self,metalink,link,title,label,description,contentType,responsible,weight,coords=None,credits=None,RESPONSE=None): """Aenderung der Properties""" setECHO_collectionInformation(self,title,label,description,contentType,responsible,credits,weight) @@ -1429,7 +1424,7 @@ class ECHO_collection(Folder, Persistent security=ClassSecurityInfo() meta_type='ECHO_collection' - viewClassificationList=viewClassificationListMaster +# viewClassificationList=viewClassificationListMaster displayTypes=displayTypes path="/mpiwg/online/permanent/shipbuilding" @@ -1741,11 +1736,11 @@ class ECHO_collection(Folder, Persistent """nothing""" return retStr - def getViewClassification(self): - if hasattr(self,'viewClassification'): - return self.viewClassification - else: - return "" +# def getViewClassification(self): +# if hasattr(self,'viewClassification'): +# return self.viewClassification +# else: +# return "" def createRessourcesFromXMLForm(self): @@ -1927,7 +1922,7 @@ class ECHO_collection(Folder, Persistent security.declarePublic('changeECHO_collection') - def changeECHO_collection(self,title,label,description,contentType,responsible,weight,secondaryLink,secondaryLinkTitle,credits=None,sortfield="weight",coords=None,RESPONSE=None,imageTag="",bgcolour="",viewClassification=None,location=None,isAlwaysClickable=None): + def changeECHO_collection(self,title,label,description,contentType,responsible,weight,secondaryLink,secondaryLinkTitle,credits=None,sortfield="weight",coords=None,RESPONSE=None,imageTag="",bgcolour="",location=None,isAlwaysClickable=None): """Aenderung der Properties""" self.secondaryLink=secondaryLink @@ -2030,10 +2025,10 @@ class ECHO_collection(Folder, Persistent def getAllMapAreas(self): """Give list of coordinates""" - subColTypes=['ECHO_collection','ECHO_resource'] + mapColTypes=['ECHO_collection','ECHO_resource'] areas=[] - for entrySearch in self.ZopeFind(self,obj_metatypes=subColTypes): - object=entrySearch[1] + for entry in self.getSubCols(self,subColTypes=mapColTypes): + object=entry areas.extend(object.getMapAreas()) return areas @@ -2348,7 +2343,15 @@ class ECHO_root(Folder,Persistent,Implic meta_type="ECHO_root" - ###CDLI adds -> have to be removed + # testing templates with macros... ROC +## content_overview_template2 = zptObjectOrFile(None, 'content_overview_template', orphaned=True) +## print "COT: ", content_overview_template2, repr(content_overview_template2) + +## def content_overview_template(self): +## content_overview_template2._cook_check() +## return content_overview_template2() + + ###Cdli adds -> have to be removed def getTablet(self,item): #print "getTablet" try: