Skip to content

KVSPSAPost Job Document#

Procedures#

OnRun#

procedure OnRun(Rec: Record "KVSPSAJob Document Header")

Events#

KVSPSAOnAfterInsertedPostedLines(Record KVSPSAJob Document Header, Record KVSPSAPostedJobDocumentHeader, Boolean) :#

Summary: Event fired after all posted lines have been inserted during job document posting. Allows extensions to perform additional processing after posting operations are complete. This event enables custom post-processing actions after job document lines have been successfully posted and posted job document records created.

[IntegrationEvent(false, false)]
local procedure KVSPSAOnAfterInsertedPostedLines(var JobDocumentHeader: Record "KVSPSAJob Document Header"; var PostedJobDocumentHeader: Record "KVSPSAPostedJobDocumentHeader"; var PerformAll: Boolean): 
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSPSAPost Job Document", 'KVSPSAOnAfterInsertedPostedLines', '', false, false)]
local procedure DoSomethingKVSPSAOnAfterInsertedPostedLines(var JobDocumentHeader: Record "KVSPSAJob Document Header"; var PostedJobDocumentHeader: Record "KVSPSAPostedJobDocumentHeader"; var PerformAll: Boolean)
begin
end;

Parameters:

  • JobDocumentHeader: The original job document header being posted.
  • PostedJobDocumentHeader: The posted job document header that was created during posting.
  • PerformAll: Indicates whether all lines should be processed or only specific lines.

KVSPSAOnAfterTestJobDocumenLine(Record KVSPSAJob Document Line, Record KVSPSAJob Document Header) :#

Summary: Event fired after testing a job document line during validation. Allows extensions to perform additional validation or processing after standard line checks. This event enables custom validation logic or additional checks to be performed on job document lines after standard validation procedures.

[IntegrationEvent(false, false)]
local procedure KVSPSAOnAfterTestJobDocumenLine(var JobDocumentLine: Record "KVSPSAJob Document Line"; var JobDocumentHeader: Record "KVSPSAJob Document Header"): 
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSPSAPost Job Document", 'KVSPSAOnAfterTestJobDocumenLine', '', false, false)]
local procedure DoSomethingKVSPSAOnAfterTestJobDocumenLine(var JobDocumentLine: Record "KVSPSAJob Document Line"; var JobDocumentHeader: Record "KVSPSAJob Document Header")
begin
end;

Parameters:

  • JobDocumentLine: The job document line that has been tested and validated.
  • JobDocumentHeader: The parent job document header for context and additional validation references.

KVSPSAOnAfterTestJobDocumentHeader(Record KVSPSAJob Document Header) :#

Summary: Event fired after testing a job document header during validation. Allows extensions to perform additional header validation or processing after standard checks. This event enables custom validation logic to be applied to job document headers after the standard validation procedures have been completed.

[IntegrationEvent(false, false)]
local procedure KVSPSAOnAfterTestJobDocumentHeader(var JobDocumentHeader: Record "KVSPSAJob Document Header"): 
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSPSAPost Job Document", 'KVSPSAOnAfterTestJobDocumentHeader', '', false, false)]
local procedure DoSomethingKVSPSAOnAfterTestJobDocumentHeader(var JobDocumentHeader: Record "KVSPSAJob Document Header")
begin
end;

Parameters:

  • JobDocumentHeader: The job document header that has been tested and validated.

KVSPSAOnBeforeCheckJobDocumentLine(Record KVSPSAJob Document Line, Boolean) :#

Summary: Event fired before checking a job document line during validation. Allows extensions to customize validation logic or skip standard checks. This event enables extensions to implement custom validation rules or bypass standard job document line validation when required.

[IntegrationEvent(false, false)]
local procedure KVSPSAOnBeforeCheckJobDocumentLine(var JobDocumentLine: Record "KVSPSAJob Document Line"; var IsHandled: Boolean): 
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSPSAPost Job Document", 'KVSPSAOnBeforeCheckJobDocumentLine', '', false, false)]
local procedure DoSomethingKVSPSAOnBeforeCheckJobDocumentLine(var JobDocumentLine: Record "KVSPSAJob Document Line"; var IsHandled: Boolean)
begin
end;

Parameters:

  • JobDocumentLine: The job document line about to be checked.
  • IsHandled: Set to true to skip the standard job document line validation process.

KVSPSAOnBeforeInsertPostedJobDocumentHeader(Record KVSPSAPostedJobDocumentHeader, Record KVSPSAJob Document Header) :#

Summary: Event fired before inserting a posted job document header during posting process. Allows extensions to modify the posted header before insertion. This event enables custom modifications to posted job document headers, such as adding custom fields or applying business logic before the record is stored.

[IntegrationEvent(false, false)]
local procedure KVSPSAOnBeforeInsertPostedJobDocumentHeader(var PostedJobDocumentHeader: Record "KVSPSAPostedJobDocumentHeader"; var JobDocumentHeader: Record "KVSPSAJob Document Header"): 
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSPSAPost Job Document", 'KVSPSAOnBeforeInsertPostedJobDocumentHeader', '', false, false)]
local procedure DoSomethingKVSPSAOnBeforeInsertPostedJobDocumentHeader(var PostedJobDocumentHeader: Record "KVSPSAPostedJobDocumentHeader"; var JobDocumentHeader: Record "KVSPSAJob Document Header")
begin
end;

Parameters:

  • PostedJobDocumentHeader: The posted job document header about to be inserted. Can be modified by extensions.
  • JobDocumentHeader: The original job document header being posted, provided for reference and data transfer.