Skip to content

KVSPSADistributionCalcMgt#

Procedures#

DistrActualEntries(Record KVSPSAJobPSPLine, Boolean, Integer, Decimal, Boolean) :#

Summary: this function updates the distribution suggestion

procedure DistrActualEntries(var CurrJobPSPLine: Record "KVSPSAJobPSPLine"; FirstCall: Boolean; BudgetLineNo: Integer; Precision: Decimal; IgnoreFilter: Boolean): 

Parameters:

  • CurrJobPSPLine:
  • FirstCall:
  • BudgetLineNo:
  • Precision:
  • IgnoreFilter:

DistrActualEntries(Record KVSPSAJobPSPLine, Record KVSPSA Job Budget Line, Boolean, Integer, Decimal, Boolean) :#

Summary: this function updates the distribution suggestion

procedure DistrActualEntries(var CurrJobPSPLine: Record "KVSPSAJobPSPLine"; var CurrJobBudgetLine: Record "KVSPSA Job Budget Line"; FirstCall: Boolean; BudgetLineNo: Integer; Precision: Decimal; IgnoreFilter: Boolean): 

Parameters:

  • CurrJobPSPLine:
  • CurrJobBudgetLine:
  • FirstCall:
  • BudgetLineNo:
  • Precision:
  • IgnoreFilter:

DistributeAllInvocing(Record KVSPSAJobPSPLine, Integer) :#

Summary: Use this function to redistribute the invoicing values.

procedure DistributeAllInvocing(var CurrJobPSPLine: Record "KVSPSAJobPSPLine"; BudgetLineNo: Integer): 

Parameters:

  • CurrJobPSPLine: Current Job PSP Line
  • BudgetLineNo: Current Budget Line No. If the Job PSP Line should be redistributed BudgetLineNo must be zero.

SyncJobBudgetEntries(Record KVSPSA Job Budget Line) :#

Summary: This function synchronizes the job budget entries. It will synchronize all job budget entries with the distribution calculation formula. It will also check the resource capacity if the job budget line is a resource and the "Use Resource Capacity" field is set to true. If the job budget line is a resource, it will check if there is enough capacity available for the planned distribution. If there is not enough capacity available, it will send a notification or raise an error depending on the setup. If the job budget line is a resource, it will also check the rounding precision for resources and items/GL accounts.

procedure SyncJobBudgetEntries(var JobBudgetLine: Record "KVSPSA Job Budget Line"): 

Parameters:

  • JobBudgetLine: Current Job Budget Line

Events#

KVSPSAOnFindPaymentPlaningElse(Boolean, Record KVSPSAJobPSPLine, Integer, Record KVSPSADistributionEntry, Decimal, Record KVSPSA Job Budget Line) :#

Summary: Integration event raised when payment planning search finds an alternative path for planning distribution entries.

[IntegrationEvent(false, false)]
local procedure KVSPSAOnFindPaymentPlaningElse(var PlaningExist: Boolean; CurrJobPSPLine: Record "KVSPSAJobPSPLine"; BudgetLineNo: Integer; var DistributionEntry: Record "KVSPSADistributionEntry"; var UnAssignedValue: Decimal; var JobBudgetLine: Record "KVSPSA Job Budget Line"): 
[EventSubscriber(ObjectType::Codeunit, Codeunit::"KVSPSADistributionCalcMgt", 'KVSPSAOnFindPaymentPlaningElse', '', false, false)]
local procedure DoSomethingKVSPSAOnFindPaymentPlaningElse(var PlaningExist: Boolean; CurrJobPSPLine: Record "KVSPSAJobPSPLine"; BudgetLineNo: Integer; var DistributionEntry: Record "KVSPSADistributionEntry"; var UnAssignedValue: Decimal; var JobBudgetLine: Record "KVSPSA Job Budget Line")
begin
end;

Parameters:

  • PlaningExist: Indicates whether payment planning exists for the current context
  • CurrJobPSPLine: The current Job PSP Line being processed
  • BudgetLineNo: The budget line number associated with the distribution
  • DistributionEntry: The distribution entry record being processed
  • UnAssignedValue: The value that has not been assigned in the distribution
  • JobBudgetLine: The job budget line record related to the distribution