我一直在尝试按照本教程关于Alfresco自定义内容类型
然而,当我进入“测试您的更改”步骤并且我去管理规则时,我无法设法在下拉列表中创建自定义类型(sc_doc和sc_whitepaper)。
我的share-config-custom.xml:
<!-- Share configuration related to this particular Share module extension, such as:
- Doclib action config
- Form config
- Aspect and Type config
Note. Any configuration related to the whole Share.war webapp
(i.e. not specific to this share extension) should be
placed in the environment specific config:
alfresco/tomcat/shared/classes/alfresco/web-extension/share-config-custom.xml file
-->
<alfresco-config>
<!-- Document Library config section -->
<config evaluator="string-compare" condition="DocumentLibrary">
<aspects>
<!-- Aspects that a user can see -->
<visible>
<aspect name="sc:webable" />
<aspect name="sc:productRelated" />
</visible>
<!-- Aspects that a user can add. Same as "visible" if left empty -->
<addable>
</addable>
<!-- Aspects that a user can remove. Same as "visible" if left empty -->
<removeable>
</removeable>
</aspects>
</config>
<config evaluator="node-type" condition="DocumentLibrary">
<types>
<type name="cm:content">
<subtype name="sc:doc" />
<subtype name="sc:whitepaper" />
</type>
<type name="sc:doc">
<subtype name="sc:whitepaper" />
</type>
</types>
</config>
</alfresco-config>
PS:在使用Eclipse在.xml中进行的每次更改后,是否必须重新运行'mvn install'?
非常感谢任何帮助!
答案 0 :(得分:0)
我不确定您从maven工件创建了哪种项目。
您可以在此处查看所有maven commands的列表。
如果您没有使用本地maven存储库,那么您可以使用“mvn package”生成新的AMP文件,然后在露天服务器上手动部署它们。
答案 1 :(得分:0)
我知道我迟到了这个答案
我的解决方案有点差,但它对我有用:)
我希望它对你也有用。
奇怪的是我正在遵循相同的教程,并且在“测试您的更改”阶段无法在服务器上看到我的自定义类型。
所以为了让它在我的分享项目中工作,我已经改变了
共享配置,custom.xml
从src/main/resources/META-INF
到src/main/amp/config/alfresco/web-extension
并重新启动alfresco,现在可以在服务器上的类型列表中查看我的自定义类型
如果您通过任何其他方式完成此操作,请发布您的答案:)
谢谢。