cancel
Showing results for 
Search instead for 
Did you mean: 

Restrict cascade delete

oliviers
Champ in-the-making
Champ in-the-making
I have created a custom aspect with an association to Alfresco users:


<aspect name="so:testAssoc">
            <associations>
                <association name="so:persons">
                    <source>
                        <mandatory>false</mandatory>
                        <many>false</many>
                    </source>
                    <target>
                        <class>cm:person</class>
                        <mandatory>false</mandatory>
                        <many>true</many>
                    </target>
                </association>
            </associations>
</aspect>

Everything works fine, but now I want to restrict delete on user if they are referenced by this association.
Is it possible to do that in model declaration or do I have to use NodeServicePolicies?

In more general manner, is there a way to restrict cascade delete for child-association and association?
2 REPLIES 2

andy
Champ on-the-rise
Champ on-the-rise
Hi

You would indeed have to do this via NodeService policies.

Andy

oliviers
Champ in-the-making
Champ in-the-making
Ok thanks, I'll do that.