Share via


Codeunit "Serv-Posting Journals Mgt."

ID 5987
Namespace: Microsoft.Service.Posting

Methods

Initialize

procedure Initialize(var TempServHeader: Record "Service Header", TmpConsume: Boolean, TmpInvoice: Boolean)

Parameters

Name Type Description
TempServHeader Table Microsoft.Service.Document."Service Header"
TmpConsume Boolean
TmpInvoice Boolean

Finalize

procedure Finalize()

SetPostingOptions

procedure SetPostingOptions(PassedConsume: Boolean, PassedInvoice: Boolean)

Parameters

Name Type Description
PassedConsume Boolean
PassedInvoice Boolean

SetItemJnlRollRndg

procedure SetItemJnlRollRndg(PassedItemJnlRollRndg: Boolean)

Parameters

Name Type Description
PassedItemJnlRollRndg Boolean

SetGenJnlLineDocNos

procedure SetGenJnlLineDocNos(DocNo: Code[20], ExtDocNo: Code[35])

Parameters

Name Type Description
DocNo Code[20]
ExtDocNo Code[35]

PostItemJnlLine

procedure PostItemJnlLine(var ServiceLine: Record "Service Line", QtyToBeShipped: Decimal, QtyToBeShippedBase: Decimal, QtyToBeConsumed: Decimal, QtyToBeConsumedBase: Decimal, QtyToBeInvoiced: Decimal, QtyToBeInvoicedBase: Decimal, ItemLedgShptEntryNo: Integer, var TrackingSpecification: Record "Tracking Specification", var TempTrackingSpecificationInv: Record "Tracking Specification", var TempHandlingSpecification: Record "Tracking Specification", var TempTrackingSpecification: Record "Tracking Specification" temporary, var ServShptHeader: Record "Service Shipment Header", ServShptLineDocNo: Code[20]): Integer

Parameters

Name Type Description
ServiceLine Table Microsoft.Service.Document."Service Line"
QtyToBeShipped Decimal
QtyToBeShippedBase Decimal
QtyToBeConsumed Decimal
QtyToBeConsumedBase Decimal
QtyToBeInvoiced Decimal
QtyToBeInvoicedBase Decimal
ItemLedgShptEntryNo Integer
TrackingSpecification Table Microsoft.Inventory.Tracking."Tracking Specification"
TempTrackingSpecificationInv Table Microsoft.Inventory.Tracking."Tracking Specification"
TempHandlingSpecification Table Microsoft.Inventory.Tracking."Tracking Specification"
TempTrackingSpecification Table Microsoft.Inventory.Tracking."Tracking Specification"
ServShptHeader Table Microsoft.Service.History."Service Shipment Header"
ServShptLineDocNo Code[20]

Returns

Type Description
Integer

PostLines

procedure PostLines(ServiceHeader: Record "Service Header", var InvoicePostingInterface: Interface "Invoice Posting", var Window: Dialog, var TotalAmount: Decimal)

Parameters

Name Type Description
ServiceHeader Table Microsoft.Service.Document."Service Header"
InvoicePostingInterface Interface Microsoft.Finance.ReceivablesPayables."Invoice Posting"
Window Dialog
TotalAmount Decimal

PostLedgerEntry

procedure PostLedgerEntry(ServiceHeader: Record "Service Header", var InvoicePostingInterface: Interface "Invoice Posting")

Parameters

Name Type Description
ServiceHeader Table Microsoft.Service.Document."Service Header"
InvoicePostingInterface Interface Microsoft.Finance.ReceivablesPayables."Invoice Posting"

PostBalancingEntry

procedure PostBalancingEntry(ServiceHeader: Record "Service Header", var InvoicePostingInterface: Interface "Invoice Posting")

Parameters

Name Type Description
ServiceHeader Table Microsoft.Service.Document."Service Header"
InvoicePostingInterface Interface Microsoft.Finance.ReceivablesPayables."Invoice Posting"

PostResJnlLineShip

procedure PostResJnlLineShip(var ServiceLine: Record "Service Line", DocNo: Code[20], ExtDocNo: Code[35])

Parameters

Name Type Description
ServiceLine Table Microsoft.Service.Document."Service Line"
DocNo Code[20]
ExtDocNo Code[35]

PostResJnlLineUndoUsage

