Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  1. A foreign key to PROCESSRUNLOG table. 
  2. An integer field to indicate whether the entity's related entity is archived or not. (0 - not archived, 1- archived)

2. Data Object Class

The entity's DO class must:

  1. Implement ICRMDORelatedArchiveEntity interface and its following methods:
    1. getRefersToArchivedEntity()
    2. isRefersToArchivedEntity()
    3. setRefersToArchivedEntity(Integer refersToArchivedEntity)
    4. getProcessRunLog()
    5. setProcessRunLog(CRMDOProcessRunLog processRunLog)

...

  1. Archived entity's <archiverelatedentities> tag value must include the related archived entity's id. <archiverelatedentities> tag can include more that one entity ids, separated by semicolons (;). For . Once the main entity is archived, related entity will no longer be editable.  For more information on archived entities go to Create an Archive Entity.

Code Block
languagexml
titleentities.xml
collapsetrue
<entityconfig>
	<entities>		
		<entity>
			<id>CUSTOMRENTALS</id>
			<name>key_rental</name>
			<tablename>TRN_RENTALS</tablename>
			<classname>com.crm.dataobject.rentals.CUSTOMCRMDORental</classname>
			<moduleid>CUSTOM_RENTALS</moduleid>
			<metadatafile>rentals</metadatafile>
		</entity>
		
		<entity>
			<id>CUSTOMRENTALTYPES</id>
			<name>key_rental_type</name>
			<tablename>TRN_RENTALTYPES</tablename>
			<classname>com.crm.dataobject.rentals.CUSTOMCRMDORentalType</classname>
			<moduleid>CUSTOMRENTALS</moduleid>
			<metadatafile>rentaltypes</metadatafile>
			<isarchived>true</isarchived>
			<archivecollections>TRN_RENTTYPEPRODUCTS</archivecollections>
			<archiverelatedentities>CUSTOMRENTALS</archiverelatedentities>
		</entity>
		<entity>
			<id>CUSTOMRENTALTYPEPRODUCTS</id>
			<name>key_rental_type_product</name>
			<tablename>TRN_RENTTYPEPRODUCTS</tablename>
			<classname>com.crm.dataobject.rentals.CUSTOMCRMDORentalTypeProduct</classname>
			<moduleid>CUSTOMRENTALS</moduleid>
			<isarchived>true</isarchived>
		</entity>
		...
	</entities>
</entityconfig>