Codeunit 18008294 EOS Commission Utilities

Codeunit 18008294 EOS Commission Utilities

Gathers all functions used to handle general needs

Methods

HasDocCommissionLine

procedure HasDocCommissionLine(tableNo: Integer; DocumentType: Integer; DocNo: Code[20]; LineNo: Integer): Boolean

Parameters / Return Value

  • tableNo Integer

  • DocumentType Integer

  • DocNo Code[20]

  • LineNo Integer

  • Returns Boolean


DeleteDocCommissionLine

procedure DeleteDocCommissionLine(tableNo: Integer; DocumentType: Integer; DocNo: Code[20]; LineNo: Integer): Boolean

Parameters / Return Value

  • tableNo Integer

  • DocumentType Integer

  • DocNo Code[20]

  • LineNo Integer

  • Returns Boolean


HasCommissionLedgerEntry

procedure HasCommissionLedgerEntry(tableNo: Integer; DocumentType: Integer; DocNo: Code[20]; LineNo: Integer; salesp: Code[20]; salespRole: Code[10]): Boolean

Parameters / Return Value

  • tableNo Integer

  • DocumentType Integer

  • DocNo Code[20]

  • LineNo Integer

  • salesp Code[20]

  • salespRole Code[10]

  • Returns Boolean


DeleteCommissionLedgerEntry

procedure DeleteCommissionLedgerEntry(tableNo: Integer; DocumentType: Integer; DocNo: Code[20]; LineNo: Integer; salesp: Code[20]; salespRole: Code[10]; DeleteManual: Boolean)

Parameters / Return Value

  • tableNo Integer

  • DocumentType Integer

  • DocNo Code[20]

  • LineNo Integer

  • salesp Code[20]

  • salespRole Code[10]

  • DeleteManual Boolean


DeleteDocCommissionLedgerEntry

procedure DeleteDocCommissionLedgerEntry(tableNo: Integer; DocumentType: Integer; DocNo: Code[20]; LineNo: Integer; salesp: Code[20]; salespRole: Code[10]; DeleteManual: Boolean)

Parameters / Return Value

  • tableNo Integer

  • DocumentType Integer

  • DocNo Code[20]

  • LineNo Integer

  • salesp Code[20]

  • salespRole Code[10]

  • DeleteManual Boolean


DocCommissionLedgerEntryEditable

procedure DocCommissionLedgerEntryEditable(CommDocLedgerEntry: Record "EOS Comm. Doc. Ledger Entry"; HideDialog: Boolean) IsEditable: Boolean

Parameters / Return Value

  • CommDocLedgerEntry Record "EOS Comm. Doc. Ledger Entry"

  • HideDialog Boolean

  • Returns Boolean


CommissionLedgerEntryEditable

procedure CommissionLedgerEntryEditable(CommissionLedgerEntry: Record "EOS Commission Ledger Entry"; HideDialog: Boolean) IsEditable: Boolean

Parameters / Return Value

  • CommissionLedgerEntry Record "EOS Commission Ledger Entry"

  • HideDialog Boolean

  • Returns Boolean


EncodeSalesDocType

procedure EncodeSalesDocType(inBuffDocType: Integer; TableID: Integer; IsHeader: Boolean) DocType: Integer

Parameters / Return Value

  • inBuffDocType Integer

  • TableID Integer

  • IsHeader Boolean

  • Returns Integer


AlignExcludeFromCommission

procedure AlignExcludeFromCommission(SalesHeader: Record "Sales Header"; GiftLinesDict: Dictionary of [Integer, Integer])

Parameters / Return Value

  • SalesHeader Record "Sales Header"

  • GiftLinesDict Dictionary[Integer,Integer]


DecodeSalesDocType

procedure DecodeSalesDocType(inSalesDocType: Integer; var RecIdBuf: Record "EOS Record Ident. Buffer"; IsHeader: Boolean): Boolean

Parameters / Return Value

  • inSalesDocType Integer

  • RecIdBuf Record "EOS Record Ident. Buffer"

  • IsHeader Boolean

  • Returns Boolean


ConvertAmount2LCY

procedure ConvertAmount2LCY(Value: Decimal; CurrencyCode: Code[10]; CurrencyFactor: Decimal; CurrencyDate: Date) RetValue: Decimal

