Ignore:
Timestamp:
Aug 21, 2012 11:44:47 AM (8 years ago)
Author:
potar
Message:

rewrote code (compatibility with Plone3.0)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • quintagroup.plonegooglesitemaps/branches/sitemap_date/quintagroup/plonegooglesitemaps/utils.py

    r3501 r3507  
    55from Globals import DevelopmentMode 
    66#from OFS.ObjectManager import BadRequestException 
     7from Products.CMFCore.utils import getToolByName 
    78 
    89from quintagroup.plonegooglesitemaps import config 
     
    2930 
    3031 
     32def getDefaultPage(obj): 
     33    """ Method gets default page for object (folderish) """ 
     34    plone_tool = getToolByName(obj, 'plone_utils') 
     35    return plone_tool.getDefaultPage(obj) 
     36 
     37 
     38def isDefaultPage(obj): 
     39    """ If object is default page then return True""" 
     40    plone_tool = getToolByName(obj, 'plone_utils') 
     41    return plone_tool.isDefaultPage(obj) 
     42 
     43 
    3144def dateTime(obj): 
    3245    """ Method gets modification date """ 
Note: See TracChangeset for help on using the changeset viewer.