Codeunit "Price Calculation Buffer Mgt."

ID 7008
Namespace: Microsoft.Pricing.Calculation

Methods

AddAsset

procedure AddAsset(AssetType: Enum "Price Asset Type", AssetNo: Code[20])

Parameters

Name Type Description
AssetType Enum Microsoft.Pricing.Asset."Price Asset Type"
AssetNo Code[20]

AddSource

procedure AddSource(SourceType: Enum "Price Source Type", ParentSourceNo: Code[20], SourceNo: Code[20])

Parameters

Name Type Description
SourceType Enum Microsoft.Pricing.Source."Price Source Type"
ParentSourceNo Code[20]
SourceNo Code[20]

AddSource

procedure AddSource(SourceType: Enum "Price Source Type", SourceNo: Code[20])

Parameters

Name Type Description
SourceType Enum Microsoft.Pricing.Source."Price Source Type"
SourceNo Code[20]

AddSource

procedure AddSource(SourceType: Enum "Price Source Type")

Parameters

Name Type Description
SourceType Enum Microsoft.Pricing.Source."Price Source Type"

GetAsset

procedure GetAsset(var PriceAsset: Record "Price Asset" temporary)

Parameters

Name Type Description
PriceAsset Table Microsoft.Pricing.Asset."Price Asset"

GetAssets

procedure GetAssets(var NewPriceAssetList: Codeunit "Price Asset List")

Parameters

Name Type Description
NewPriceAssetList Codeunit Microsoft.Pricing.Asset."Price Asset List"

GetBuffer

procedure GetBuffer(var ResultPriceCalculationBuffer: Record "Price Calculation Buffer" temporary)

Parameters

Name Type Description
ResultPriceCalculationBuffer Table Microsoft.Pricing.Calculation."Price Calculation Buffer"

GetSource

procedure GetSource(SourceType: Enum "Price Source Type"): Code[20]

Parameters

Name Type Description
SourceType Enum Microsoft.Pricing.Source."Price Source Type"

Returns

Type Description
Code[20]

GetSources

procedure GetSources(var TempPriceSource: Record "Price Source" temporary): Boolean

Parameters

Name Type Description
TempPriceSource Table Microsoft.Pricing.Source."Price Source"

Returns

Type Description
Boolean

GetSources

procedure GetSources(var NewPriceSourceList: Codeunit "Price Source List")

Parameters

Name Type Description
NewPriceSourceList Codeunit Microsoft.Pricing.Source."Price Source List"

SetAssets

procedure SetAssets(var NewPriceAssetList: Codeunit "Price Asset List")

Parameters

Name Type Description
NewPriceAssetList Codeunit Microsoft.Pricing.Asset."Price Asset List"

SetSources

procedure SetSources(var NewPriceSourceList: Codeunit "Price Source List")

Parameters

Name Type Description
NewPriceSourceList Codeunit Microsoft.Pricing.Source."Price Source List"

Set

procedure Set(NewPriceCalculationBuffer: Record "Price Calculation Buffer" temporary, var PriceSourceList: Codeunit "Price Source List")

Parameters

Name Type Description
NewPriceCalculationBuffer Table Microsoft.Pricing.Calculation."Price Calculation Buffer"
PriceSourceList Codeunit Microsoft.Pricing.Source."Price Source List"

RoundPrice

procedure RoundPrice(var Price: Decimal)

Parameters

Name Type Description
Price Decimal

IsInMinQty

procedure IsInMinQty(PriceListLine: Record "Price List Line"): Boolean

Parameters

Name Type Description
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"

Returns

Type Description
Boolean

ConvertAmount

procedure ConvertAmount(AmountType: Enum "Price Amount Type", var PriceListLine: Record "Price List Line")

Parameters

Name Type Description
AmountType Enum Microsoft.Pricing.PriceList."Price Amount Type"
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"

ConvertAmountByTax

procedure ConvertAmountByTax(var PriceListLine: Record "Price List Line", var Amount: Decimal)

Parameters

Name Type Description
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"
Amount Decimal

ConvertAmountByUnitOfMeasure

procedure ConvertAmountByUnitOfMeasure(var PriceListLine: Record "Price List Line", var Amount: Decimal)

Parameters

Name Type Description
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"
Amount Decimal

ConvertAmountByCurrency

procedure ConvertAmountByCurrency(var PriceListLine: Record "Price List Line", var Amount: Decimal)

Parameters

Name Type Description
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"
Amount Decimal

SetLineDiscountPctForPickBestLine

procedure SetLineDiscountPctForPickBestLine(var PriceListLine: Record "Price List Line")

Parameters

Name Type Description
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"

FillBestLine

procedure FillBestLine(AmountType: Enum "Price Amount Type", var PriceListLine: Record "Price List Line")

Parameters

Name Type Description
AmountType Enum Microsoft.Pricing.PriceList."Price Amount Type"
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"

SetFiltersOnPriceListLine

procedure SetFiltersOnPriceListLine(var PriceListLine: Record "Price List Line", AmountType: Enum "Price Amount Type", ShowAll: Boolean)

Parameters

Name Type Description
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"
AmountType Enum Microsoft.Pricing.PriceList."Price Amount Type"
ShowAll Boolean

RestoreFilters

procedure RestoreFilters(var PriceListLine: Record "Price List Line")

Parameters

Name Type Description
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"

VerifySelectedLine

procedure VerifySelectedLine(PriceListLine: Record "Price List Line")

Parameters

