The table below provides a comprehensive overview of all fields and relationships for the Contact object in Maica. Please refer to the table below for detailed information.
Click here to view and download the complete Contact Schema.
Validation Rules
The list below outlines the Validation Rules applied to the Contact Object in Maica.
Please refer to the list below for more detailed information on each Validation Rule.
NDIS Number Must Be 9 Digits
Ensures that the NDIS Number is 9 digits.
Validation Rule Detail
Rule Name
VAL_CONTACT_0001
Error Message
VAL_0001: If provided, the NDIS Number must be 9 characters in length.
Error Location
Top of Page
Error Condition Formula
IF (NOT(ISBLANK(maica_cc__NDIS_Number__c)),OR(LEN(maica_cc__NDIS_Number__c) <>9,NOT(ISNUMBER(maica_cc__NDIS_Number__c))),false)
Automation
Flows
The list below outlines the Flows applied to the Contact Object in Maica.
Please refer to the list below for more detailed information on each Flow.
Participant Geocoding
This Salesforce Autolaunched Flow is designed to geocode addresses for participants, updating their latitude and longitude based on the provided address information.
Flow Detail
Flow Label
Maica - Participant Geocoding
API Name
maica__Maica_Participant_Geocoding
Type
Autolaunched Flow
Flow Summary
This flow facilitates the geocoding of participant addresses by:
Detecting changes to participant records and ensuring address fields are populated.
Calling an Apex action to geocode the address.
Updating the participant record with the geocoded latitude and longitude.
Flow Description
Start (Record-Triggered Flow):
The flow is initiated upon the creation or update of a participant record.
Checks if the latitude and longitude are set to 0.0 and ensures that the address fields (MailingCity, MailingPostalCode, MailingStreet, and MailingState) are not null.
Proceeds to geocode the address asynchronously after the record is saved.
Geocode the Address (Apex Action):
Calls the GeocodeAddressInvocableProc Apex action to geocode the address.
Passes the address fields and the record ID as input parameters.
Captures the latitude and longitude from the geocoding result.
Proceeds to the Error decision.
Error? (Decision):
Checks if there is an error message from the geocoding process.
If no error, proceeds to update the participant record with the geocoded latitude and longitude.
If an error is detected, the flow ends.
Update Participant (Update Records):
Updates the participant record with the latitude and longitude from the geocoding result.
Ends the flow.
Trigger Handlers
The list below outlines the Trigger Handlers applied to the Contact Object in Maica.
Please refer to the list below for more detailed information on each Trigger Handler.
Participant Geocoding
This trigger is designed to manage the geocoding of participants in Maica.
Detail
Load Order
1
Label
ParticipantGeocode_MDTM
Execution, Logic & Outcome
Execution of Trigger Logic:
The trigger logic defined in the ParticipantGeocode_MDTM class is executed when the trigger conditions are met. The class contains the code that manages the geocoding process for participants.
Trigger Conditions:
When a new participant (Contact) is created.
When an existing participant is updated.
Any specific field changes that are monitored by the trigger (defined in the handler class).
Logic Explanation
Initialisation:
When a participant record is created or updated, the trigger is initialised. The ParticipantGeocode_MDTM metadata type configuration is loaded, ensuring that the trigger is active (Active__c is true) and has the correct load order (Load_Order__c is 1.0).
Trigger Execution:
Upon initialisation, the trigger executes the logic defined in the ParticipantGeocode_MDTM class.
The class methods perform the following steps:
Validation: The participant's address data is validated to ensure it is complete and accurate.
Geocoding: The validated address data is converted into geographical coordinates using geocoding services.
Update: The participant record is updated with the newly obtained geographical coordinates.
Trigger Outcome:
Once executed, the trigger ensures that each participant is geocoded correctly, based on the logic defined in the handler class. This helps maintain accurate geographical data for participants.
Contact Update Connections Type
This trigger is designed to manage the updating of connection types for contacts in Maica.
Detail
Load Order
2
Label
ContactUpdateConnectionsType_MDTM
Execution, Logic & Outcome
Execution of Trigger Logic:
The trigger logic defined in the ContactUpdateConnectionsType_MDTM class is executed when the trigger conditions are met. The class contains the code that manages the updating process for connection types.
Trigger Conditions:
When a new contact (Contact) is created.
When an existing contact is updated.
Any specific field changes that are monitored by the trigger (defined in the handler class).
Logic Explanation
Initialisation:
When a contact record is created or updated, the trigger is initialised. The ContactUpdateConnectionsType_MDTM metadata type configuration is loaded, ensuring that the trigger is active (Active__c is true) and has the correct load order (Load_Order__c is 2.0).
Trigger Execution:
Upon initialisation, the trigger executes the logic defined in the ContactUpdateConnectionsType_MDTM class.
The class methods perform the following steps:
Validation: The contact data is validated to ensure it is complete and accurate.
Update: The connection type is updated based on predefined criteria such as contact status or type.
Notification: Relevant stakeholders are notified if necessary, ensuring that all parties are aware of the updates.
Trigger Outcome:
Once executed, the trigger ensures that each contact's connection type is updated correctly, based on the logic defined in the handler class. This helps maintain accurate data and operational efficiency.