procedure PostResJnlLineUndoUsage(var ServiceLine: Record "Service Line", DocNo: Code[20], ExtDocNo: Code[35])

Parameters

Name Type Description
ServiceLine Table Microsoft.Service.Document."Service Line"
DocNo Code[20]
ExtDocNo Code[35]

PostResJnlLineSale

procedure PostResJnlLineSale(var ServiceLine: Record "Service Line", DocNo: Code[20], ExtDocNo: Code[35])

Parameters

Name Type Description
ServiceLine Table Microsoft.Service.Document."Service Line"
DocNo Code[20]
ExtDocNo Code[35]

PostResJnlLineConsume

procedure PostResJnlLineConsume(var ServiceLine: Record "Service Line", var ServShptHeader: Record "Service Shipment Header")

Parameters

Name Type Description
ServiceLine Table Microsoft.Service.Document."Service Line"
ServShptHeader Table Microsoft.Service.History."Service Shipment Header"

InitServiceRegister

procedure InitServiceRegister(var NextServLedgerEntryNo: Integer, var NextWarrantyLedgerEntryNo: Integer)

Parameters

Name Type Description
NextServLedgerEntryNo Integer
NextWarrantyLedgerEntryNo Integer

FinishServiceRegister

procedure FinishServiceRegister(var nextServEntryNo: Integer, var nextWarrantyEntryNo: Integer)

Parameters

Name Type Description
nextServEntryNo Integer
nextWarrantyEntryNo Integer

InsertServLedgerEntry

procedure InsertServLedgerEntry(var NextEntryNo: Integer, var ServiceHeader: Record "Service Header", var ServiceLine: Record "Service Line", var ServItemLine: Record "Service Item Line", Qty: Decimal, DocNo: Code[20]): Integer

Parameters

Name Type Description
NextEntryNo Integer
ServiceHeader Table Microsoft.Service.Document."Service Header"
ServiceLine Table Microsoft.Service.Document."Service Line"
ServItemLine Table Microsoft.Service.Document."Service Item Line"
Qty Decimal
DocNo Code[20]

Returns

Type Description
Integer

InsertServLedgerEntrySale

procedure InsertServLedgerEntrySale(var passedNextEntryNo: Integer, var ServHeader: Record "Service Header", var ServLine: Record "Service Line", var ServItemLine: Record "Service Item Line", Qty: Decimal, QtyToCharge: Decimal, GenJnlLineDocNo: Code[20], DocLineNo: Integer)

Parameters

Name Type Description
passedNextEntryNo Integer
ServHeader Table Microsoft.Service.Document."Service Header"
ServLine Table Microsoft.Service.Document."Service Line"
ServItemLine Table Microsoft.Service.Document."Service Item Line"
Qty Decimal
QtyToCharge Decimal
GenJnlLineDocNo Code[20]
DocLineNo Integer

CreateCreditEntry

procedure CreateCreditEntry(var passedNextEntryNo: Integer, var ServHeader: Record "Service Header", var ServLine: Record "Service Line", GenJnlLineDocNo: Code[20])

Parameters

Name Type Description
passedNextEntryNo Integer
ServHeader Table Microsoft.Service.Document."Service Header"
ServLine Table Microsoft.Service.Document."Service Line"
GenJnlLineDocNo Code[20]

InsertWarrantyLedgerEntry

procedure InsertWarrantyLedgerEntry(var NextWarrantyEntryNo: Integer, var ServiceHeader: Record "Service Header", var ServiceLine: Record "Service Line", var ServItemLine: Record "Service Item Line", Qty: Decimal, GenJnlLineDocNo: Code[20]): Integer

Parameters

Name Type Description
NextWarrantyEntryNo Integer
ServiceHeader Table Microsoft.Service.Document."Service Header"
ServiceLine Table Microsoft.Service.Document."Service Line"
ServItemLine Table Microsoft.Service.Document."Service Item Line"
Qty Decimal
GenJnlLineDocNo Code[20]

Returns

Type Description
Integer

CalcSLEDivideAmount

procedure CalcSLEDivideAmount(Qty: Decimal, var passedServHeader: Record "Service Header", var passedTempServLine: Record "Service Line", var passedVATAmountLine: Record "VAT Amount Line")

Parameters