Name Type Description
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"

Events

OnAfterCalcUnitAmountRoundingPrecision

[IntegrationEvent(False,False)]
local procedure OnAfterCalcUnitAmountRoundingPrecision(PriceCalculationBuffer: Record "Price Calculation Buffer" temporary, var UnitAmountRoundingPrecision: Decimal)

Parameters

Name Type Description
PriceCalculationBuffer Table Microsoft.Pricing.Calculation."Price Calculation Buffer"
UnitAmountRoundingPrecision Decimal

OnAfterGetAssets

[IntegrationEvent(False,False)]
local procedure OnAfterGetAssets(PriceCalculationBuffer: Record "Price Calculation Buffer" temporary, var NewPriceAssetList: Codeunit "Price Asset List")

Parameters

Name Type Description
PriceCalculationBuffer Table Microsoft.Pricing.Calculation."Price Calculation Buffer"
NewPriceAssetList Codeunit Microsoft.Pricing.Asset."Price Asset List"

OnAfterGetSources

[IntegrationEvent(False,False)]
local procedure OnAfterGetSources(PriceCalculationBuffer: Record "Price Calculation Buffer" temporary, var TempPriceSource: Record "Price Source" temporary, var Found: Boolean)

Parameters

Name Type Description
PriceCalculationBuffer Table Microsoft.Pricing.Calculation."Price Calculation Buffer"
TempPriceSource Table Microsoft.Pricing.Source."Price Source"
Found Boolean

OnAfterGetSourcesNewPriceSourceList

[IntegrationEvent(False,False)]
local procedure OnAfterGetSourcesNewPriceSourceList(var PriceCalculationBuffer: Record "Price Calculation Buffer" temporary, var NewPriceSourceList: Codeunit "Price Source List")

Parameters

Name Type Description
PriceCalculationBuffer Table Microsoft.Pricing.Calculation."Price Calculation Buffer"
NewPriceSourceList Codeunit Microsoft.Pricing.Source."Price Source List"

OnAfterSetFilters

[IntegrationEvent(False,False)]
local procedure OnAfterSetFilters(var PriceListLine: Record "Price List Line", AmountType: Enum "Price Amount Type", var PriceCalculationBuffer: Record "Price Calculation Buffer" temporary, ShowAll: Boolean)

Parameters

Name Type Description
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"
AmountType Enum Microsoft.Pricing.PriceList."Price Amount Type"
PriceCalculationBuffer Table Microsoft.Pricing.Calculation."Price Calculation Buffer"
ShowAll Boolean

OnAfterSetLineDiscountPctForPickBestLine

[IntegrationEvent(False,False)]
local procedure OnAfterSetLineDiscountPctForPickBestLine(PriceCalculationBuffer: Record "Price Calculation Buffer" temporary, var PriceListLine: Record "Price List Line")

Parameters

Name Type Description
PriceCalculationBuffer Table Microsoft.Pricing.Calculation."Price Calculation Buffer"
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"

OnBeforeConvertAmount

[IntegrationEvent(False,False)]
local procedure OnBeforeConvertAmount(AmountType: Enum "Price Amount Type", var PriceListLine: Record "Price List Line", PriceCalculationBuffer: Record "Price Calculation Buffer" temporary, var IsHandled: Boolean)

Parameters

Name Type Description
AmountType Enum Microsoft.Pricing.PriceList."Price Amount Type"
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"
PriceCalculationBuffer Table Microsoft.Pricing.Calculation."Price Calculation Buffer"
IsHandled Boolean

OnBeforeIsInMinQty

[IntegrationEvent(False,False)]
local procedure OnBeforeIsInMinQty(PriceListLine: Record "Price List Line", PriceCalculationBuffer: Record "Price Calculation Buffer" temporary, var Result: Boolean, var IsHandled: Boolean)

Parameters

Name Type Description
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"
PriceCalculationBuffer Table Microsoft.Pricing.Calculation."Price Calculation Buffer"
Result Boolean
IsHandled Boolean

OnBeforeSet

[IntegrationEvent(False,False)]
local procedure OnBeforeSet(var PriceCalculationBuffer: Record "Price Calculation Buffer" temporary)

Parameters

Name Type Description
PriceCalculationBuffer Table Microsoft.Pricing.Calculation."Price Calculation Buffer"

OnConvertAmountByTaxOnAfterVATPostingSetupGet

[IntegrationEvent(False,False)]
local procedure OnConvertAmountByTaxOnAfterVATPostingSetupGet(var VATPostingSetup: Record "VAT Posting Setup", var Amount: Decimal, var IsHandled: Boolean, var PriceCalculationBuffer: Record "Price Calculation Buffer" temporary)

Parameters

Name Type Description
VATPostingSetup Table Microsoft.Finance.VAT.Setup."VAT Posting Setup"
Amount Decimal
IsHandled Boolean
PriceCalculationBuffer Table Microsoft.Pricing.Calculation."Price Calculation Buffer"

OnBeforeConvertAmountByCurrency

[IntegrationEvent(False,False)]
local procedure OnBeforeConvertAmountByCurrency(var PriceListLine: Record "Price List Line", var Amount: Decimal, var PriceCalculationBuffer: Record "Price Calculation Buffer" temporary)

Parameters

Name Type Description
PriceListLine Table Microsoft.Pricing.PriceList."Price List Line"
Amount Decimal
PriceCalculationBuffer Table Microsoft.Pricing.Calculation."Price Calculation Buffer"

See also