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

[Event Request] Table 36 "Sales Header" - OnBeforeValidateCustomerDiscGroup #27705

Open
skuchana93 opened this issue Nov 26, 2024 · 0 comments
Open
Labels
event-request Request for adding an event SCM GitHub request for SCM area

Comments

@skuchana93
Copy link

skuchana93 commented Nov 26, 2024

Describe the request

In Table 36, please include the OnBeforeValidateCustomerDiscGroup event within the OnValidate trigger of the "Customer Disc. Group" field.

Actual Code:
trigger OnValidate()
begin
TestStatusOpen();
MessageIfSalesLinesExist(FieldCaption("Customer Disc. Group"));
end;

Required Code with a new event request:
trigger OnValidate()
var
IsHandled: Boolean;
begin
IsHandled := false;
OnBeforeValidateCustomerDiscGroup(Rec, xRec, CurrFieldNo, IsHandled);
if IsHandled then
exit;
TestStatusOpen();
MessageIfSalesLinesExist(FieldCaption("Customer Disc. Group"));
end;

[IntegrationEvent(false, false)]
local procedure OnBeforeValidateCustomerDiscGroup(var SalesHeader: Record "Sales Header"; xSalesHeader: Record "Sales Header"; CurrentFieldNo: Integer; var IsHandled: Boolean)
begin
end;

Additional context

This new event is necessary to enable subscription for implementing custom code and to provide the option to bypass the base code when needed.
Internal work item: AB#558865

@ChethanT ChethanT added event-request Request for adding an event SCM GitHub request for SCM area labels Nov 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
event-request Request for adding an event SCM GitHub request for SCM area
Projects
None yet
Development

No branches or pull requests

2 participants