Name Type Description
Qty Decimal
passedServHeader Table Microsoft.Service.Document."Service Header"
passedTempServLine Table Microsoft.Service.Document."Service Line"
passedVATAmountLine Table Microsoft.Finance.VAT.Calculation."VAT Amount Line"

TestSrvCostDirectPost

procedure TestSrvCostDirectPost(ServLineNo: Code[20])

Parameters

Name Type Description
ServLineNo Code[20]

TestGLAccDirectPost

procedure TestGLAccDirectPost(ServLineNo: Code[20])

Parameters

Name Type Description
ServLineNo Code[20]

CollectValueEntryRelation

procedure CollectValueEntryRelation(var PassedValueEntryRelation: Record "Value Entry Relation", RowId: Text[100])

Parameters

Name Type Description
PassedValueEntryRelation Table Microsoft.Inventory.Ledger."Value Entry Relation"
RowId Text[100]

PostJobJnlLine

procedure PostJobJnlLine(var ServHeader: Record "Service Header", ServLine: Record "Service Line", QtyToBeConsumed: Decimal): Boolean

Parameters

Name Type Description
ServHeader Table Microsoft.Service.Document."Service Header"
ServLine Table Microsoft.Service.Document."Service Line"
QtyToBeConsumed Decimal

Returns

Type Description
Boolean

SetPostingDate

Obsolete

This element will become obsolete from version 26.0. The variable ServiceLinePostingDate is initialized but not used.

[Obsolete(The variable ServiceLinePostingDate is initialized but not used.,26.0)]
procedure SetPostingDate(PostingDate: Date)

Parameters

Name Type Description
PostingDate Date

Events

OnAfterTransferValuesToJobJnlLine

[IntegrationEvent(False,False)]
local procedure OnAfterTransferValuesToJobJnlLine(var JobJournalLine: Record "Job Journal Line", ServiceLine: Record "Service Line")

Parameters

Name Type Description
JobJournalLine Table Microsoft.Projects.Project.Journal."Job Journal Line"
ServiceLine Table Microsoft.Service.Document."Service Line"

OnBeforePostItemJnlLine

[IntegrationEvent(False,False)]
local procedure OnBeforePostItemJnlLine(var ItemJournalLine: Record "Item Journal Line", ServiceShipmentHeader: Record "Service Shipment Header", ServiceLine: Record "Service Line", GenJnlLineDocNo: Code[20], QtyToBeShipped: Decimal, QtyToBeShippedBase: Decimal, QtyToBeInvoiced: Decimal, QtyToBeInvoicedBase: Decimal)

Parameters

Name Type Description
ItemJournalLine Table Microsoft.Inventory.Journal."Item Journal Line"
ServiceShipmentHeader Table Microsoft.Service.History."Service Shipment Header"
ServiceLine Table Microsoft.Service.Document."Service Line"
GenJnlLineDocNo Code[20]
QtyToBeShipped Decimal
QtyToBeShippedBase Decimal
QtyToBeInvoiced Decimal
QtyToBeInvoicedBase Decimal

OnBeforePostJobJnlLine

[IntegrationEvent(False,False)]
local procedure OnBeforePostJobJnlLine(var ServiceHeader: Record "Service Header", var ServiceLine: Record "Service Line", QtyToBeConsumed: Decimal, var Result: Boolean, var IsHandled: Boolean)

Parameters

Name Type Description
ServiceHeader Table Microsoft.Service.Document."Service Header"
ServiceLine Table Microsoft.Service.Document."Service Line"
QtyToBeConsumed Decimal
Result Boolean
IsHandled Boolean

OnBeforeResJnlPostLine

[IntegrationEvent(False,False)]
local procedure OnBeforeResJnlPostLine(var ResJnlLine: Record "Res. Journal Line", ServiceHeader: Record "Service Header", ServiceLine: Record "Service Line")

Parameters

Name Type Description
ResJnlLine Table Microsoft.Projects.Resources.Journal."Res. Journal Line"
ServiceHeader Table Microsoft.Service.Document."Service Header"
ServiceLine Table Microsoft.Service.Document."Service Line"

OnPostItemJnlLineOnBeforeCreateWhseJnlLine

