-Type_A, Meta_A,Meta_B
-Type_B, Meta_A,Meta_C,Meta_D
-Type_C, …
Type : facture
Meta : numéro client
Meta : numéro entreprise
1 facture : numéroClient=4, numéroEntreprise=1
1 facture : numéroClient=5, numéroEntreprise=1
1 facture : numéroClient=4, numéroEntreprise=2
1 facture : numéroClient=4, numéroEntreprise=2
1 facture : numéroClient=4, numéroEntreprise=2
…
<constraint name="sg:SingleDoc" type="ch.custom.model.constraint.SingleDocConstraint">
</constraint>
</constraints>
package ch.custom.model.constraint;
import org.alfresco.repo.dictionary.constraint.AbstractConstraint;
import org.alfresco.service.cmr.dictionary.ConstraintException;
/**
* Check that the document is single in Alfresco. (Check attributes)
*
*/
public class SingleDocConstraint extends AbstractConstraint {
@Override
protected void evaluateSingleValue(Object value) {
// Check if same type with same attributs values exist in alfresco
…
}
}
<types>
<type name="cm:cmobject">
<title>Object</title>
<parent>sys:base</parent>
<properties>
<property name="cm:name">
<title>Name</title>
<type>d:text</type>
<mandatory enforced="true">true</mandatory>
<index enabled="true">
<atomic>true</atomic>
<stored>false</stored>
<tokenised>both</tokenised>
</index>
<constraints>
<constraint ref="cm:filename" />
</constraints>
</property>
</properties>
<mandatory-aspects>
<aspect>cm:auditable</aspect>
</mandatory-aspects>
</type>
…
Content from pre 2016 and from language groups that have been closed.
Content is read-only.
By using this site, you are agreeing to allow us to collect and use cookies as outlined in Alfresco’s Cookie Statement and Terms of Use (and you have a legitimate interest in Alfresco and our products, authorizing us to contact you in such methods). If you are not ok with these terms, please do not use this website.