Metadata-Version: 1.0
Name: mailtoplone.scrawl
Version: 0.1
Summary: addon for mailtoplone creating Scrawl Blog Entries
Home-page: http://svn.plone.org/svn/collective/mailtoplone/mailtoplone.scrawl/tags/0.1
Author: Hans-Peter Locher
Author-email: hans-peter.locher@inquant.de
License: GPL
Description: Dependencies
        
        mailtoplone.base:
        
        - http://pypi.python.org/pypi/mailtoplone.base
        
        Scrawl:
        
        - http://pypi.python.org/pypi/Products.Scrawl
        
        Example buildout
        
        buildout:
        
        - http://svn.plone.org/svn/collective/mailtoplone/buildout-scrawl
        
        Change history
        **************
        
        Changelog
        =========
        
        0.1 (2009-05-29)
        ----------------
        
        - call add_category [hplocher]
        - get all attachments from mail, and call add_file
        for each [hplocher]
        call add_file for each, before calling create_
        - decode subject header, used as title [hplocher]
        - refactor adapter, use IBlogEntryFactory [hplocher]
        - add adapter to create a Blog Entry [hplocher]
        (title, body text, only atm)
        
        
        Detailed Documentation
        **********************
        
        Introduction
        ============
        
        We need manager role for this test::
        
        >>> self.setRoles(('Manager',))
        
        
        Configure Folder for Blog Entries
        ---------------------------------
        
        We use a standard Folder for dropping the emails in::
        
        >>> self.portal.invokeFactory('Folder', 'blog_entries')
        'blog_entries'
        >>> blog_entries = self.portal.blog_entries
        
        To enable MailDropbox functionality, we equip the
        folder with an additional marker interface::
        
        >>> from zope.interface import alsoProvides
        >>> from mailtoplone.scrawl.interfaces import IScrawlMailDropBoxMarker
        >>> alsoProvides(blog_entries, IScrawlMailDropBoxMarker)
        
        mailtoplone uses a more generic interface IMailDropBox, to adapt the
        context, we use that to call drop::
        
        >>> from mailtoplone.base.interfaces import IMailDropBox
        >>> IMailDropBox(blog_entries).drop("Subject: my first blog entry")
        
        As result, we wexpect a single blog entry, with the title, id set
        according to the email's subject::
        >>> blog_entries.objectIds()
        ['my-first-blog-entry']
        >>> blog_entry = blog_entries.listFolderContents()[0]
        >>> blog_entry.title
        u'my first blog entry'
        >>> blog_entry.portal_type
        'Blog Entry'
        
        Contributors
        ************
        
        Hans-Peter Locher, Author
        
        
        Download
        ********
        
Platform: UNKNOWN
Classifier: Framework :: Plone
Classifier: Intended Audience :: Developers
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: License :: OSI Approved :: GNU General Public License (GPL)
