diff --git a/ApexDocContent/Contacts.htm b/ApexDocContent/Contacts.htm new file mode 100644 index 0000000000..8e7ae9e755 --- /dev/null +++ b/ApexDocContent/Contacts.htm @@ -0,0 +1,15 @@ + + +

Contacts Classes

+

NPSP Contacts functionality is made up of these components:

+ + +

The classes involved with Do Not Contact include:

+ + + diff --git a/src/classes/ACCT_IndividualAccounts_TDTM.cls b/src/classes/ACCT_IndividualAccounts_TDTM.cls index c66c8cb6db..913c2bf50d 100644 --- a/src/classes/ACCT_IndividualAccounts_TDTM.cls +++ b/src/classes/ACCT_IndividualAccounts_TDTM.cls @@ -33,7 +33,7 @@ * @group Accounts * @description Implements Household or Administrative account model - controls syncing within the model */ -public with sharing class ACCT_IndividualAccounts_TDTM extends TDTM_Runnable { +public class ACCT_IndividualAccounts_TDTM extends TDTM_Runnable { /******************************************************************************************************* * @description the current Contact Settings object diff --git a/src/classes/ADDR_Account_TDTM.cls b/src/classes/ADDR_Account_TDTM.cls index 808acb73e2..8cf7fb14d7 100644 --- a/src/classes/ADDR_Account_TDTM.cls +++ b/src/classes/ADDR_Account_TDTM.cls @@ -33,7 +33,7 @@ * @group Address Management * @description Trigger Handler on Account for Address management */ -public with sharing class ADDR_Account_TDTM extends TDTM_Runnable { +public class ADDR_Account_TDTM extends TDTM_Runnable { /******************************************************************************************************* * @description Trigger Handler on Account that handles Address management. diff --git a/src/classes/ADDR_Contact_TDTM.cls b/src/classes/ADDR_Contact_TDTM.cls index 32daccbe55..6c42ff0986 100644 --- a/src/classes/ADDR_Contact_TDTM.cls +++ b/src/classes/ADDR_Contact_TDTM.cls @@ -33,7 +33,7 @@ * @group Address Management * @description Trigger Handler on Contact for Address management */ -public with sharing class ADDR_Contact_TDTM extends TDTM_Runnable { +public class ADDR_Contact_TDTM extends TDTM_Runnable { public static Boolean contactsUpdatedAfterInsert = false; diff --git a/src/classes/AFFL_AccRecordType_TDTM.cls b/src/classes/AFFL_AccRecordType_TDTM.cls index f51596c123..46fbea100c 100644 --- a/src/classes/AFFL_AccRecordType_TDTM.cls +++ b/src/classes/AFFL_AccRecordType_TDTM.cls @@ -33,7 +33,7 @@ * @group Affiliations * @description Supports changing the record type of an account. */ -public with sharing class AFFL_AccRecordType_TDTM extends TDTM_Runnable { +public class AFFL_AccRecordType_TDTM extends TDTM_Runnable { /******************************************************************************************************* * @description Updates key affiliation lookups on contact, and any other primary affiliation of the new type. diff --git a/src/classes/AFFL_MultiRecordType_TDTM.cls b/src/classes/AFFL_MultiRecordType_TDTM.cls index 58fe3ea750..b4e487424a 100644 --- a/src/classes/AFFL_MultiRecordType_TDTM.cls +++ b/src/classes/AFFL_MultiRecordType_TDTM.cls @@ -33,7 +33,7 @@ * @group Affiliations * @description Handles affiliations of different record types, with one primary per type. */ -public with sharing class AFFL_MultiRecordType_TDTM extends TDTM_Runnable { +public class AFFL_MultiRecordType_TDTM extends TDTM_Runnable { //Get the primary affiliation fields defined in the Affiliation Mappings private static AFFL_MultiRecordTypeMapper afflMapper = new AFFL_MultiRecordTypeMapper(); diff --git a/src/classes/COFF_Affiliation_TDTM.cls b/src/classes/COFF_Affiliation_TDTM.cls index 064cbb2b34..8594e49ce9 100644 --- a/src/classes/COFF_Affiliation_TDTM.cls +++ b/src/classes/COFF_Affiliation_TDTM.cls @@ -33,7 +33,7 @@ * @group Program Enrollment * @description Keeps Course Offering and Affiliation records for a Contact in sync. */ -public with sharing class COFF_Affiliation_TDTM extends TDTM_Runnable { +public class COFF_Affiliation_TDTM extends TDTM_Runnable { /******************************************************************************************************* * @description Handles Affiliation management for Course Offering. diff --git a/src/classes/CON_DoNotContact_TDTM.cls b/src/classes/CON_DoNotContact_TDTM.cls index 6f5d5c5f30..e6be192a65 100644 --- a/src/classes/CON_DoNotContact_TDTM.cls +++ b/src/classes/CON_DoNotContact_TDTM.cls @@ -30,9 +30,11 @@ /** * @author Salesforce.com Foundation * @date 2015 +* @group Contacts +* @group-content ../../ApexDocContent/Contacts.htm * @description Handles changes to the deceased and do not contact fields on Contact. */ -public with sharing class CON_DoNotContact_TDTM extends TDTM_Runnable { +public class CON_DoNotContact_TDTM extends TDTM_Runnable { /******************************************************************************************************* * @description Handles deceased and do not contact fields. diff --git a/src/classes/CON_DoNotContact_TEST.cls b/src/classes/CON_DoNotContact_TEST.cls index bb8ebab9c5..de03a46e33 100644 --- a/src/classes/CON_DoNotContact_TEST.cls +++ b/src/classes/CON_DoNotContact_TEST.cls @@ -27,9 +27,21 @@ ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +/** +* @author Salesforce.com Foundation +* @date 2015 +* @group Contacts +* @group-content ../../ApexDocContent/Contacts.htm +* @description Handles changes to the deceased and do not contact fields on Contact. +*/ @isTest private class CON_DoNotContact_TEST { + /******************************************************************************************************* + * @description Marks a contact as Deceased, verifies DoNotCall, HasOptedOutOfEmail, and naming + * exclusions are set. Removes deceased flag, verifies DoNotCall, HasOptedOutOfEmail, and naming + * exclusion have been removed. + */ static testMethod void testDeceased() { UTIL_CustomSettingsFacade.getSettingsForTests(new Hierarchy_Settings__c (Account_Processor__c = CAO_Constants.HH_ACCOUNT_PROCESSOR)); @@ -61,6 +73,10 @@ private class CON_DoNotContact_TEST { system.assert(!queryCon[0].HasOptedOutOfEmail, 'Contact should not be opted out of email.'); } + /******************************************************************************************************* + * @description Marks a contact as Do Not Contact, verifies DoNotCall and HasOptedOutOfEmail are set. + * Removes Do Not Contact flag, verifies DoNotCall and HasOptedOutOfEmail are no longer set. + */ static testMethod void testDoNotContact() { UTIL_CustomSettingsFacade.getSettingsForTests(new Hierarchy_Settings__c (Account_Processor__c = CAO_Constants.HH_ACCOUNT_PROCESSOR)); diff --git a/src/classes/CON_Preferred_TDTM.cls b/src/classes/CON_Preferred_TDTM.cls index 35682b9723..450d09a6e8 100644 --- a/src/classes/CON_Preferred_TDTM.cls +++ b/src/classes/CON_Preferred_TDTM.cls @@ -33,7 +33,7 @@ * @group Contacts * @description Populates default email and phone fields according to user preferences. */ -public with sharing class CON_Preferred_TDTM extends TDTM_Runnable { +public class CON_Preferred_TDTM extends TDTM_Runnable { /******************************************************************************************************* * @description Updates default email and phone fields based to the preferred email and preferred phone values. diff --git a/src/classes/CON_PrimaryAffls_TDTM.cls b/src/classes/CON_PrimaryAffls_TDTM.cls index ae870b3bfe..46f9f62c99 100644 --- a/src/classes/CON_PrimaryAffls_TDTM.cls +++ b/src/classes/CON_PrimaryAffls_TDTM.cls @@ -34,7 +34,7 @@ * @description Creates Affiliations when the user manually populates * any of the primary affiliation lookup fields. */ -public with sharing class CON_PrimaryAffls_TDTM extends TDTM_Runnable { +public class CON_PrimaryAffls_TDTM extends TDTM_Runnable { //Get the primary affiliation fields defined in the Affiliation Mappings private static AFFL_MultiRecordTypeMapper afflMapper = new AFFL_MultiRecordTypeMapper(); diff --git a/src/classes/PREN_Affiliation_TDTM.cls b/src/classes/PREN_Affiliation_TDTM.cls index 4d0ae8e003..60ab3dfd87 100644 --- a/src/classes/PREN_Affiliation_TDTM.cls +++ b/src/classes/PREN_Affiliation_TDTM.cls @@ -33,7 +33,7 @@ * @group Program Enrollment * @description Keeps Program Enrollment and Affiliation records for a Contact in sync. */ -public with sharing class PREN_Affiliation_TDTM extends TDTM_Runnable { +public class PREN_Affiliation_TDTM extends TDTM_Runnable { /******************************************************************************************************* * @description Handles Affiliation management for Program Enrollment. diff --git a/src/classes/REL_Relationships_Cm_TDTM.cls b/src/classes/REL_Relationships_Cm_TDTM.cls index 06c1aade9a..5812c31aa1 100644 --- a/src/classes/REL_Relationships_Cm_TDTM.cls +++ b/src/classes/REL_Relationships_Cm_TDTM.cls @@ -31,7 +31,7 @@ * @author Salesforce.com Foundation * @description Implements relationships behavior */ -public with sharing class REL_Relationships_Cm_TDTM extends TDTM_Runnable { +public class REL_Relationships_Cm_TDTM extends TDTM_Runnable { public override DmlWrapper run(List newList, List oldList, TDTM_Runnable.Action triggerAction, Schema.DescribeSObjectResult objResult) { diff --git a/src/classes/THAN_Filter_TDTM.cls b/src/classes/THAN_Filter_TDTM.cls index 945538dda2..6f49cfec7a 100644 --- a/src/classes/THAN_Filter_TDTM.cls +++ b/src/classes/THAN_Filter_TDTM.cls @@ -33,7 +33,7 @@ * @group TDTM * @description Validates Trigger Handler fields data. */ -public with sharing class THAN_Filter_TDTM extends TDTM_Runnable { +public class THAN_Filter_TDTM extends TDTM_Runnable { /******************************************************************************************************* * @description Validates Trigger Handler fields data.