[Product-Developers] Re: Content Rules - Create Folder action

David Bain david.bain at alteroo.com
Sat Jul 5 18:15:17 UTC 2008

On Sat, Jul 5, 2008 at 12:42 PM, Martin Aspeli <optilude at gmx.net> wrote:
> David Bain wrote:
>> How do I go about creating a folder with a content rule/trigger.
>> I see actions such as notify, copy to folder etc... but nothing like:
>> "create folder" or "create object"
> Take a look at
> http://plone.org/documentation/tutorial/creating-content-rule-conditions-and-actions
> - you'll need to create a new content rule action, but that shouldn't be so
> hard.
too hard is relative to what you know already :).
I think I found a nice example in mailtoplone
I'll go through that code as an example

>> Is there an add on for this already? Or does it need to be written?
>> The use case is the ability to archive events based on month. The
>> rules would be:
>> On adding an event
>> 1. Create a folder structure (if it does not exist) based on year and
>> month
>> 2. move the event to the year/month folder
> I would possibly just make a bespoke action type for this use case, rather
> than try to generalise too much. You'll need some logic to determine where
> to create the folder and what to name it that's probably not going to be
> easy to generalise beyond this use case.
> Martin
> --
> Author of `Professional Plone Development`, a book for developers who
> want to work with Plone. See http://martinaspeli.net/plone-book
> _______________________________________________
> Product-Developers mailing list
> Product-Developers at lists.plone.org
> http://lists.plone.org/mailman/listinfo/product-developers

More information about the Product-Developers mailing list