开发者

Data models in Alfresco

开发者 https://www.devze.com 2023-03-18 21:04 出处:网络
I\'m trying to create some data models in Alfresco. I create an XML file in alfresco extension folder where I declare 3 types: one that extends cm:content and two others that extend the first one.

I'm trying to create some data models in Alfresco.

I create an XML file in alfresco extension folder where I declare 3 types: one that extends cm:content and two others that extend the first one.

Then I create another XML file with the same namespace and declare there the fourth type.

Both files are included in the custom-model-context.xml and all the types are listed in the file web-client-config-custom.xml:

    <content-types>
        <type name="t3s:Document"/>
        <type name="t3s:Document1"/>
        <type name="t3s:Temp"/>
        <type name="t3s:Temp1"/>
    </content-types>

But in the Alfresco App I only see the last t3s:Temp1. When I delete it and its XML-file I see all other types from the first XML file.

Wha开发者_开发技巧t does it mean and what do I must to change to see every type in Alfresco App?


You're only allowed to define a namespace in one model file. If you wish to use that namespace in a different model file, you need to import it, rather than trying to re-define it. From what you've said, I think you may be defining the same namespace in two places, so one overwrites the other.

You probably want to have a look through http://wiki.alfresco.com/wiki/Data_Dictionary_Guide and then tweak your setup so either everything is in one file, or otherwise you have one file define your namespace and the second imports it.

0

精彩评论

暂无评论...
验证码 换一张
取 消