如何在Plone 5中添加新的收集标准?
我将一个名为course的新选择字段添加到一个新创建的实例中的灵巧内容类型文件中。为了在/++add++集合中使用字段“course”作为标准,我遵循并将其添加到plone/buildout cache/eggs/plone.app.querystring-1.3.14-py2.7.egg/plone/app/querystring/profiles/default/registry.xml中的registry.xml文件中:如何在Plone 5中添加新的收集标准?,plone,content-type,dexterity,Plone,Content Type,Dexterity,我将一个名为course的新选择字段添加到一个新创建的实例中的灵巧内容类型文件中。为了在/++add++集合中使用字段“course”作为标准,我遵循并将其添加到plone/buildout cache/eggs/plone.app.querystring-1.3.14-py2.7.egg/plone/app/querystring/profiles/default/registry.xml中的registry.xml文件中: <records interface="plone.app.q
<records interface="plone.app.querystring.interfaces.IQueryField"
prefix="plone.app.querystring.field.course">
<value key="title">course</value>
<value key="description">A custom course index</value>
<value key="enabled">True</value>
<value key="sortable">False</value>
<value key="operations">
<element>plone.app.querystring.operation.string.is</element>
</value>
<value key="group">Metadata</value>
</records>
课程
自定义课程索引
真的
假的
plone.app.querystring.operation.string.is
元数据
但我在标准列表中找不到“课程”
要获得收集的标准,我可以做些什么?首先:修改Plone源代码是一种不良做法。不要这样做。从来没有 您所参考的指南是可以的,但它旨在用于您必须开发并添加到安装中的新Plone插件中 请仔细阅读 在您的情况下:您需要一个非常简单的附加组件,带有一个简单的通用设置步骤,其中包含一个包含上述代码的
registry.xml
文件。
安装加载项后(每次重新安装时),您的注册将添加到您的站点。keul能帮助您进一步吗?