Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add logging to DPEV - Listener create opportunity #206

Open
wants to merge 1 commit into
base: metecho/2024-october-sprint
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
<assignments>
<name>Update_MFS_Error</name>
<label>Update MFS - Error</label>
<locationX>440</locationX>
<locationY>494</locationY>
<locationX>704</locationX>
<locationY>818</locationY>
<assignmentItems>
<assignToReference>Membership_Form_Submission_Record.Status__c</assignToReference>
<operator>Assign</operator>
Expand All @@ -28,8 +28,8 @@
<assignments>
<name>Update_MFS_Error_Opp</name>
<label>Update MFS - Error</label>
<locationX>704</locationX>
<locationY>386</locationY>
<locationX>968</locationX>
<locationY>602</locationY>
<assignmentItems>
<assignToReference>Membership_Form_Submission_Record.Status__c</assignToReference>
<operator>Assign</operator>
Expand All @@ -53,7 +53,7 @@
<name>Update_MFS_Success2</name>
<label>Update MFS - Success</label>
<locationX>176</locationX>
<locationY>494</locationY>
<locationY>818</locationY>
<assignmentItems>
<assignToReference>Membership_Form_Submission_Record.Opportunity__c</assignToReference>
<operator>Assign</operator>
Expand All @@ -65,6 +65,13 @@
<targetReference>Update_MFS</targetReference>
</connector>
</assignments>
<constants>
<name>staticFlowName</name>
<dataType>String</dataType>
<value>
<stringValue>DPEV Listener - Create Opportunity</stringValue>
</value>
</constants>
<description>Create Listener flow off creation of: DPEV Create Opportunity Platform Event</description>
<environments>Default</environments>
<formulas>
Expand Down Expand Up @@ -94,17 +101,263 @@
</value>
</processMetadataValues>
<processType>AutoLaunchedFlow</processType>
<recordCreates>
<description>Create Membership Essentials Log records for each success and fault</description>
<name>Create_Membership_Essentials_Log_Error</name>
<label>Create Membership Essentials Log - Error</label>
<locationX>968</locationX>
<locationY>494</locationY>
<connector>
<targetReference>Update_MFS_Error_Opp</targetReference>
</connector>
<inputAssignments>
<field>Flow_Name__c</field>
<value>
<elementReference>staticFlowName</elementReference>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Message__c</field>
<value>
<stringValue>Create Opportunity has failed</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Type__c</field>
<value>
<stringValue>Error</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Membership_Form_Submission__c</field>
<value>
<elementReference>Membership_Form_Submission_Record.Id</elementReference>
</value>
</inputAssignments>
<object>Membership_Essentials_Event_Log__c</object>
<storeOutputAutomatically>true</storeOutputAutomatically>
</recordCreates>
<recordCreates>
<description>Create Membership Essentials Log records for each success and fault</description>
<name>Create_Membership_Essentials_Log_Error_0</name>
<label>Create Membership Essentials Log - Error</label>
<locationX>704</locationX>
<locationY>710</locationY>
<connector>
<targetReference>Update_MFS_Error</targetReference>
</connector>
<inputAssignments>
<field>Flow_Name__c</field>
<value>
<elementReference>staticFlowName</elementReference>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Message__c</field>
<value>
<stringValue>Create Opportunity Line Item has failed</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Type__c</field>
<value>
<stringValue>Error</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Membership_Form_Submission__c</field>
<value>
<elementReference>Membership_Form_Submission_Record.Id</elementReference>
</value>
</inputAssignments>
<object>Membership_Essentials_Event_Log__c</object>
<storeOutputAutomatically>true</storeOutputAutomatically>
</recordCreates>
<recordCreates>
<description>Create Membership Essentials Log records for each success and fault</description>
<name>Create_Membership_Essentials_Log_Error_0_0</name>
<label>Create Membership Essentials Log - Error</label>
<locationX>440</locationX>
<locationY>1034</locationY>
<inputAssignments>
<field>Flow_Name__c</field>
<value>
<elementReference>staticFlowName</elementReference>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Message__c</field>
<value>
<stringValue>Membership Form Submission update has failed</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Type__c</field>
<value>
<stringValue>Error</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Membership_Form_Submission__c</field>
<value>
<elementReference>Membership_Form_Submission_Record.Id</elementReference>
</value>
</inputAssignments>
<object>Membership_Essentials_Event_Log__c</object>
<storeOutputAutomatically>true</storeOutputAutomatically>
</recordCreates>
<recordCreates>
<description>Create Membership Essentials Log records for each success and fault</description>
<name>Create_Membership_Essentials_Log_Pass</name>
<label>Create Membership Essentials Log - Pass</label>
<locationX>176</locationX>
<locationY>278</locationY>
<connector>
<targetReference>Create_Opportunity_Record</targetReference>
</connector>
<inputAssignments>
<field>Flow_Name__c</field>
<value>
<elementReference>staticFlowName</elementReference>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Message__c</field>
<value>
<stringValue>DPEV Listener - Create Opportunity has started</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Type__c</field>
<value>
<stringValue>Pass</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Membership_Form_Submission__c</field>
<value>
<elementReference>Membership_Form_Submission_Record.Id</elementReference>
</value>
</inputAssignments>
<object>Membership_Essentials_Event_Log__c</object>
<storeOutputAutomatically>true</storeOutputAutomatically>
</recordCreates>
<recordCreates>
<description>Create Membership Essentials Log records for each success and fault</description>
<name>Create_Membership_Essentials_Log_Pass_0</name>
<label>Create Membership Essentials Log - Pass</label>
<locationX>176</locationX>
<locationY>494</locationY>
<connector>
<targetReference>Create_Opportunity_Line_Item</targetReference>
</connector>
<inputAssignments>
<field>Flow_Name__c</field>
<value>
<elementReference>staticFlowName</elementReference>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Message__c</field>
<value>
<stringValue>Opportunity has been created</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Type__c</field>
<value>
<stringValue>Pass</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Membership_Form_Submission__c</field>
<value>
<elementReference>Membership_Form_Submission_Record.Id</elementReference>
</value>
</inputAssignments>
<object>Membership_Essentials_Event_Log__c</object>
<storeOutputAutomatically>true</storeOutputAutomatically>
</recordCreates>
<recordCreates>
<description>Create Membership Essentials Log records for each success and fault</description>
<name>Create_Membership_Essentials_Log_Pass_0_0</name>
<label>Create Membership Essentials Log - Pass</label>
<locationX>176</locationX>
<locationY>710</locationY>
<connector>
<targetReference>Update_MFS_Success2</targetReference>
</connector>
<inputAssignments>
<field>Flow_Name__c</field>
<value>
<elementReference>staticFlowName</elementReference>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Message__c</field>
<value>
<stringValue>Opportunity Line Item has been created</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Type__c</field>
<value>
<stringValue>Pass</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Membership_Form_Submission__c</field>
<value>
<elementReference>Membership_Form_Submission_Record.Id</elementReference>
</value>
</inputAssignments>
<object>Membership_Essentials_Event_Log__c</object>
<storeOutputAutomatically>true</storeOutputAutomatically>
</recordCreates>
<recordCreates>
<description>Create Membership Essentials Log records for each success and fault</description>
<name>Create_Membership_Essentials_Log_Pass_0_0_0</name>
<label>Create Membership Essentials Log - Pass</label>
<locationX>176</locationX>
<locationY>1034</locationY>
<inputAssignments>
<field>Flow_Name__c</field>
<value>
<elementReference>staticFlowName</elementReference>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Message__c</field>
<value>
<stringValue>Membership Form Submission has been updated</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Log_Type__c</field>
<value>
<stringValue>Pass</stringValue>
</value>
</inputAssignments>
<inputAssignments>
<field>Membership_Form_Submission__c</field>
<value>
<elementReference>Membership_Form_Submission_Record.Id</elementReference>
</value>
</inputAssignments>
<object>Membership_Essentials_Event_Log__c</object>
<storeOutputAutomatically>true</storeOutputAutomatically>
</recordCreates>
<recordCreates>
<description>Create the opportunity line item</description>
<name>Create_Opportunity_Line_Item</name>
<label>Create Opportunity Line Item</label>
<locationX>176</locationX>
<locationY>386</locationY>
<locationY>602</locationY>
<connector>
<targetReference>Update_MFS_Success2</targetReference>
<targetReference>Create_Membership_Essentials_Log_Pass_0_0</targetReference>
</connector>
<faultConnector>
<targetReference>Update_MFS_Error</targetReference>
<targetReference>Create_Membership_Essentials_Log_Error_0</targetReference>
</faultConnector>
<inputAssignments>
<field>OpportunityId</field>
Expand Down Expand Up @@ -144,12 +397,12 @@
<name>Create_Opportunity_Record</name>
<label>Create Opportunity Record</label>
<locationX>176</locationX>
<locationY>278</locationY>
<locationY>386</locationY>
<connector>
<targetReference>Create_Opportunity_Line_Item</targetReference>
<targetReference>Create_Membership_Essentials_Log_Pass_0</targetReference>
</connector>
<faultConnector>
<targetReference>Update_MFS_Error_Opp</targetReference>
<targetReference>Create_Membership_Essentials_Log_Error</targetReference>
</faultConnector>
<inputAssignments>
<field>AccountId</field>
Expand Down Expand Up @@ -197,7 +450,7 @@
<locationY>170</locationY>
<assignNullValuesIfNoRecordsFound>false</assignNullValuesIfNoRecordsFound>
<connector>
<targetReference>Create_Opportunity_Record</targetReference>
<targetReference>Create_Membership_Essentials_Log_Pass</targetReference>
</connector>
<filterLogic>and</filterLogic>
<filters>
Expand All @@ -215,7 +468,13 @@
<name>Update_MFS</name>
<label>Update - MFS</label>
<locationX>176</locationX>
<locationY>602</locationY>
<locationY>926</locationY>
<connector>
<targetReference>Create_Membership_Essentials_Log_Pass_0_0_0</targetReference>
</connector>
<faultConnector>
<targetReference>Create_Membership_Essentials_Log_Error_0_0</targetReference>
</faultConnector>
<inputReference>Membership_Form_Submission_Record</inputReference>
</recordUpdates>
<start>
Expand Down