AnsweredAssumed Answered

Override property of a subtype

Question asked by livier on Jan 8, 2019
Latest reply on Jan 14, 2019 by livier

Hi every one and happy new year.

 

I'd like to know if there's a way to override properties in subtypes.

 

For example, here is my type :

 

<type name="myCM:entreprise">
            <title>Documents Entreprises</title>
            <parent>myCM:doc</parent>
            <properties>
                <property name=myCM:categories">
                       <title>Categories  </title>
                       <type>d:text</type>
                 </property>

            <properties>   
 </type>

The myCM:entreprise type as the property "categories". In my subtypes, I'd like to override this property with differents lists. I try this code but it doesn't work --> GetModelsDiffs Error :

 

 

<type name="myCM:entrepriseAlpha">
            <title>Documents Entreprises</title>
            <parent>myCM:entreprise</parent>
            <overrides>
                <property name="myCM:categories">
                    <title>Categorie de document</title>
                    <type>d:text</type>
                    <constraints>
                        <constraint ref="myCM:listCategoriesAlpha"/>
                    </constraints>
                </property>        
            </overrides>
 </type>

 

<type name="myCM:entrepriseBeta">
            <title>Documents Entreprises</title>
            <parent>myCM:entreprise</parent>
            <overrides>
                <property name="myCM:categories">
                    <title>Categorie de document</title>
                    <type>d:text</type>
                    <constraints>
                        <constraint ref="myCM:listCategoriesBeta"/>
                    </constraints>
                </property>        
            </overrides>
 </type>

 

Thanks in advance.

I work with SDK 3.0 and alfresco comunity v5.2

Outcomes