java.lang.IllegalStateException: Operation not allowed against node pending deletion. Check the node for aspect {http://www.alfresco.org/model/system/1.0}pendingDelete
<aspect name="rassleg:arg_corr">
<title>Argomenti correlati</title>
<mandatory-aspects>
<aspect>cm:taggable</aspect>
</mandatory-aspects>
</aspect>
<aspect name="rassleg:doc_corr">
<title>Documenti correlati</title>
<associations>
<association name="rassleg:relatedDocuments">
<title>Documenti correlati</title>
<source>
<mandatory>false</mandatory>
<many>true</many>
</source>
<target>
<class>rassleg:base_type</class>
<mandatory>false</mandatory>
<many>true</many>
</target>
</association>
</associations>
</aspect>
…
public class RuleTriggerBidirectionalAssoc extends RuleTriggerAbstractBase
implements NodeServicePolicies.OnDeleteAssociationPolicy,
NodeServicePolicies.OnCreateAssociationPolicy {
Log log = LogFactory.getLog(RuleTriggerBidirectionalAssoc.class);
public void onDeleteAssociation(AssociationRef nodeAssocRef) {
log.info("Called onDeleteAssociation");
nodeService.removeAssociation(nodeAssocRef.getTargetRef(),
nodeAssocRef.getSourceRef(),
nodeAssocRef.getTypeQName());
}
public void onCreateAssociation(AssociationRef nodeAssocRef) {
log.info("Called onCreateAssociation");
nodeService.createAssociation(nodeAssocRef.getTargetRef(),
nodeAssocRef.getSourceRef(),
nodeAssocRef.getTypeQName());
}
public void registerRuleTrigger() {
log.info("Called registerRuleTrigger");
this.policyComponent.bindAssociationBehaviour(QName.createQName(
NamespaceService.ALFRESCO_URI, "onCreateAssociation"), this,
new JavaBehaviour(this, "onCreateAssociation"));
this.policyComponent.bindAssociationBehaviour(QName.createQName(
NamespaceService.ALFRESCO_URI, "onDeleteAssociation"), this,
new JavaBehaviour(this, "onDeleteAssociation"));
}
}
<config evaluator="aspect" condition="rassleg:doc_corr">
<forms>
<form>
<field-visibility>
<show id="rassleg:relatedDocuments" />
</field-visibility>
<appearance>
<field id="rassleg:relatedDocuments" label-id="label.avvproj-rassleg-relatedDocuments">
<control template="/com/avvproj/components/form/controls/association.ftl">
<control-param name="displayMode">items</control-param>
<control-param name="showTargetLink">true</control-param>
<control-param name="allowNavigationToContentChildren">false</control-param>
<control-param name="startLocation">{doclib}</control-param>
</control>
</field>
</appearance>
</form>
</forms>
</config>
Archive content from product discussions in Italian.
This group is now closed and 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.