Why do you need this change?
We would like to be able to set additional filters for Customer/Vendor Contract Deferrals in report 8051 "Contract Deferrals Release" before they are counted and released.
This was originally requested in microsoft/ALAppExtensions#29435 and received positively there.
Describe the request
Add an integration event raised after the standard filters are set, so subscribers can extend the filtering before the deferrals are counted.
Existing Source Code:
local procedure FilterAndCountContractDeferrals()
begin
ContractDeferralIteration := 0;
GlobalCustomerContractDeferral.SetRange("Posting Date", 0D, PostUntilDate);
GlobalCustomerContractDeferral.SetRange("Document Posting Date", 0D, PostUntilDate);
GlobalCustomerContractDeferral.SetRange(Released, false);
GlobalVendorContractDeferral.SetRange("Posting Date", 0D, PostUntilDate);
GlobalVendorContractDeferral.SetRange("Document Posting Date", 0D, PostUntilDate);
GlobalVendorContractDeferral.SetRange(Released, false);
TotalContractDeferralsCount := GlobalVendorContractDeferral.Count + GlobalCustomerContractDeferral.Count;
end;
New Source Code:
local procedure FilterAndCountContractDeferrals()
begin
ContractDeferralIteration := 0;
GlobalCustomerContractDeferral.SetRange("Posting Date", 0D, PostUntilDate);
GlobalCustomerContractDeferral.SetRange("Document Posting Date", 0D, PostUntilDate);
GlobalCustomerContractDeferral.SetRange(Released, false);
GlobalVendorContractDeferral.SetRange("Posting Date", 0D, PostUntilDate);
GlobalVendorContractDeferral.SetRange("Document Posting Date", 0D, PostUntilDate);
GlobalVendorContractDeferral.SetRange(Released, false);
OnFilterAndCountContractDeferralsOnAfterFilterGlobalContractDeferral(GlobalCustomerContractDeferral, GlobalVendorContractDeferral); //CHANGED (!)
TotalContractDeferralsCount := GlobalVendorContractDeferral.Count + GlobalCustomerContractDeferral.Count;
end;
[IntegrationEvent(false, false)]
local procedure OnFilterAndCountContractDeferralsOnAfterFilterGlobalContractDeferral(var CustSubContractDeferral: Record "Cust. Sub. Contract Deferral"; var VendSubContractDeferral: Record "Vend. Sub. Contract Deferral")
begin
end;
Provide an implementation (optional)
Why do you need this change?
We would like to be able to set additional filters for Customer/Vendor Contract Deferrals in report 8051 "Contract Deferrals Release" before they are counted and released.
This was originally requested in microsoft/ALAppExtensions#29435 and received positively there.
Describe the request
Add an integration event raised after the standard filters are set, so subscribers can extend the filtering before the deferrals are counted.
Existing Source Code:
New Source Code:
Provide an implementation (optional)