Parameters / Return Value

  • Value Decimal

  • CurrencyCode Code[10]

  • CurrencyFactor Decimal

  • CurrencyDate Date

  • Returns Decimal


GetCustomerCommissionGroup

procedure GetCustomerCommissionGroup(customerNo: Code[20]): Code[20]

Parameters / Return Value

  • customerNo Code[20]

  • Returns Code[20]


GetCustomerCommissionGroup

procedure GetCustomerCommissionGroup(EOSCommissionLedgerEntry: Record "EOS Commission Ledger Entry"): Code[20]

Parameters / Return Value

  • EOSCommissionLedgerEntry Record "EOS Commission Ledger Entry"

  • Returns Code[20]


GetProdCommissionGroup

procedure GetProdCommissionGroup(EOSCommissionLedgerEntry: Record "EOS Commission Ledger Entry"): Code[20]

Parameters / Return Value

  • EOSCommissionLedgerEntry Record "EOS Commission Ledger Entry"

  • Returns Code[20]


GetProductCommissionGroup

procedure GetProductCommissionGroup(ProductNo: Code[50]; productType: Integer): Code[20]

Parameters / Return Value

  • ProductNo Code[50]

  • productType Integer

  • Returns Code[20]


GetProductCommissionGroupFromDocLine

procedure GetProductCommissionGroupFromDocLine(ProductNo: Code[20]; productType: Integer): Code[20]

Parameters / Return Value

  • ProductNo Code[20]

  • productType Integer

  • Returns Code[20]


GotoPage

procedure GotoPage(Notif: Notification)

Parameters / Return Value

  • Notif Notification

NotificationHandler

procedure NotificationHandler(PageNoToOpen: Integer; Scope: NotificationScope; MessageText: Text; ActionText: Text; HasAction: Boolean)

Parameters / Return Value

  • PageNoToOpen Integer

  • Scope NotificationScope

  • MessageText Text

  • ActionText Text

  • HasAction Boolean


CalcPeriodCode

procedure CalcPeriodCode(DocDate: Date; salesp: Code[20]): Code[20]

Parameters / Return Value

  • DocDate Date

  • salesp Code[20]

  • Returns Code[20]


DrilldownSalespersons

procedure DrilldownSalespersons(HeaderType: Integer; HeaderSubType: Option; HeaderID: code[20]; HeaderSubID: code[20]; HeaderRefNo: integer; IsEditable: Boolean)

Parameters / Return Value

  • HeaderType Integer

  • HeaderSubType Option

  • HeaderID code[20]

  • HeaderSubID code[20]

  • HeaderRefNo integer

  • IsEditable Boolean


UpdateRelatedEntriesAndProspectReferences

procedure UpdateRelatedEntriesAndProspectReferences(PurchLine: Record "Purchase Line"; PurchInvHeader: Record "Purch. Inv. Header";var PurchInvLine: Record "Purch. Inv. Line")

Parameters / Return Value

  • PurchLine Record "Purchase Line"

  • PurchInvHeader Record "Purch. Inv. Header"

  • PurchInvLine Record "Purch. Inv. Line"


UpdateRelatedEntriesAndProspectReferences

procedure UpdateRelatedEntriesAndProspectReferences(PurchLine: Record "Purchase Line"; PurchCrMemoHdr: Record "Purch. Cr. Memo Hdr.";var PurchCrMemoLine: Record "Purch. Cr. Memo Line")

Parameters / Return Value

  • PurchLine Record "Purchase Line"

  • PurchCrMemoHdr Record "Purch. Cr. Memo Hdr."

  • PurchCrMemoLine Record "Purch. Cr. Memo Line"


CollectCommLedgerEntryFromProspect

procedure CollectCommLedgerEntryFromProspect(var EOSCommDocLedgerEntry: Record "EOS Comm. Doc. Ledger Entry"; EOSCommissionProspectHeader: Record "EOS Commission Prospect Header")

Parameters / Return Value

  • EOSCommDocLedgerEntry Record "EOS Comm. Doc. Ledger Entry"

  • EOSCommissionProspectHeader Record "EOS Commission Prospect Header"


CollectCommLedgerEntryFromProspect

procedure CollectCommLedgerEntryFromProspect(var EOSCommissionLedgerEntry: Record "EOS Commission Ledger Entry"; EOSCommissionProspectHeader: Record "EOS Commission Prospect Header")

