Beispiel #1
0
 def __getattr__(self, name):
     try:
         return Container.__getattr__(self, name)
     except AttributeError:
         # Check if it's on shared folder
         # Search for the content on the shared folder
         portal = getSite()
         if portal is not None and name in portal and not name.startswith('_'):
             # XXX Check that is content
             if (name != 'portal_catalog'
                     and (name not in _languagelist
                          and name not in _combinedlanguagelist
                          and name != 'id-id')):
                 new_object = aq_base(getattr(portal, name)).__of__(self)
                 new_object._v_is_shared_content = True
                 return new_object
             else:
                 raise
             #if IBaseObject.providedBy(new_object) or IDexterityContent.providedBy(new_object):
             #    new_object._v_is_shared_content = True
             #    return new_object
             #else:
             #    raise
         else:
             raise