def compilationUID(obj):
    previousparent = parent = obj.aq_parent
    while ICompilation.providedBy(parent) or ISection.providedBy(parent):
        previousparent = parent
        parent = parent.aq_parent
    uuid = IUUID(previousparent)
    return uuid
Exemplo n.º 2
0
def compilationUID(obj):
    previousparent = parent = obj.aq_parent
    while ICompilation.providedBy(parent) or ISection.providedBy(parent):
        previousparent = parent
        parent = parent.aq_parent
    uuid = IUUID(previousparent)
    return uuid
Exemplo n.º 3
0
 def isSection(self, item):
     return ISection.providedBy(item)
 def test_isSection(self):
     compilation = self.portal._getOb('compilation001')
     tochelper = TableOfContentsHelpers(compilation, {})
     items = tochelper.getContentItems()
     for item in items:
         self.assertTrue(ISection.providedBy(item))
Exemplo n.º 5
0
 def isSection(self, item):
     return ISection.providedBy(item)
 def test_isSection(self):
     compilation = self.portal._getOb('compilation001')
     tochelper = TableOfContentsHelpers(compilation, {}) 
     items = tochelper.getContentItems()
     for item in items:
         self.assertTrue(ISection.providedBy(item))