Skip to main content
Solved

How to Associate Inbound Emails with Opportunities

  • 15 July 2024
  • 2 replies
  • 36 views

If ACU processes an inbound email it can associate it with a contact. However, the activity is not visible in the opportunity activity for that contact. From the opportunity you can see the Lead’s activities, but not the contacts.

How would you associate inbound emails with an opportunity?

Or how would you include/merge the primary contacts activities in the opportunity’s activity list?

2 replies

Userlevel 3
Badge +1

This worked for me. It just merges in the activities for the current contact.

 

    public class OpportunityMaint_ActivityDetailsGPExt : PXGraphExtension<OpportunityMaint_ActivityDetailsExt, OpportunityMaint>
{
[PXOverride]
public Type GetLinkConditionClause()
{
//var op = this.Base.Opportunity.Current;
//var c = this.Base.Contacts.Current;


return typeof(Where<BqlChainableConditionBase<TypeArrayOf<IBqlBinary>.
FilledWith<
And<Compare<CRPMTimeActivity.refNoteID, In<P.AsGuid>>>>
>.Or<
Brackets<
BqlChainableConditionBase<TypeArrayOf<IBqlBinary>.
FilledWith<And<Compare<Current<CROpportunityClass.showContactActivities>, Equal<True>>>>
>.
And<BqlOperand<CRPMTimeActivity.refNoteID, IBqlGuid>.IsEqual<BqlField<CROpportunity.leadID, IBqlGuid>.FromCurrent>>>
>.
Or<BqlOperand<CRPMTimeActivity.refNoteID, IBqlGuid>.IsEqual<BqlField<Contact.noteID, IBqlGuid>.FromCurrent>>
>);
}
}

 

 

Userlevel 7
Badge

Thank you for sharing your solution with the community @Leif!

Reply