KVSKBAPriceInformation
Fields
| Name | Type | Note |
|---|---|---|
| Information No. | Integer | |
| Initial Record | Boolean | |
| Responsibility Center | Code[10] | |
| Date | Date | |
| Customer No. | Code[20] | |
| Customer Price Group | Code[10] | |
| Customer Name | Text[100] | |
| Prices Including VAT | Boolean | |
| VAT Bus. Posting Group | Code[20] | |
| Customer Disc. Group | Code[20] | |
| Type | Option | OptionMembers: ,,Item |
| No. | Code[20] | |
| Variant Code | Code[10] | |
| Description | Text[100] | |
| Description 2 | Text[50] | |
| Item Price Group | Code[10] | |
| VAT Prod. Posting Group | Code[20] | |
| VAT Calculation Type | Enum Tax Calculation Type | |
| VAT % | Decimal | |
| Item Disc. Group | Code[20] | |
| Unit Cost (LCY) | Decimal | |
| Unit of Measure Code | Code[10] | |
| Qty. per Unit of Measure | Decimal | |
| KVSKBAPriceUnit | Decimal | |
| Currency Code | Code[10] | |
| Currency Factor | Decimal | |
| Base Unit of Measure Code | Code[10] | |
| Quantity | Decimal | |
| Unit Price (Calculated) | Decimal | |
| Unit Price (PU) (Calculated) | Decimal | |
| Minimum Qty. (Price Calc.) | Decimal | |
| Starting Date (Price Calc.) | Date | |
| Ending Date (Price Calc.) | Date | |
| Allow Line Disc. (Price Calc.) | Boolean | |
| Allow Inv. Disc. (Price Calc.) | Boolean | |
| KVSKBAPriceDescendedFromItem | Boolean | |
| Line Discount % (Calc.) | Decimal | |
| Minimum Qty. (Disc. Calc.) | Decimal | |
| Starting Date (Disc. Calc.) | Date | |
| Ending Date (Disc. Calc.) | Date | |
| Not Billable (Calc) | Code[10] | Warning: Obsolete |
| NotBillableCalc | Code[20] | |
| KVSKBADiscDescendedFromItem | Boolean | |
| Minimum Quantity | Decimal | |
| Starting Date | Date | |
| Ending Date | Date | |
| Allow Line Disc. | Boolean | |
| Allow Invoice Disc. | Boolean | |
| Unit Price | Decimal | |
| KVSKBAUnitPricePriceUnit | Decimal | |
| Line Discount % | Decimal | |
| Line Discount Amount | Decimal | |
| Line Amount | Decimal | |
| Line Amount (LCY) | Decimal | |
| Line Amount (LCY) excl. VAT | Decimal | |
| Unit Cost Amount (LCY) | Decimal | |
| Profit (LCY) | Decimal | |
| Profit % | Decimal | |
| KVSKBAMinimumProfit | Decimal | |
| Autosave Information by Exit | Boolean | |
| KVSKBADonotFindBestPrice | Boolean | |
| KVSKBASalesOrderType | Code[10] | |
| Pricing Customer | Option | OptionMembers: ,Sell-to Customer,Bill-to Customer |
| Bill-to Customer No. | Code[20] | |
| LocationCode | Code[10] | |
| Price Price List Code (Calc.) | Code[20] | |
| Price P. List Line No. (Calc.) | Integer | |
| Disc. Price List Code (Calc.) | Code[20] | |
| Disc. P. List Line No. (Calc.) | Integer | |
| Comment | Text[80] | |
| Item Reference No. | Code[50] | |
| Item Reference Unit of Measure | Code[10] | |
| Item Reference Type | Enum Item Reference Type | |
| Item Reference Type No. | Code[30] | |
| Price Calculation Method | Enum Price Calculation Method | |
| Price Price List Code | Code[20] | |
| Discount Price List Code | Code[20] | |
| NotBillable | Code[20] | |
| Not Billable | Code[10] | Warning: Obsolete |
Procedures
GetPriceCalculationHandler(Enum Price Type, Interface Price Calculation) :
procedure GetPriceCalculationHandler(LocalPriceType: Enum "Price Type"; var PriceCalculation: Interface "Price Calculation"):
ApplyDiscount(Interface Price Calculation) :
procedure ApplyDiscount(var PriceCalculation: Interface "Price Calculation"):
ApplyPrice(Integer, Interface Price Calculation) :
procedure ApplyPrice(CalledByFieldNo: Integer; var PriceCalculation: Interface "Price Calculation"):
CountDiscount(Boolean) : Integer
Summary: Counts the number of applicable discounts using the specified price calculation handler.
procedure CountDiscount(ShowAll: Boolean): Integer
Parameters:
ShowAll: A boolean indicating whether to show all discounts or only applicable ones.
Returns: The count of applicable discounts.
Remarks: This procedure counts the number of applicable discounts for the current record using the provided price calculation handler. It retrieves the appropriate handler based on the sale price type and returns the count of discounts.
CountPrice(Boolean) : Integer
Summary: Counts the number of applicable prices using the specified price calculation handler.
procedure CountPrice(ShowAll: Boolean): Integer
Parameters:
ShowAll: A boolean indicating whether to show all prices or only applicable ones.
Returns: The count of applicable prices.
Remarks: This procedure counts the number of applicable prices for the current record using the provided price calculation handler. It retrieves the appropriate handler based on the sale price type and returns the count of prices.
DiscountExists(Boolean) : Boolean
Summary: Checks if any applicable discounts exist using the specified price calculation handler.
procedure DiscountExists(ShowAll: Boolean): Boolean
Parameters:
ShowAll: A boolean indicating whether to show all discounts or only applicable ones.
Returns: A boolean indicating whether any applicable discounts exist.
Remarks: This procedure checks if any applicable discounts exist for the current record using the provided price calculation handler. It retrieves the appropriate handler based on the sale price type and returns true if any discounts exist, otherwise false.
PriceExists(Boolean) : Boolean
Summary: Checks if any applicable prices exist using the specified price calculation handler.
procedure PriceExists(ShowAll: Boolean): Boolean
Parameters:
ShowAll: A boolean indicating whether to show all prices or only applicable ones.
Returns: A boolean indicating whether any applicable prices exist.
Remarks: This procedure checks if any applicable prices exist for the current record using the provided price calculation handler. It retrieves the appropriate handler based on the sale price type and returns true if any prices exist, otherwise false.
PickDiscount() : Boolean
Summary: Picks a discount using the specified price calculation handler.
procedure PickDiscount(): Boolean
Returns: A boolean indicating whether a discount was picked.
Remarks: This procedure allows the user to pick a discount for the current record using the provided price calculation handler. It retrieves the appropriate handler based on the sale price type, applies the discount, and updates the current record with the selected discount. If the selected discount is not allowed, it prompts the user for confirmation.
PickPrice() : Boolean
Summary: Picks a price using the specified price calculation handler.
procedure PickPrice(): Boolean
Returns: A boolean indicating whether a price was picked.
Remarks: This procedure allows the user to pick a price for the current record using the provided price calculation handler. It retrieves the appropriate handler based on the sale price type, applies the price, and updates the current record with the selected price. If the selected price is not allowed, it prompts the user for confirmation.
Events
OnAfterApplyPrice(Record KVSKBAPriceInformation, Record KVSKBAPriceInformation, Integer, Integer) :
Summary: Event raised after a price has been applied to the price information record.
[IntegrationEvent(false, false)]
local procedure OnAfterApplyPrice(var KVSKBAPriceInformation: Record "KVSKBAPriceInformation"; var xKVSKBAPriceInformation: Record "KVSKBAPriceInformation"; CallFieldNo: Integer; CurrentFieldNo: Integer):
Parameters:
KVSKBAPriceInformation: The price information record after the price was applied.xKVSKBAPriceInformation: The previous state of the price information record.CallFieldNo: The field number that initiated the call.CurrentFieldNo: The field number currently being processed.
Remarks: Use this event to perform additional calculations or field assignments after the standard apply price logic has run.
OnAfterGetDateForCalculations(Date, Record KVSKBAPriceInformation) :
Summary: Event raised after the date for price/discount calculations has been determined.
[IntegrationEvent(false, false)]
local procedure OnAfterGetDateForCalculations(var DocumentDate: Date; KVSKBAPriceInformation: Record "KVSKBAPriceInformation"):
Parameters:
DocumentDate: The resolved document date used for calculations.KVSKBAPriceInformation: The price information record.
Remarks: Use this event to override the calculated document date with a custom value.
OnAfterGetLineWithPrice(Interface Line With Price) :
[IntegrationEvent(true, false)]
local procedure OnAfterGetLineWithPrice(var LineWithPrice: Interface "Line With Price"):
OnAfterUpdateItemReference(Record KVSKBAPriceInformation) :
Summary: Event raised after the item reference has been updated on the price information record.
[IntegrationEvent(true, false)]
local procedure OnAfterUpdateItemReference(var KVSKBAPriceInformation: Record "KVSKBAPriceInformation"):
Parameters:
KVSKBAPriceInformation: The price information record after the item reference update.
Remarks: Use this event to react to item reference changes or apply further field assignments after the standard update logic has run.
OnBeforeUpdateUnitCost(Record KVSKBAPriceInformation, Boolean) :
Summary: Event raised before the unit cost is updated on the price information record.
[IntegrationEvent(false, false)]
local procedure OnBeforeUpdateUnitCost(var PriceInformation: Record "KVSKBAPriceInformation"; var Handled: Boolean):
Parameters:
PriceInformation: The price information record.Handled: Set to true to skip the default unit cost update logic.
Remarks: Subscribers can set Handled to true to replace the standard unit cost update with custom behaviour.
OnBeforeUpdateUnitPrice(Record KVSKBAPriceInformation, Record KVSKBAPriceInformation, Boolean) :
Summary: Event that is raised bofore the UpdateUnitPrice function has been executed
[IntegrationEvent(false, false)]
local procedure OnBeforeUpdateUnitPrice(var PriceInformation: Record "KVSKBAPriceInformation"; var xPriceInformation: Record "KVSKBAPriceInformation"; var IsHandled: Boolean):
Parameters:
PriceInformation: Actual RecordxPriceInformation: Previous Record ContentIsHandled: Parameter for skipping the processing function UpdateUnitPrice
Remarks: Use this event to perform additional logic before the unit price is updated. Set IsHandled to true to prevent the standard UpdateUnitPrice logic from executing.
OnAfterUpdateUnitPrice(Record KVSKBAPriceInformation, Record KVSKBAPriceInformation) :
Summary: Event that is raised after the UpdateUnitPrice function has been executed.
[IntegrationEvent(false, false)]
local procedure OnAfterUpdateUnitPrice(var PriceInformation: Record "KVSKBAPriceInformation"; var xPriceInformation: Record "KVSKBAPriceInformation"):
Parameters:
PriceInformation: Actual RecordxPriceInformation: Previous Record Content
Remarks: Use this event to perform additional logic after the unit price has been updated.
OnValidateNotBillableOnBeforeSelectAskBillableHandlingType(Record KVSKBAPriceInformation, Integer, Boolean) :
Summary: Integration event that is raised before selecting the handling type for 'Not Billable' when 'Ask' option is chosen.
[IntegrationEvent(false, false)]
local procedure OnValidateNotBillableOnBeforeSelectAskBillableHandlingType(PriceInformation: Record "KVSKBAPriceInformation"; var DefaultSelectOption: Integer; var IsHandled: Boolean):
Parameters:
PriceInformation: The price information record.DefaultSelectOption: The default option to select (1 for 'Full Discount', 2 for 'Empty Price and Discount').IsHandled: Set to true if the event has been handled and the default behavior should be skipped.
Remarks: Use this event to customize the options presented to the user or to implement custom handling logic when 'Not Billable' is set to 'Ask'.