KVSKBAItemJournalLinePrice
Implements [#437dbf0e84ff417a965ded2bb9650972#Shipment Method ](https://github.com/search?q=Table+%5b%23437dbf0e84ff417a965ded2bb9650972%23Shipment+Method+%3aocticons-mark-github-16%3a%5d(https%3a%2f%2fgithub.com%2fsearch%3fq%3dTable%2b%2523437dbf0e84ff417a965ded2bb9650972%2523Shipment%2bMethod%2brepo%253AStefanMaron%252FMSDyn365BC.Code.History%26type%3dCode)+repo%3AStefanMaron%2FMSDyn365BC.Code.History&type=Code).
Procedures
GetTableNo() : Integer
Summary: Gets the table number for the Item Journal Line table.
procedure GetTableNo(): Integer
Returns: Table number of the Item Journal Line table
SetLine(Enum Price Type, Variant) :
procedure SetLine(PriceType: Enum "Price Type"; Line: Variant):
SetLine(Enum Price Type, Variant, Variant) :
procedure SetLine(PriceType: Enum "Price Type"; Header: Variant; Line: Variant):
SetSources(Codeunit Price Source List) :
procedure SetSources(var NewPriceSourceList: Codeunit "Price Source List"):
GetLine(Variant) :
Summary: Gets the current Item Journal Line record.
procedure GetLine(var Line: Variant):
Parameters:
Line: Variable to store the Item Journal Line record
GetLine(Variant, Variant) :
Summary: Gets the current header and line records.
procedure GetLine(var Header: Variant; var Line: Variant):
Parameters:
Header: Variable to store the header record (always cleared for Item Journal Lines)Line: Variable to store the Item Journal Line record
GetPriceType() : Enum
Summary: Gets the current price type being used for calculations.
procedure GetPriceType(): Enum Price Type
Returns: The current price type (Sale or Purchase)
IsPriceUpdateNeeded(Enum Price Amount Type, Boolean, Integer) : Boolean
procedure IsPriceUpdateNeeded(AmountType: Enum "Price Amount Type"; FoundPrice: Boolean; CalledByFieldNo: Integer): Boolean
IsDiscountAllowed() : Boolean
Summary: Checks if discounts are allowed for the current line.
procedure IsDiscountAllowed(): Boolean
Returns: Boolean indicating whether discounts are allowed
Verify() :
Summary: Verifies that required fields are filled for price calculation.
procedure Verify():
Remarks: Tests that Qty. per Unit of Measure is not zero
SetAssetSourceForSetup(Record Dtld. Price Calculation Setup) : Boolean
Summary: Sets up the asset source for detailed price calculation setup.
procedure SetAssetSourceForSetup(var DtldPriceCalculationSetup: Record "Dtld. Price Calculation Setup"): Boolean
Parameters:
DtldPriceCalculationSetup: Record to populate with setup information
Returns: Boolean indicating whether the source group was successfully retrieved
GetAssetType() : Enum
Summary: Gets the asset type for price calculation.
procedure GetAssetType(): Enum Price Asset Type
Returns: The asset type (always Item for Item Journal Lines)
CopyToBuffer(Codeunit Price Calculation Buffer Mgt.) : Boolean
procedure CopyToBuffer(var PriceCalculationBufferMgt: Codeunit "Price Calculation Buffer Mgt."): Boolean
ValidatePrice(Enum Price Amount Type) :
procedure ValidatePrice(AmountType: Enum "Price Amount Type"):
SetPrice(Enum Price Amount Type, Record Price List Line) :
procedure SetPrice(AmountType: Enum "Price Amount Type"; PriceListLine: Record "Price List Line"):
Update(Enum Price Amount Type) :
procedure Update(AmountType: Enum "Price Amount Type"):
Events
OnAfterAddSources(Record Item Journal Line, Enum Price Type, Codeunit Price Source List) :
[IntegrationEvent(false, false)]
local procedure OnAfterAddSources(ItemJournalLine: Record "Item Journal Line"; PriceType: Enum "Price Type"; var PriceSourceList: Codeunit "Price Source List"):
OnAfterIsPriceUpdateNeeded(Enum Price Amount Type, Boolean, Integer, Record Item Journal Line, Boolean) :
[IntegrationEvent(false, false)]
local procedure OnAfterIsPriceUpdateNeeded(AmountType: Enum "Price Amount Type"; FoundPrice: Boolean; CalledByFieldNo: Integer; ItemJournalLine: Record "Item Journal Line"; var Result: Boolean):
OnAfterFillBuffer(Record Price Calculation Buffer, Record Item Journal Line) :
Summary: Integration event that allows customization of price calculation buffer.
[IntegrationEvent(false, false)]
local procedure OnAfterFillBuffer(var PriceCalculationBuffer: Record "Price Calculation Buffer"; ItemJournalLine: Record "Item Journal Line"):
Parameters:
PriceCalculationBuffer: Price calculation buffer that can be modified by subscribersItemJournalLine: Item Journal Line record being processed
Remarks: Use this event to add custom fields or modify buffer data for price calculations
OnAfterSetPrice(Record Item Journal Line, Record Price List Line, Enum Price Amount Type) :
[IntegrationEvent(false, false)]
local procedure OnAfterSetPrice(var ItemJournalLine: Record "Item Journal Line"; PriceListLine: Record "Price List Line"; AmountType: Enum "Price Amount Type"):
OnBeforeSetPrice(Record Item Journal Line, Record Price List Line, Enum Price Amount Type, Boolean) :
[IntegrationEvent(false, false)]
local procedure OnBeforeSetPrice(var ItemJournalLine: Record "Item Journal Line"; PriceListLine: Record "Price List Line"; AmountType: Enum "Price Amount Type"; var IsHandled: Boolean):
OnAfterGetDocumentDate(Date, Record Item Journal Line) :
Summary: Integration event that allows customization of the document date used for price calculations.
[IntegrationEvent(false, false)]
local procedure OnAfterGetDocumentDate(var DocumentDate: Date; ItemJournalLine: Record "Item Journal Line"):
Parameters:
DocumentDate: Document date that can be modified by subscribersItemJournalLine: Item Journal Line record being processed
Remarks: Use this event to provide custom logic for determining the date to use in price calculations