[IntegrationEvent(False,False)]
local procedure OnPostItemJnlLineOnBeforeCreateWhseJnlLine(var ItemJournalLine: Record "Item Journal Line", ServiceHeader: Record "Service Header", var ShouldCreateWhseJnlLine: Boolean, ServiceShipmentHeader: Record "Service Shipment Header", var ServiceLine: Record "Service Line", var TempWarehouseJournalLine: Record "Warehouse Journal Line" temporary, var WhsePosting: Boolean, var CheckApplFromItemEntry: Boolean)

Parameters

Name Type Description
ItemJournalLine Table Microsoft.Inventory.Journal."Item Journal Line"
ServiceHeader Table Microsoft.Service.Document."Service Header"
ShouldCreateWhseJnlLine Boolean
ServiceShipmentHeader Table Microsoft.Service.History."Service Shipment Header"
ServiceLine Table Microsoft.Service.Document."Service Line"
TempWarehouseJournalLine Table Microsoft.Warehouse.Journal."Warehouse Journal Line"
WhsePosting Boolean
CheckApplFromItemEntry Boolean

OnPostJobJnlLineOnBeforeCalcCurrencyFactor

[IntegrationEvent(False,False)]
local procedure OnPostJobJnlLineOnBeforeCalcCurrencyFactor(ServLine: Record "Service Line", var CurrExchRate: Record "Currency Exchange Rate")

Parameters

Name Type Description
ServLine Table Microsoft.Service.Document."Service Line"
CurrExchRate Table Microsoft.Finance.Currency."Currency Exchange Rate"

OnPostJobJnlLineOnBeforeValidateNo

[IntegrationEvent(False,False)]
local procedure OnPostJobJnlLineOnBeforeValidateNo(var JobJournalLine: Record "Job Journal Line", ServiceLine: Record "Service Line")

Parameters

Name Type Description
JobJournalLine Table Microsoft.Projects.Project.Journal."Job Journal Line"
ServiceLine Table Microsoft.Service.Document."Service Line"

OnPostResJnlLineOnAfterResJnlLineInit

[IntegrationEvent(False,False)]
local procedure OnPostResJnlLineOnAfterResJnlLineInit(var ResJnlLine: Record "Res. Journal Line", EntryType: Enum "Res. Journal Line Entry Type", Qty: Decimal)

Parameters

Name Type Description
ResJnlLine Table Microsoft.Projects.Resources.Journal."Res. Journal Line"
EntryType Enum Microsoft.Projects.Resources.Journal."Res. Journal Line Entry Type"
Qty Decimal

OnAfterPostItemJnlLine

[IntegrationEvent(False,False)]
local procedure OnAfterPostItemJnlLine(ServiceHeader: Record "Service Header", var ItemJournalLine: Record "Item Journal Line", var TempHandlingTrackingSpecification: Record "Tracking Specification")

Parameters

Name Type Description
ServiceHeader Table Microsoft.Service.Document."Service Header"
ItemJournalLine Table Microsoft.Inventory.Journal."Item Journal Line"
TempHandlingTrackingSpecification Table Microsoft.Inventory.Tracking."Tracking Specification"

OnAfterPostResJnlLine

[IntegrationEvent(False,False)]
local procedure OnAfterPostResJnlLine(ServiceHeader: Record "Service Header", var ResJournalLine: Record "Res. Journal Line")

Parameters

Name Type Description
ServiceHeader Table Microsoft.Service.Document."Service Header"
ResJournalLine Table Microsoft.Projects.Resources.Journal."Res. Journal Line"

OnBeforePostResJnlLineShip

[IntegrationEvent(False,False)]
local procedure OnBeforePostResJnlLineShip(var ServiceLine: Record "Service Line", DocNo: Code[20], ExtDocNo: Code[35], var IsHandled: Boolean)

Parameters

Name Type Description
ServiceLine Table Microsoft.Service.Document."Service Line"
DocNo Code[20]
ExtDocNo Code[35]
IsHandled Boolean

OnBeforePostResJnlLineConsume

[IntegrationEvent(False,False)]
local procedure OnBeforePostResJnlLineConsume(var ServiceLine: Record "Service Line", var ServiceShipmentHeader: Record "Service Shipment Header", var IsHandled: Boolean)

Parameters

Name Type Description
ServiceLine Table Microsoft.Service.Document."Service Line"
ServiceShipmentHeader Table Microsoft.Service.History."Service Shipment Header"
IsHandled Boolean

See also