Parameters / Return Value

  • EOSCommissionLedgerEntry Record "EOS Commission Ledger Entry"

  • EOSCommissionProspectHeader Record "EOS Commission Prospect Header"


CollectCommLedgerEntryFromProspect

procedure CollectCommLedgerEntryFromProspect(var EOSCommissionLedgerEntry: Record "EOS Commission Ledger Entry"; EOSCommissionProspectLine: Record "EOS Commission Prospect Line")

Parameters / Return Value

  • EOSCommissionLedgerEntry Record "EOS Commission Ledger Entry"

  • EOSCommissionProspectLine Record "EOS Commission Prospect Line"


CollectCommLedgerEntryFromProspect

procedure CollectCommLedgerEntryFromProspect(var CommissionDocLedgerEntry: Record "EOS Comm. Doc. Ledger Entry"; EOSCommissionProspectLine: Record "EOS Commission Prospect Line")

Parameters / Return Value

  • CommissionDocLedgerEntry Record "EOS Comm. Doc. Ledger Entry"

  • EOSCommissionProspectLine Record "EOS Commission Prospect Line"


CollectCommLedgerEntryFromPurchase

procedure CollectCommLedgerEntryFromPurchase(var EOSCommissionLedgerEntry: Record "EOS Comm. Doc. Ledger Entry"; PurchaseLine: Record "Purchase Line")

Parameters / Return Value

  • EOSCommissionLedgerEntry Record "EOS Comm. Doc. Ledger Entry"

  • PurchaseLine Record "Purchase Line"


CollectCommLedgerEntryFromPurchase

procedure CollectCommLedgerEntryFromPurchase(var EOSCommissionLedgerEntry: Record "EOS Comm. Doc. Ledger Entry"; PurchaseHeader: Record "Purchase Header")

Parameters / Return Value

  • EOSCommissionLedgerEntry Record "EOS Comm. Doc. Ledger Entry"

  • PurchaseHeader Record "Purchase Header"


CollectCommLedgerEntryFromPurchase

procedure CollectCommLedgerEntryFromPurchase(var EOSCommissionLedgerEntry: Record "EOS Comm. Doc. Ledger Entry"; PurchaseInvLine: Record "Purch. Inv. Line")

Parameters / Return Value

  • EOSCommissionLedgerEntry Record "EOS Comm. Doc. Ledger Entry"

  • PurchaseInvLine Record "Purch. Inv. Line"


CollectCommLedgerEntryFromPurchase

procedure CollectCommLedgerEntryFromPurchase(var EOSCommissionLedgerEntry: Record "EOS Comm. Doc. Ledger Entry"; PurchCrMemoLine: Record "Purch. Cr. Memo Line")

Parameters / Return Value

  • EOSCommissionLedgerEntry Record "EOS Comm. Doc. Ledger Entry"

  • PurchCrMemoLine Record "Purch. Cr. Memo Line"


CollectCommLedgerEntryFromPurchase

procedure CollectCommLedgerEntryFromPurchase(var EOSCommissionLedgerEntry: Record "EOS Comm. Doc. Ledger Entry"; PurchCrMemoHdr: Record "Purch. Cr. Memo Hdr.")

Parameters / Return Value

  • EOSCommissionLedgerEntry Record "EOS Comm. Doc. Ledger Entry"

  • PurchCrMemoHdr Record "Purch. Cr. Memo Hdr."


CollectCommLedgerEntryFromPurchase

procedure CollectCommLedgerEntryFromPurchase(var EOSCommissionLedgerEntry: Record "EOS Comm. Doc. Ledger Entry"; PurchaseInvHeader: Record "Purch. Inv. Header")

Parameters / Return Value

  • EOSCommissionLedgerEntry Record "EOS Comm. Doc. Ledger Entry"

  • PurchaseInvHeader Record "Purch. Inv. Header"


CollectProspectFromPurchase

procedure CollectProspectFromPurchase(var EOSCommissionProspectHeader: Record "EOS Commission Prospect Header"; PurchaseHeader: Record "Purchase Header")

Parameters / Return Value

  • EOSCommissionProspectHeader Record "EOS Commission Prospect Header"

  • PurchaseHeader Record "Purchase Header"


CollectProspectFromPurchase

