Diff for /ECHO_content/ECHO_Nav.py between versions 1.78 and 1.80

version 1.78, 2006/10/23 11:12:24 version 1.80, 2007/02/22 10:29:00
Line 31  import os.path Line 31  import os.path
 import urllib  import urllib
 from ECHO_helpers import displayTypes,checkOnlyOneInGroup  from ECHO_helpers import displayTypes,checkOnlyOneInGroup
 from ECHO_collection import content_html  from ECHO_collection import content_html
 import zLOG  import logging
   
   #def ersetzt logging
   def logger(txt,method,txt2):
       """logging"""
       logging.info(txt+ txt2)
   
   
 try:      try:    
     from Products.ZSQLExtend.ZSQLExtend import ZSQLExtendFolder      from Products.ZSQLExtend.ZSQLExtend import ZSQLExtendFolder
 except:  except:
     zLOG.LOG('ECHO_Nav',zLOG.INFO,'ZSQLSimpleSearch not supported')      logger('ECHO_Nav',logging.INFO,'ZSQLSimpleSearch not supported')
   
   
   
Line 273  class ECHO_sqlElement(SimpleItem): Line 279  class ECHO_sqlElement(SimpleItem):
     try:          try:    
         searchQuery=ZSQLExtendFolder.ZSQLSimpleSearch          searchQuery=ZSQLExtendFolder.ZSQLSimpleSearch
     except:      except:
         zLOG.LOG('ECHO_Nav',zLOG.INFO,'ZSQLSimpleSearch not supported')          logger('ECHO_Nav',logging.INFO,'ZSQLSimpleSearch not supported')
                           
     def getNavList(self):       def getNavList(self): 
         """ausgabe der treffer list fuer navigation"""          """ausgabe der treffer list fuer navigation"""
Line 297  class ECHO_sqlElement(SimpleItem): Line 303  class ECHO_sqlElement(SimpleItem):
                 try:                  try:
                     ret.append((getattr(record,self.field),self.baseUrl+urllib.quote(str(getattr(record,self.getSearchField())))))                      ret.append((getattr(record,self.field),self.baseUrl+urllib.quote(str(getattr(record,self.getSearchField())))))
                 except:                  except:
                     zLOG.LOG('ECHO_Nav',zLOG.INFO,"error, search")                      logger('ECHO_Nav',logging.INFO,"error, search")
                     """notrhing"""                      """notrhing"""
                                           
             return ret              return ret
Line 630  class ECHO_navigation(Folder): Line 636  class ECHO_navigation(Folder):
         obj=objtemp                obj=objtemp      
   
         for keys in obj.ZopeFind(obj,obj_metatypes=self.displayedMetaTypes):          for keys in obj.ZopeFind(obj,obj_metatypes=self.displayedMetaTypes):
           
             x=keys[1]              x=keys[1]
             if depth>1:              if depth>1:
                 nav[x.getId()]=(self.getColls(x,int(depth)-1,checkOnly),x)                  nav[x.getId()]=(self.getColls(x,int(depth)-1,checkOnly),x)
Line 707  class ECHO_navigation(Folder): Line 714  class ECHO_navigation(Folder):
                             try:                              try:
                                 label=temp[x][1].getTitle()                                  label=temp[x][1].getTitle()
                             except:                              except:
                                 zLOG.LOG("ECHO_Nav",zLOG.ERROR,"%s has neither getLabel nor getTile implemented"%temp[x][1].getId())                                  logger("ECHO_Nav",logging.ERROR,"%s has neither getLabel nor getTile implemented"%temp[x][1].getId())
                                 label=""                                  label=""
                     else:                      else:
                         label=temp[x][1].getTitle()                          label=temp[x][1].getTitle()

Removed from v.1.78  
changed lines
  Added in v.1.80


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>