project QadFinancials > class BJournalEntry > method AddStandardPosting

Description

add a posting line on any gl account (except control and VAT accounts) to current posting


Parameters


icPostingtcRowidinputcharactertposting.tc_Rowid
icGLCodeinputcharactergl account
icDivisionCodeinputcharacterSub-Account
icCostCentreCodeinputcharactercost centre
icCostCentreTextinputcharacterText
icProjectCodeinputcharacterproject
icProjectTextinputcharacterText
icIntercoBusinessRelationCodeinputcharacterinterco
icCurrencyCodeinputcharactercurrency
idDebitTCinputdecimalDebitTC
idDebitLCinputdecimalDebitLC (use NULL if value should be calculated)
idDebitCCinputdecimalDebitCC (use NULL if value should be calculated)
idDebitPCinputdecimalDebitPC (use NULL if value should be calculated)
idCreditTCinputdecimalCreditTC
idCreditLCinputdecimalCreditLC (use NULL if value should be calculated)
idCreditCCinputdecimalCreditCC (use NULL if value should be calculated)
idCreditPCinputdecimalCreditPC (use NULL if value should be calculated)
idQtyinputdecimalQuantity
icLineTextinputcharacterText
icSafTextinputcharacterText
tDefaultSafsinputtemp-tabledefault saf's
icExchangeRateTypeinputcharacterexchange rate type
idExchangeRateinputdecimal
idExchangeRateScaleinputdecimal
idPostingLineCCRateinputdecimal
idPostingLineCCScaleinputdecimal
oiPostingLineIdoutputintegerPosting Line ID
iiSafStructureIdinputintegerSaf Structure ID : necessary for posting on project, cost centre, .. so that you knows which saf structure you must take, if this is blank, then the first one will be taken
icSafStructureCodeinputcharacterSaf Structure Code : necessary for posting on project, cost centre, .. so that you knows which saf structure you must take, if this is blank, then the first one will be taken
icAllocationKeyinputcharacter
ilLinkedCrCyDaemonReqExistsinputlogical
itExchangeRateDateinputdate
oiReturnStatusoutputintegerReturn status of the method.


Internal usage


QadFinancials
method BAPMatching.AdditionalUpdatesAllCosts
method BAPMatching.AdditionalUpdatesAllCreatePLCirec
method BAPMatching.AdditionalUpdatesAllLinesPLAddPostingLine
method BAPMatching.AdditionalUpdatesAllLinesPLAddPostingLineOpAllocCode
method BBankEntry.AdditionalUpdatesInv
method BBankEntry.AdditionalUpdatesInvCurrDiff
method BBankEntry.AdditionalUpdatesInvDeductions
method BBankEntry.AdditionalUpdatesInvDiscountCurrDiff
method BBankEntry.AdditionalUpdatesInvDiscountCurrDiffTax
method BBankEntry.AdditionalUpdatesInvRounding
method BCDocument.AdditionalUpdatesPostingCrossCy
method BCDocument.AdditionalUpdatesPostingDocCtrl
method BCDocument.AdditionalUpdatesPostingDocCtrl3
method BCDocument.AdditionalUpdatesPostingPrePayment
method BCDocument.AdditionalUpdatesPostingRounding
method BCDocument.AdditionalUpdatesPostingXrefCIDisc
method BCDocument.AdditionalUpdatesPostingXrefCIDiscTax
method BCDocument.AdditionalUpdatesPostingXrefCIInt
method BCDocument.AdditionalUpdatesPostingXrefDI
method BCDocument.AdditionalUpdatesPostingXRefWHT
method BCInvoice.CreateCInvoiceMovementsCrossCy
method BCInvoice.CreateCInvoiceMovementsRoundDiff
method BCInvoice.CreateCInvoiceMovementsRoundDiffCC
method BCInvoice.CreateCIPosting2
method BCInvoice.CreateMFPosting
method BConsolid.AdditionalUpdatesPosting
method BDDocument.AdditionalUpdatesPostingDeduction
method BDDocument.AdditionalUpdatesPostingDocCtrl
method BDDocument.AdditionalUpdatesPostingDocCtrl3
method BDDocument.AdditionalUpdatesPostingPrePayment
method BDDocument.AdditionalUpdatesPostingRounding
method BDDocument.AdditionalUpdatesPostingXrefDIDisc
method BDDocument.AdditionalUpdatesPostingXrefDIDisc2
method BDDocument.AdditionalUpdatesPostingXrefDIInt
method BDInvoice.CreateDInvoiceMovementsCrossCy
method BDInvoice.CreateDInvoiceMovementsRoundDiff
method BDInvoice.CreateDInvoiceMovementsRoundDiffCC
method BDInvoice.CreateDInvoicesDeduction
method BDInvoice.CreateDIPosting
method BDInvoice.CreateDIPostingSales
method BDInvoice.UpdateDeductionDetailPosting
method BExpenseNote.ExpNoteRegisterPosting
method BFixedAssetDepreciation.AdditionalUpdatesPosting
method BFixedAssetDisposal.AdditionalUpdatesPosting
method BFixedAssetRevaluation.AdditionalUpdatesPosting
method BGLOpenItemProcessor.GLOpenItemInitializationPosting
method BJournalEntry.CreateReverseEntries
method BOpenItemAdjustment.OIAdjCommitSubCheckPostingBalanceLCCC
method BOpenItemAdjustment.OIAdjCommitSubCInvoiceDiscount
method BOpenItemAdjustment.OIAdjCommitSubDInvoiceDiscount
method BQCrossCyPosting.ApiProcessQCrossCyPosting
method BQCrossCyPosting.ApiProcessQCrossCyPostingForAPM
method BSelfBill.ApiCreateInvPrepayPaymentSubPostERD
method BYearClosing.AdditionalUpdatesPostingCloseOpenBS
method BYearClosing.AdditionalUpdatesPostingCloseOpenPL
method BYearClosing.AdditionalUpdatesPostingTrans


