Written by The Jahia Team
   Estimated reading time:

For a Jahia component to support personalization and optimization, it shall be a droppable content and shall not be a content list

In others words, "add personalization" and "add optimization test" features are enforced by the definition below. For any area where you want to be able to  test or personalize content,  you'll need to authorize the nodetypes "wemnt:personalizedContent" and "wemnt:optimizationTest".

<bean id="Toolbar.Item.Personalize" class="org.jahia.services.uicomponents.bean.toolbar.Item">
        <property name="actionItem">
            <bean class="org.jahia.ajax.gwt.client.widget.toolbar.action.ExecuteActionItem">
                <property name="action" value="personalize"/>
                <property name="forbiddenNodeTypes" >
                    <set>
                        <value>wemnt:personalizedContent</value>
                        <value>wemnt:optimizationTest</value>
                        <value>wemmix:editItem</value>
                        <value>jnt:contentList</value>
                    </set>
                </property>
                <property name="requiredNodeTypes" value="jmix:droppableContent"/>
            </bean>
        </property>
        <property name="titleKey" value="label.edit.personalize@resources.marketing-factory-core"/>
        <property name="icon" value="/modules/marketing-factory-core/images/icons/personalize"/>
        <property name="parent" value="editmode.contextMenu"/>
        <property name="requiredModule" value="marketing-factory-core"/>
        <property name="visibility">
            <bean class="org.jahia.services.uicomponents.bean.Visibility">
                <property name="permission" value="canPersonalizeWithMarketingFactory"/>
            </bean>
        </property>
    </bean>