怎样通过策略包创建定制的首页

怎样通过策略包创建定制的首页
Have you tried content generation using Generic Setup?
The following example should reset the content generated by setupPortalContent():
  1. Add folder named structure under your site policy product's default profile folder (e.g. src/my.site.policy/my/site/policy/profiles/default/structure/).
  2. Under that folder, add a new file named .delete with content
  3. events front-page Members news 
  4. Under the same folder, add a new file named .objects with content
  5. front-page,Document 
  6. Still under the same folder, add a new file named front-page with content
  7. id: front-page title: Foo description: Bar Content-Type: text/html <p>Hello World!</p> 
The new Plone site created with this policy should contain only the front-page described above. (Note that the new front-page has the initial state of its default workflow, which is private by default.)
The easiest way to experiment with content generation further, I think, is to just create something, export Content-step from portal_setup and examine the results. Also the Generic Setup Quick Reference by Six Feet Up gives an overview for content generation support in Generic Setup.
总结:
所有Archtype和dexterity内容类型都可以采用这种structure方式来预置内容对象。
设置