Esempio n. 1
0
 def __call__(self, content):
     if not IViewableObject.providedBy(content):
         return True
     item = self.get(content)
     # Item is none will account for unpublished content.
     return ((item is None) or (self.metadata(item, 'silva-settings',
                                              'hide_from_tocs') == 'hide'))
Esempio n. 2
0
 def __call__(self, content):
     if not IViewableObject.providedBy(content):
         return True
     item = self.get(content)
     # Item is none will account for unpublished content.
     return (
         (item is None) or
         (self.metadata(item, 'silva-settings', 'hide_from_tocs') == 'hide'))