ALAppExtensions icon indicating copy to clipboard operation
ALAppExtensions copied to clipboard

[Event Request] Add Event OnFinishWizardBeforeInsertOpportunity in Table 5092 Opportunity

Open akontos opened this issue 4 years ago • 1 comments

Please add an Event OnFinishWizardBeforeInsertOpportunity to procedure FinishWizard in Table 5092 Opportunity

procedure FinishWizard()
    var
        ActivateFirstStage: Boolean;
    begin
        "Wizard Step" := Opp."Wizard Step"::" ";
        ActivateFirstStage := "Activate First Stage";
        "Activate First Stage" := false;
        OppEntry."Chances of Success %" := "Wizard Chances of Success %";
        OppEntry."Estimated Close Date" := "Wizard Estimated Closing Date";
        OppEntry."Estimated Value (LCY)" := "Wizard Estimated Value (LCY)";

        "Wizard Chances of Success %" := 0;
        "Wizard Estimated Closing Date" := 0D;
        "Wizard Estimated Value (LCY)" := 0;
        "Segment Description" := '';
        "Wizard Contact Name" := '';
        "Wizard Campaign Description" := '';

        OnFinishWizardBeforeInsertOpportunity(Rec, OppEntry);  <--- NEW EVENT

        InsertOpportunity(Rec, OppEntry, RMCommentLineTmp, ActivateFirstStage);
        Delete;

        OnAfterFinishWizard(Rec);
    end;
    [IntegrationEvent(false, false)]
    local procedure OnFinishWizardBeforeInsertOpportunity(var Opportunity: Record Opportunity; var OppEntry: Record "Opportunity Entry")
    begin
    end;

akontos avatar Jan 04 '22 14:01 akontos

Thanks for reporting this. We agree, and we’ll publish a fix asap, either in an update for the current version or in the next major release. Please do not reply to this, as we do not monitor closed issues. If you have follow-up questions or requests, please create a new issue where you reference this one.

JesperSchulz avatar Jan 27 '22 14:01 JesperSchulz