Exemplo n.º 1
0
 def to_folder(self):
     """replace self with a folder"""
     haunted = self.get_haunted()
     if haunted is not None:
         binding = getUtility(IMetadataService).getMetadata(haunted)
         data_content = binding.get('silva-content', acquire=0)
         data_extra = binding.get('silva-extra', acquire=0)
     helpers.convert_content(self, Folder)
     if haunted is not None:
         binding = getUtility(IMetadataService).getMetadata(self)
         binding.setValues('silva-content', data_content)
         binding.setValues('silva-extra', data_extra)
Exemplo n.º 2
0
 def to_folder(self):
     """replace self with a folder"""
     haunted = self.get_haunted()
     if haunted is not None:
         binding = getUtility(IMetadataService).getMetadata(haunted)
         data_content = binding.get('silva-content', acquire=0)
         data_extra = binding.get('silva-extra', acquire=0)
     helpers.convert_content(self, Folder)
     if haunted is not None:
         binding = getUtility(IMetadataService).getMetadata(self)
         binding.setValues('silva-content', data_content)
         binding.setValues('silva-extra', data_extra)
Exemplo n.º 3
0
 def to_folder(self):
     """Publication becomes a folder instead.
     """
     helpers.convert_content(self, Folder)
Exemplo n.º 4
0
 def to_publication(self):
     """Turn this folder into a publication.
     """
     from Products.Silva.Publication import Publication
     helpers.convert_content(self, Publication)
Exemplo n.º 5
0
 def to_folder(self):
     """Publication becomes a folder instead.
     """
     helpers.convert_content(self, Folder)