Former Communication Data

Development Status
Stable
Active Installs
39
Maintainers
Download

Last updated: 2020-01-23

Works with CiviCRM 5.9 or higher.

This extension saves old emailaddresses, phone numbers and addresses for contacts in a specific tab (custom group) called Former Communication Details. Whenever you delete (or update with new relevant data like emailaddress, phone number or address data) the former communication data will be saved in this tab.

Techie Talk

The extension creates a new custom group upon installation called Former Communication Details. The custom group is set to is_reserved=1. All custom fields in the custom group are view only.

The extension uses the pre and post hook on Email, Phone and Address with delete or edit operations.

The pre hook retrieves the original data (using api action getsingle of the specific entity) and stores it. The post hook for the delete operation adds the original data to the custom group. The post hook for the edit operation checks if email, phone, street_address, county, state_province, postal_code, city or country have changed. If so it will save the original data in the custom group.

Screenshot (click to enlarge)