0
votes

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.

What does it mean and what do I must to change to see every type in Alfresco App?

1
Are you saying that you have two content model files, each with different definitions but the same namespace? - Gagravarr

1 Answers

2
votes

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.