Improved: Make removeContentAndRelated service fail-save for missing
content and remove related ContentAttributes also.
Thanks Martin Becker for reporting and providing the patch.
</simple-method>
<simple-method method-name="removeContentAndRelated" short-description="Remove a Content Record, related resource(s) and assocs.">
<entity-one entity-name="Content" value-field="content"/>
+ <if-not-empty field="content">
+ <remove-related value-field="content" relation-name="ContentAttribute"/>
<remove-related value-field="content" relation-name="ContentRole"/>
<remove-related value-field="content" relation-name="ContentKeyword"/>
<remove-related value-field="content" relation-name="FromContentAssoc"/>
<remove-related value-field="dataResource" relation-name="DataResourceRole"/>
<remove-value value-field="dataResource"/>
</if-not-empty>
+ </if-not-empty>
</simple-method>
<!-- update content; just status -->
<condition>
<or>
<if-empty field="parameters.contentId"/>
- <if-compare operator="equals" value="null" field="parameters.contentId"></if-compare>
+ <if-compare operator="equals" value="null" field="parameters.contentId"/>
</or>
</condition>
<then>
