We now have to support two ways to add content:

1.) oldstyle (no add view specified)

The addable types are listed in folder_factories. After specifying type and ID the object is added. constructContent redirects to the immediate view.

2.) newstyle (add view is specified)

The addable types are listed as actions. These actions should show up in a menu. The add action points to a type specific add form. After completion of the form the object is added. The add form redirects to the immediate view.

Some parts are still missing:

- add a traverser that allows to use pretty URLs and better portal type handling for add views (not part of this proposal)

- don't show newstyle types in folder_factories

- show add actions in the CMFDefault skin

Proposal 1: allowedContentTypes

This PortalFolder method is used by folder_factories and by folder_contents to decide if the 'New...' button is added. I propose to add a new skip_add_views argument to allowedContentTypes. If true, newstyle types are skipped.

Proposal 2: main_template

CMFDefault menus are implemented in main_template. I propose to add a new section for 'folder/add' actions.

If there are no objections I'll make these changes on trunk.



Zope-CMF maillist  -  Zope-CMF@lists.zope.org

See http://collector.zope.org/CMF for bug reports and feature requests

Reply via email to