procedure CollectProspectFromPurchase(var EOSCommissionProspectHeader: Record "EOS Commission Prospect Header"; PurchaseHeader: Record "Purch. Inv. Header")

Parameters / Return Value

  • EOSCommissionProspectHeader Record "EOS Commission Prospect Header"

  • PurchaseHeader Record "Purch. Inv. Header"


CollectProspectFromPurchase

procedure CollectProspectFromPurchase(var EOSCommissionProspectHeader: Record "EOS Commission Prospect Header"; PurchaseHeader: Record "Purch. Cr. Memo Hdr.")

Parameters / Return Value

  • EOSCommissionProspectHeader Record "EOS Commission Prospect Header"

  • PurchaseHeader Record "Purch. Cr. Memo Hdr."


CollectCommLedgerEntryFromSalesp

procedure CollectCommLedgerEntryFromSalesp(var EOSCommDocLedgerEntry: Record "EOS Comm. Doc. Ledger Entry"; SalespersonPurchaser: Record "Salesperson/Purchaser"; ApplyFilter: Option "All","OnlyClosed","OnlyOpen")

Parameters / Return Value

  • EOSCommDocLedgerEntry Record "EOS Comm. Doc. Ledger Entry"

  • SalespersonPurchaser Record "Salesperson/Purchaser"

  • ApplyFilter Option

    "All" (0) , "OnlyClosed" (1) , "OnlyOpen" (2)


HasEntriesInSettlement

procedure HasEntriesInSettlement(var EOSCommissionLedgerEntry: Record "EOS Comm. Doc. Ledger Entry"; RaiseErr: Boolean): Boolean

Parameters / Return Value

  • EOSCommissionLedgerEntry Record "EOS Comm. Doc. Ledger Entry"

  • RaiseErr Boolean

  • Returns Boolean


CheckModifyCustLedgerEntry

procedure CheckModifyCustLedgerEntry(CustLedgerEntryRec: Record "Cust. Ledger Entry"; CustLedgerEntry: Record "Cust. Ledger Entry")

Parameters / Return Value

  • CustLedgerEntryRec Record "Cust. Ledger Entry"

  • CustLedgerEntry Record "Cust. Ledger Entry"


CheckUnapplyCustEntrySettled

procedure CheckUnapplyCustEntrySettled(DetailedCustLedgEntry: Record "Detailed Cust. Ledg. Entry"; HideDialog: Boolean) Block: Boolean

Parameters / Return Value

  • DetailedCustLedgEntry Record "Detailed Cust. Ledg. Entry"

  • HideDialog Boolean

  • Returns Boolean


GetSettlementEndingDate

procedure GetSettlementEndingDate(SalespersonPurchaser: Record "Salesperson/Purchaser"; EOSCommissionPeriod: Record "EOS Commission Period") RefDate: date

Parameters / Return Value

  • SalespersonPurchaser Record "Salesperson/Purchaser"

  • EOSCommissionPeriod Record "EOS Commission Period"

  • Returns date


GetSettlementEndingDate

procedure GetSettlementEndingDate(SalespersonPurchaser: Record "Salesperson/Purchaser"; inStartingDate: Date; inEndingDate: Date) RefDate: date

Parameters / Return Value

  • SalespersonPurchaser Record "Salesperson/Purchaser"

  • inStartingDate Date

  • inEndingDate Date

  • Returns date


AddDimensionsToDimSet

procedure AddDimensionsToDimSet(var outDimSetID: Integer; inDimSetID: Integer)

Parameters / Return Value

  • outDimSetID Integer

  • inDimSetID Integer


UpdateCommissionDueDateFromCLE

procedure UpdateCommissionDueDateFromCLE(CLE: integer; NewDueDate: Date)

Parameters / Return Value

  • CLE integer

  • NewDueDate Date


CheckCLERenegotiable

procedure CheckCLERenegotiable(CLE: integer; HideDialog: Boolean; TrapError: Boolean; var ErrorText: Text) IsRenegotiable: Boolean

Parameters / Return Value

  • CLE integer

  • HideDialog Boolean

  • TrapError Boolean

  • ErrorText Text

  • Returns Boolean


IsRenegotiated

procedure IsRenegotiated(CustLedgerEntry: Record "Cust. Ledger Entry"): Boolean

Parameters / Return Value

  • CustLedgerEntry Record "Cust. Ledger Entry"

  • Returns Boolean



EOS Labs -