program code (program/bjournalentry.p)

<ANCESTOR-CODE>

    /* ======================================= */
    /* Return in case ancestor returned errors */
    /* ======================================= */
    if oiReturnStatus < 0
    then return.
    
    /* ==================================================================================================== */
    /* Create enabling information based upon tqGLForPostingLineCreationCopy (available from ancestor-code) */
    /* ==================================================================================================== */
    find first tqGLForPostingLineCreationCpy.
    if tqGLForPostingLineCreationCpy.tlGLIsAutomaticAccount = false
    then do :
        create tPostingLineEnabling.
        assign tPostingLineEnabling.tc_Rowid            = tPostingLine.tc_Rowid
               tPostingLineEnabling.tcBusinessFieldName = "tPostingLine.tcDivisionCode":U
               tPostingLineEnabling.tlEnabled           = tqGLForPostingLineCreationCpy.tlGLIsDivisionAccount.
        create tPostingLineEnabling.
        assign tPostingLineEnabling.tc_Rowid            = tPostingLine.tc_Rowid
               tPostingLineEnabling.tcBusinessFieldName = "tPostingLine.tcCostCentreCode":U
               tPostingLineEnabling.tlEnabled           = tqGLForPostingLineCreationCpy.tlGLIsCostCentreAccount.
        create tPostingLineEnabling.
        assign tPostingLineEnabling.tc_Rowid            = tPostingLine.tc_Rowid
               tPostingLineEnabling.tcBusinessFieldName = "tPostingLine.tcProjectCode":U
               tPostingLineEnabling.tlEnabled           = tqGLForPostingLineCreationCpy.tlGLIsProjectAccount.
        create tPostingLineEnabling.
        assign tPostingLineEnabling.tc_Rowid            = tPostingLine.tc_Rowid
               tPostingLineEnabling.tcBusinessFieldName = "tPostingLine.tcIntercoBusinessRelationCode":U
               tPostingLineEnabling.tlEnabled           = tqGLForPostingLineCreationCpy.tlGLIsIntercoAccount and tqGLForPostingLineCreationCpy.tlGLIsFixedInterco = false.
        create tPostingLineEnabling.
        assign tPostingLineEnabling.tc_Rowid            = tPostingLine.tc_Rowid
               tPostingLineEnabling.tcBusinessFieldName = "tPostingLine.PostingLineQTY":U
               tPostingLineEnabling.tlEnabled           = tqGLForPostingLineCreationCpy.tlGLIsQuantityAccount.
        create tPostingLineEnabling.
        assign tPostingLineEnabling.tc_Rowid            = tPostingLine.tc_Rowid
               tPostingLineEnabling.tcBusinessFieldName = "tPostingLine.tcCurrencyCode":U
               tPostingLineEnabling.tlEnabled           = tqGLForPostingLineCreationCpy.tiCurrency_ID = 0 and tqGLForPostingLineCreationCpy.tlGLIsLocalCurrency = false.
    end. /* if tqGLForPostingLineCreation.tlGLIsAutomaticAccount = false  */