指派給銷售的交貨的項目電量折扣優惠不會根據選取的選項,Microsoft 動態航行點 2009年中的個別值,項目發佈到。請依照下列程式碼變更一節,若要解決這個問題的步驟。下列產品中,就會發生這個問題︰
-
Microsoft 動態航行點 2009 R2
-
Microsoft 動態航行點 2009 Service Pack 1 (SP1)
解決方案
Hotfix 資訊
已經可以從 Microsoft 取得支援的 hotfix。不過,它只被用來修正本文所述的問題。它只適用於發生此特定問題的系統上。此 hotfix 可能會接受其他測試。因此,如果此問題不會嚴重影響,我們建議您等候下一步的 Microsoft 動態航行點 2009 service pack 或包含此 hotfix 的下一個 Microsoft 動態航行點版本。
注意 在特殊的情況下,通常會支援呼叫可能已被取消如果技術支援專業人員的 Microsoft 動態及相關的產品所產生的費用會決定某特定更新程式可以解決您的問題。收取支援費用會套用,如果有其他支援問題是,不能限定的特定更新程式。安裝資訊
Microsoft 會提供程式設計範例僅供說明,而不做任何明示或默示的保證。這包括,但不限於適售性或適合某特定用途之默示擔保責任。本文假設您已相當熟悉使用的我們所示範的程式設計語言以及建立和偵錯程序所使用的工具。Microsoft 技術支援工程師可以協助解釋特定程序的功能。不過,它們不會修改這些範例以提供附加功能或建構程序來滿足您特定需求。
注意套用此 hotfix 之前,請確認所有的 Microsoft 動態航行點用戶端使用者會登出系統。這包括 Microsoft 動態航行點應用程式伺服器 (NAS) 服務。您應該是唯一的用戶端使用者已登入,當您實作此 hotfix。 若要實作此 hotfix,您必須有開發人員授權。 我們建議您在 Windows 登入] 視窗中的色彩,或資料庫登入] 視窗中的使用者帳戶被指派 「 進階 」 的角色識別碼。如果使用者帳戶不能指派為 「 超級 」 的角色識別碼,您必須確認使用者帳戶具有下列權限︰-
您將會變更物件的 [修改] 權限。
-
執行權限的系統物件 ID 5210物件和系統物件 ID 9015
物件。
注意您沒有擁有資料存放區的權限,除非您需要執行資料修復。
程式碼變更
注意永遠測試程式碼修正在受控制的環境中才能套用到實際執行電腦的修正程式。
若要解決這個問題,請依照下列步驟執行:-
變更中屬性的程式碼,在銷售張貼 codeunit (80) 如下所示︰
現有的程式碼 1...PostJobContractLine(JobTaskSalesLine,TempJnlLineDim2);
END; SalesLine.Type::"Charge (Item)": IF Invoice OR ItemChargeAssgntOnly THEN BEGIN // Delete the following line. ItemJnlRollRndg := FALSE; // End of the deleted line. ClearItemChargeAssgntFilter; TempItemChargeAssgntSales.SETCURRENTKEY("Applies-to Doc. Type"); TempItemChargeAssgntSales.SETRANGE("Document Line No.",SalesLine."Line No."); IF TempItemChargeAssgntSales.FINDSET THEN ...取代程式碼 1
...PostJobContractLine(JobTaskSalesLine,TempJnlLineDim2);
END; SalesLine.Type::"Charge (Item)": IF Invoice OR ItemChargeAssgntOnly THEN BEGIN // Add the following line. ItemJnlRollRndg := TRUE; // End of the added line. ClearItemChargeAssgntFilter; TempItemChargeAssgntSales.SETCURRENTKEY("Applies-to Doc. Type"); TempItemChargeAssgntSales.SETRANGE("Document Line No.",SalesLine."Line No."); IF TempItemChargeAssgntSales.FINDSET THEN ...現有的程式碼 2
...GenJnlLineDocNo := TempItemChargeAssgntSales."Applies-to Doc. No.";
CASE TempItemChargeAssgntSales."Applies-to Doc. Type" OF TempItemChargeAssgntSales."Applies-to Doc. Type"::Shipment: BEGIN // Delete the following line. PostItemChargePerShpt(SalesLine); TempItemChargeAssgntSales.MARK(TRUE); END; TempItemChargeAssgntSales."Applies-to Doc. Type"::"Return Receipt": BEGIN ...取代程式碼 2
...GenJnlLineDocNo := TempItemChargeAssgntSales."Applies-to Doc. No.";
CASE TempItemChargeAssgntSales."Applies-to Doc. Type" OF TempItemChargeAssgntSales."Applies-to Doc. Type"::Shipment: BEGIN // Add the following lines. PostItemChargePerShpt(SalesLine,SalesLine."Inv. Discount Amount", SalesLine.Quantity,SalesLine."Line Discount Amount",SalesLine."Line Amount"); // End of the added lines. TempItemChargeAssgntSales.MARK(TRUE); END; TempItemChargeAssgntSales."Applies-to Doc. Type"::"Return Receipt": BEGIN ...現有的程式碼 3
...TempItemChargeAssgntSales.MARK(TRUE);
END; TempItemChargeAssgntSales."Applies-to Doc. Type"::"Return Receipt": BEGIN // Delete the following line. PostItemChargePerRetRcpt(SalesLine); TempItemChargeAssgntSales.MARK(TRUE); END; TempItemChargeAssgntSales."Applies-to Doc. Type"::Order, TempItemChargeAssgntSales."Applies-to Doc. Type"::Invoice: ...取代程式碼 3
...TempItemChargeAssgntSales.MARK(TRUE);
END; TempItemChargeAssgntSales."Applies-to Doc. Type"::"Return Receipt": BEGIN // Add the following lines. PostItemChargePerRetRcpt(SalesLine,SalesLine."Inv. Discount Amount", SalesLine.Quantity,SalesLine."Line Discount Amount",SalesLine."Line Amount"); // End of the added lines. TempItemChargeAssgntSales.MARK(TRUE); END; TempItemChargeAssgntSales."Applies-to Doc. Type"::Order, TempItemChargeAssgntSales."Applies-to Doc. Type"::Invoice: ... -
變更銷售張貼 codeunit (80) 的PostItemChargePerShpt函式中的程式碼如下所示︰
現有的程式碼 1...END;
END; END; // Delete the following line. LOCAL PROCEDURE PostItemChargePerShpt@5807(SalesLine@1000 : Record 37); VAR SalesShptLine@1003 : Record 111; TempItemLedgEntry@1010 : TEMPORARY Record 32; ItemTrackingMgt@1009 : Codeunit 6500; ...取代程式碼 1
...END;
END; END; // Add the following line. LOCAL PROCEDURE PostItemChargePerShpt@5807(SalesLine@1000 : Record 37;VAR TotalInvDiscAmtRemaining@1012 : Decimal;VAR TotalQtyRemaining@1013 : Decimal;VAR TotalLineDiscAmtRemaining@1014 : Decimal;VAR TotalLineAmtRemaining@1015 : Decimal); VAR SalesShptLine@1003 : Record 111; TempItemLedgEntry@1010 : TEMPORARY Record 32; ItemTrackingMgt@1009 : Codeunit 6500; ...現有的程式碼 2
...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(SalesLine, TempItemLedgEntry."Entry No.",ABS(TempItemLedgEntry.Quantity), // Delete the following line. AmountToAssign,QtyToAssign); NonDistrQuantity := NonDistrQuantity - ABS(TempItemLedgEntry.Quantity); NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...取代程式碼 2
...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(SalesLine, TempItemLedgEntry."Entry No.",ABS(TempItemLedgEntry.Quantity), // Add the following lines. AmountToAssign,QtyToAssign,TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. NonDistrQuantity := NonDistrQuantity - ABS(TempItemLedgEntry.Quantity); NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...現有的程式碼 3
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(SalesLine, TempItemLedgEntry."Entry No.",ABS(TempItemLedgEntry.Quantity), // Delete the following line. NonDistrAmountToAssign,NonDistrQtyToAssign); UNTIL TempItemLedgEntry.NEXT = 0; END ELSE PostItemCharge(SalesLine, SalesShptLine."Item Shpt. Entry No.",SalesShptLine."Quantity (Base)", ...取代程式碼 3
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(SalesLine, TempItemLedgEntry."Entry No.",ABS(TempItemLedgEntry.Quantity), // Add the following lines. NonDistrAmountToAssign,NonDistrQtyToAssign,TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. UNTIL TempItemLedgEntry.NEXT = 0; END ELSE PostItemCharge(SalesLine, SalesShptLine."Item Shpt. Entry No.",SalesShptLine."Quantity (Base)", ...現有的程式碼 4
...END ELSE
PostItemCharge(SalesLine, SalesShptLine."Item Shpt. Entry No.",SalesShptLine."Quantity (Base)", TempItemChargeAssgntSales."Amount to Assign", // Delete the following lines. TempItemChargeAssgntSales."Qty. to Assign"); END; LOCAL PROCEDURE PostItemChargePerRetRcpt@5810(SalesLine@1000 : Record 37); // End of the deleted lines. VAR ReturnRcptLine@1002 : Record 6661; TempItemLedgEntry@1010 : TEMPORARY Record 32; ItemTrackingMgt@1009 : Codeunit 6500; ...取代程式碼 4
...END ELSE
PostItemCharge(SalesLine, SalesShptLine."Item Shpt. Entry No.",SalesShptLine."Quantity (Base)", TempItemChargeAssgntSales."Amount to Assign", // Add the following lines. TempItemChargeAssgntSales."Qty. to Assign",TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); END; LOCAL PROCEDURE PostItemChargePerRetRcpt@5810(SalesLine@1000 : Record 37;VAR TotalInvDiscAmtRemaining@1012 : Decimal;VAR TotalQtyRemaining@1013 : Decimal;VAR TotalLineDiscAmtRemaining@1014 : Decimal;VAR TotalLineAmtRemaining@1015 : Decimal); // End of the added lines. VAR ReturnRcptLine@1002 : Record 6661; TempItemLedgEntry@1010 : TEMPORARY Record 32; ItemTrackingMgt@1009 : Codeunit 6500; ... -
變更銷售張貼 codeunit (80) 的PostItemChargePerRetRcpt函式中的程式碼如下所示︰
現有的程式碼 1...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(SalesLine, TempItemLedgEntry."Entry No.",ABS(TempItemLedgEntry.Quantity), // Delete the following line. AmountToAssign,QtyToAssign); NonDistrQuantity := NonDistrQuantity - ABS(TempItemLedgEntry.Quantity); NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...取代程式碼 1
...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(SalesLine, TempItemLedgEntry."Entry No.",ABS(TempItemLedgEntry.Quantity), // Add the following lines. AmountToAssign,QtyToAssign,TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. NonDistrQuantity := NonDistrQuantity - ABS(TempItemLedgEntry.Quantity); NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...現有的程式碼 2
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(SalesLine, TempItemLedgEntry."Entry No.",ABS(TempItemLedgEntry.Quantity), // Delete the following line. NonDistrAmountToAssign,NonDistrQtyToAssign); UNTIL TempItemLedgEntry.NEXT = 0; END ELSE PostItemCharge(SalesLine, ReturnRcptLine."Item Rcpt. Entry No.",ReturnRcptLine."Quantity (Base)", ...取代程式碼 2
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(SalesLine, TempItemLedgEntry."Entry No.",ABS(TempItemLedgEntry.Quantity), // Add the following lines. NonDistrAmountToAssign,NonDistrQtyToAssign,TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. UNTIL TempItemLedgEntry.NEXT = 0; END ELSE PostItemCharge(SalesLine, ReturnRcptLine."Item Rcpt. Entry No.",ReturnRcptLine."Quantity (Base)", ...現有的程式碼 3
...END ELSE
PostItemCharge(SalesLine, ReturnRcptLine."Item Rcpt. Entry No.",ReturnRcptLine."Quantity (Base)", TempItemChargeAssgntSales."Amount to Assign", // Delete the following line. TempItemChargeAssgntSales."Qty. to Assign") END; LOCAL PROCEDURE PostAssocItemJnlLine@3(QtyToBeShipped@1000 : Decimal;QtyToBeShippedBase@1001 : Decimal) : Integer; VAR ...取代程式碼 3
...END ELSE
PostItemCharge(SalesLine, ReturnRcptLine."Item Rcpt. Entry No.",ReturnRcptLine."Quantity (Base)", TempItemChargeAssgntSales."Amount to Assign", // Add the following lines. TempItemChargeAssgntSales."Qty. to Assign",TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining) // End of the added lines. END; LOCAL PROCEDURE PostAssocItemJnlLine@3(QtyToBeShipped@1000 : Decimal;QtyToBeShippedBase@1001 : Decimal) : Integer; VAR ... -
變更銷售張貼 codeunit (80) 的PostItemCharge函式中的程式碼如下所示︰
現有的程式碼 1...TempValueEntryRelation.DELETEALL;
END; END; // Delete the following line. PROCEDURE PostItemCharge@42(SalesLine@1005 : Record 37;ItemEntryNo@1004 : Integer;QuantityBase@1003 : Decimal;AmountToAssign@1002 : Decimal;QtyToAssign@1001 : Decimal); VAR DummyTrackingSpecification@1000 : Record 336; BEGIN WITH TempItemChargeAssgntSales DO BEGIN ...取代程式碼 1
...TempValueEntryRelation.DELETEALL;
END; END; // Add the following line. PROCEDURE PostItemCharge@42(SalesLine@1005 : Record 37;ItemEntryNo@1004 : Integer;QuantityBase@1003 : Decimal;AmountToAssign@1002 : Decimal;QtyToAssign@1001 : Decimal;VAR TotalInvDiscAmtRemaining@1006 : Decimal;VAR TotalQtyRemaining@1007 : Decimal;VAR TotalLineDiscAmtRemaining@1008 : Decimal;VAR TotalLineAmtRemaining@1009 : Decimal); VAR DummyTrackingSpecification@1000 : Record 336; BEGIN WITH TempItemChargeAssgntSales DO BEGIN ...現有的程式碼 2
...SalesLine.Amount :=
CurrExchRate.ExchangeAmtFCYToLCY( UseDate,SalesHeader."Currency Code",TotalChargeAmt,SalesHeader."Currency Factor"); SalesLine."Inv. Discount Amount" := ROUND( // Delete the following lines. SalesLine."Inv. Discount Amount" / SalesLine.Quantity * QtyToAssign, GLSetup."Amount Rounding Precision"); // End of the deleted lines. SalesLine.Amount := ROUND(SalesLine.Amount,GLSetup."Amount Rounding Precision") - TotalChargeAmtLCY; IF SalesHeader."Currency Code" <> '' THEN TotalChargeAmtLCY := TotalChargeAmtLCY + SalesLine.Amount; SalesLine."Unit Cost (LCY)" := ROUND( ...取代程式碼 2
...SalesLine.Amount :=
CurrExchRate.ExchangeAmtFCYToLCY( UseDate,SalesHeader."Currency Code",TotalChargeAmt,SalesHeader."Currency Factor"); SalesLine."Inv. Discount Amount" := ROUND( // Add the following lines. TotalInvDiscAmtRemaining / TotalQtyRemaining * QtyToAssign, GLSetup."Amount Rounding Precision"); SalesLine."Line Discount Amount" := ROUND( TotalLineDiscAmtRemaining / TotalQtyRemaining * QtyToAssign, GLSetup."Amount Rounding Precision"); SalesLine."Line Amount" := ROUND( TotalLineAmtRemaining / TotalQtyRemaining * QtyToAssign, GLSetup."Amount Rounding Precision"); TotalInvDiscAmtRemaining := TotalInvDiscAmtRemaining - SalesLine."Inv. Discount Amount"; TotalLineDiscAmtRemaining := TotalLineDiscAmtRemaining - SalesLine."Line Discount Amount"; TotalLineAmtRemaining := TotalLineAmtRemaining - SalesLine."Line Amount"; TotalQtyRemaining := TotalQtyRemaining - QtyToAssign; // End of the added lines. SalesLine.Amount := ROUND(SalesLine.Amount,GLSetup."Amount Rounding Precision") - TotalChargeAmtLCY; IF SalesHeader."Currency Code" <> '' THEN TotalChargeAmtLCY := TotalChargeAmtLCY + SalesLine.Amount; SalesLine."Unit Cost (LCY)" := ROUND( ... -
變更中屬性的程式碼,在 thePurch-張貼 codeunit (90),如下所示︰
現有的程式碼 1...3:
ERROR(Text015); PurchLine.Type::"Charge (Item)": IF Invoice OR ItemChargeAssgntOnly THEN BEGIN // Delete the following line. ItemJnlRollRndg := FALSE; ClearItemChargeAssgntFilter; TempItemChargeAssgntPurch.SETCURRENTKEY("Applies-to Doc. Type"); TempItemChargeAssgntPurch.SETRANGE("Document Line No.",PurchLine."Line No."); IF TempItemChargeAssgntPurch.FINDSET THEN ...取代程式碼 1
...3:
ERROR(Text015); PurchLine.Type::"Charge (Item)": IF Invoice OR ItemChargeAssgntOnly THEN BEGIN // Add the following line. ItemJnlRollRndg := TRUE; ClearItemChargeAssgntFilter; TempItemChargeAssgntPurch.SETCURRENTKEY("Applies-to Doc. Type"); TempItemChargeAssgntPurch.SETRANGE("Document Line No.",PurchLine."Line No."); IF TempItemChargeAssgntPurch.FINDSET THEN ...現有的程式碼 2
...GenJnlLineDocNo := TempItemChargeAssgntPurch."Applies-to Doc. No.";
CASE TempItemChargeAssgntPurch."Applies-to Doc. Type" OF TempItemChargeAssgntPurch."Applies-to Doc. Type"::Receipt: BEGIN // Delete the following line. PostItemChargePerRcpt(PurchLine); TempItemChargeAssgntPurch.MARK(TRUE); END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Transfer Receipt": BEGIN ...取代程式碼 2
...GenJnlLineDocNo := TempItemChargeAssgntPurch."Applies-to Doc. No.";
CASE TempItemChargeAssgntPurch."Applies-to Doc. Type" OF TempItemChargeAssgntPurch."Applies-to Doc. Type"::Receipt: BEGIN // Add the following lines. PostItemChargePerRcpt(PurchLine,PurchLine."Inv. Discount Amount", PurchLine.Quantity,PurchLine."Line Discount Amount",PurchLine."Line Amount"); // End of the added lines. TempItemChargeAssgntPurch.MARK(TRUE); END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Transfer Receipt": BEGIN ...現有的程式碼 3
...TempItemChargeAssgntPurch.MARK(TRUE);
END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Transfer Receipt": BEGIN // Delete the following line. PostItemChargePerTransfer(PurchLine); TempItemChargeAssgntPurch.MARK(TRUE); END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Return Shipment": BEGIN ...取代程式碼 3
...TempItemChargeAssgntPurch.MARK(TRUE);
END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Transfer Receipt": BEGIN // Add the following lines. PostItemChargePerTransfer(PurchLine,PurchLine."Inv. Discount Amount", PurchLine.Quantity,PurchLine."Line Discount Amount",PurchLine."Line Amount"); // End of the added lines. TempItemChargeAssgntPurch.MARK(TRUE); END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Return Shipment": BEGIN ...現有的程式碼 4
...TempItemChargeAssgntPurch.MARK(TRUE);
END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Return Shipment": BEGIN // Delete the following line. PostItemChargePerRetShpt(PurchLine); TempItemChargeAssgntPurch.MARK(TRUE); END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Sales Shipment": BEGIN ...取代程式碼 4
...TempItemChargeAssgntPurch.MARK(TRUE);
END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Return Shipment": BEGIN // Add the following lines. PostItemChargePerRetShpt(PurchLine,PurchLine."Inv. Discount Amount", PurchLine.Quantity,PurchLine."Line Discount Amount",PurchLine."Line Amount"); // End of the added lines. TempItemChargeAssgntPurch.MARK(TRUE); END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Sales Shipment": BEGIN ...現有的程式碼 5
...TempItemChargeAssgntPurch.MARK(TRUE);
END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Sales Shipment": BEGIN // Delete the following line. PostItemChargePerSalesShpt(PurchLine); TempItemChargeAssgntPurch.MARK(TRUE); END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Return Receipt": BEGIN ...取代程式碼 5
...TempItemChargeAssgntPurch.MARK(TRUE);
END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Sales Shipment": BEGIN // Add the following lines. PostItemChargePerSalesShpt(PurchLine,PurchLine."Inv. Discount Amount", PurchLine.Quantity,PurchLine."Line Discount Amount",PurchLine."Line Amount"); // End of the added lines. TempItemChargeAssgntPurch.MARK(TRUE); END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Return Receipt": BEGIN ...現有的程式碼 6
...TempItemChargeAssgntPurch.MARK(TRUE);
END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Return Receipt": BEGIN // Delete the following line. PostItemChargePerRetRcpt(PurchLine); TempItemChargeAssgntPurch.MARK(TRUE); END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::Order, TempItemChargeAssgntPurch."Applies-to Doc. Type"::Invoice: ...取代程式碼 6
...TempItemChargeAssgntPurch.MARK(TRUE);
END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::"Return Receipt": BEGIN // Add the following lines. PostItemChargePerRetRcpt(PurchLine,PurchLine."Inv. Discount Amount", PurchLine.Quantity,PurchLine."Line Discount Amount",PurchLine."Line Amount"); // End of the added lines. TempItemChargeAssgntPurch.MARK(TRUE); END; TempItemChargeAssgntPurch."Applies-to Doc. Type"::Order, TempItemChargeAssgntPurch."Applies-to Doc. Type"::Invoice: ... -
變更在 thePurch 的PostItemChargePerRcpt函式中的程式碼-張貼 codeunit (90),如下所示︰
現有的程式碼 1...END;
END; END; // Delete the following line. LOCAL PROCEDURE PostItemChargePerRcpt@5807(PurchLine@1000 : Record 39); VAR PurchRcptLine@1002 : Record 121; TempItemLedgEntry@1003 : TEMPORARY Record 32; ItemTrackingMgt@1005 : Codeunit 6500; ...取代程式碼 1
...END;
END; END; // Add the following line. LOCAL PROCEDURE PostItemChargePerRcpt@5807(PurchLine@1000 : Record 39;VAR TotalInvDiscAmtRemaining@1012 : Decimal;VAR TotalQtyRemaining@1013 : Decimal;VAR TotalLineDiscAmtRemaining@1014 : Decimal;VAR TotalLineAmtRemaining@1015 : Decimal); VAR PurchRcptLine@1002 : Record 121; TempItemLedgEntry@1003 : TEMPORARY Record 32; ItemTrackingMgt@1005 : Codeunit 6500; ...現有的程式碼 2
...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Delete the following line. AmountToAssign * Sign,QtyToAssign,PurchRcptLine."Indirect Cost %"); NonDistrQuantity := NonDistrQuantity - TempItemLedgEntry.Quantity; NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...取代程式碼 2
...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Add the following lines. AmountToAssign * Sign,QtyToAssign,PurchRcptLine."Indirect Cost %", TotalInvDiscAmtRemaining,TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. NonDistrQuantity := NonDistrQuantity - TempItemLedgEntry.Quantity; NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...現有的程式碼 3
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Delete the following line. NonDistrAmountToAssign * Sign,NonDistrQtyToAssign,PurchRcptLine."Indirect Cost %"); UNTIL TempItemLedgEntry.NEXT = 0; END ELSE ERROR(Text042) ELSE ...取代程式碼 3
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Add the following lines. NonDistrAmountToAssign * Sign,NonDistrQtyToAssign,PurchRcptLine."Indirect Cost %", TotalInvDiscAmtRemaining,TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. UNTIL TempItemLedgEntry.NEXT = 0; END ELSE ERROR(Text042) ELSE ...現有的程式碼 4
...PostItemCharge(PurchLine,
PurchRcptLine."Item Rcpt. Entry No.",PurchRcptLine."Quantity (Base)", TempItemChargeAssgntPurch."Amount to Assign" * Sign, TempItemChargeAssgntPurch."Qty. to Assign", // Delete the following lines. PurchRcptLine."Indirect Cost %"); END; LOCAL PROCEDURE PostItemChargePerRetShpt@5811(PurchLine@1000 : Record 39); // End of the deleted lines. VAR ReturnShptLine@1002 : Record 6651; TempItemLedgEntry@1010 : TEMPORARY Record 32; ItemTrackingMgt@1009 : Codeunit 6500; ...取代程式碼 4
...PostItemCharge(PurchLine,
PurchRcptLine."Item Rcpt. Entry No.",PurchRcptLine."Quantity (Base)", TempItemChargeAssgntPurch."Amount to Assign" * Sign, TempItemChargeAssgntPurch."Qty. to Assign", // Add the following lines. PurchRcptLine."Indirect Cost %",TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); END; LOCAL PROCEDURE PostItemChargePerRetShpt@5811(PurchLine@1000 : Record 39;VAR TotalInvDiscAmtRemaining@1012 : Decimal;VAR TotalQtyRemaining@1013 : Decimal;VAR TotalLineDiscAmtRemaining@1014 : Decimal;VAR TotalLineAmtRemaining@1015 : Decimal); // End of the added lines. VAR ReturnShptLine@1002 : Record 6651; TempItemLedgEntry@1010 : TEMPORARY Record 32; ItemTrackingMgt@1009 : Codeunit 6500; ... -
變更在 thePurch 的PostItemChargePerRetShpt函式中的程式碼-張貼 codeunit (90),如下所示︰
現有的程式碼 1...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Delete the following line. AmountToAssign * Sign,QtyToAssign,ReturnShptLine."Indirect Cost %"); NonDistrQuantity := NonDistrQuantity - TempItemLedgEntry.Quantity; NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...取代程式碼 1
...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Add the following lines. AmountToAssign * Sign,QtyToAssign,ReturnShptLine."Indirect Cost %",TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. NonDistrQuantity := NonDistrQuantity - TempItemLedgEntry.Quantity; NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...現有的程式碼 2
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Delete the following line. NonDistrAmountToAssign * Sign,NonDistrQtyToAssign,ReturnShptLine."Indirect Cost %"); UNTIL TempItemLedgEntry.NEXT = 0; END ELSE ERROR(Text042) ELSE ...取代程式碼 2
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Add the following lines. NonDistrAmountToAssign * Sign,NonDistrQtyToAssign,ReturnShptLine."Indirect Cost %",TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. UNTIL TempItemLedgEntry.NEXT = 0; END ELSE ERROR(Text042) ELSE ...現有的程式碼 3
...PostItemCharge(PurchLine,
ReturnShptLine."Item Shpt. Entry No.",-ReturnShptLine."Quantity (Base)", ABS(TempItemChargeAssgntPurch."Amount to Assign") * Sign, TempItemChargeAssgntPurch."Qty. to Assign", // Delete the following lines. ReturnShptLine."Indirect Cost %"); END; LOCAL PROCEDURE PostItemChargePerTransfer@23(PurchLine@1000 : Record 39); // End of the deleted lines. VAR TransRcptLine@1002 : Record 5747; ItemApplnEntry@1003 : Record 339; DummyTrackingSpecification@1001 : Record 336; ...取代程式碼 3
...PostItemCharge(PurchLine,
ReturnShptLine."Item Shpt. Entry No.",-ReturnShptLine."Quantity (Base)", ABS(TempItemChargeAssgntPurch."Amount to Assign") * Sign, TempItemChargeAssgntPurch."Qty. to Assign", // Add the following lines. ReturnShptLine."Indirect Cost %",TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); END; LOCAL PROCEDURE PostItemChargePerTransfer@23(PurchLine@1000 : Record 39;VAR TotalInvDiscAmtRemaining@1016 : Decimal;VAR TotalQtyRemaining@1017 : Decimal;VAR TotalLineDiscAmtRemaining@1018 : Decimal;VAR TotalLineAmtRemaining@1019 : Decimal); // End of the added lines. VAR TransRcptLine@1002 : Record 5747; ItemApplnEntry@1003 : Record 339; DummyTrackingSpecification@1001 : Record 336; ... -
變更在 thePurch 的PostItemChargePerTransfer函式中的程式碼-張貼 codeunit (90),如下所示
現有的程式碼...PurchLine."Bin Code" := '';
PurchLine."Line No." := "Document Line No."; IF TransRcptLine."Item Rcpt. Entry No." = 0 THEN // Delete the following line. PostItemChargePerITTransfer(PurchLine,TransRcptLine) ELSE BEGIN TotalAmountToPostFCY := "Amount to Assign"; IF PurchHeader."Currency Code" <> '' THEN TotalAmountToPostLCY := ...取代程式碼
...PurchLine."Bin Code" := '';
PurchLine."Line No." := "Document Line No."; IF TransRcptLine."Item Rcpt. Entry No." = 0 THEN // Add the following lines. PostItemChargePerITTransfer(PurchLine,TransRcptLine,TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining) // End of the added lines. ELSE BEGIN TotalAmountToPostFCY := "Amount to Assign"; IF PurchHeader."Currency Code" <> '' THEN TotalAmountToPostLCY := ... -
變更在 thePurch 的PostItemChargePerITTransfer函式中的程式碼-張貼 codeunit (90),如下所示︰
現有的程式碼 1...END;
END; END; // Delete the following line. LOCAL PROCEDURE PostItemChargePerITTransfer@43(PurchLine@1000 : Record 39;TransRcptLine@1017 : Record 5747); VAR TempItemLedgEntry@1016 : TEMPORARY Record 32; ItemTrackingMgt@1001 : Codeunit 6500; Factor@1023 : Decimal; ...取代程式碼 1
...END;
END; END; // Add the following line. LOCAL PROCEDURE PostItemChargePerITTransfer@43(PurchLine@1000 : Record 39;TransRcptLine@1017 : Record 5747;VAR TotalInvDiscAmtRemaining@1026 : Decimal;VAR TotalQtyRemaining@1024 : Decimal;VAR TotalLineDiscAmtRemaining@1025 : Decimal;VAR TotalLineAmtRemaining@1030 : Decimal); VAR TempItemLedgEntry@1016 : TEMPORARY Record 32; ItemTrackingMgt@1001 : Codeunit 6500; Factor@1023 : Decimal; ...現有的程式碼 2
...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Delete the following line. AmountToAssign,QtyToAssign,0); NonDistrQuantity := NonDistrQuantity - TempItemLedgEntry.Quantity; NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...取代程式碼 2
...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Add the following lines. AmountToAssign,QtyToAssign,0,TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. NonDistrQuantity := NonDistrQuantity - TempItemLedgEntry.Quantity; NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...現有的程式碼 3
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Delete the following line. NonDistrAmountToAssign,NonDistrQtyToAssign,0); UNTIL TempItemLedgEntry.NEXT = 0; END ELSE ERROR(Text042); END; ...取代程式碼 3
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Add the following lines. NonDistrAmountToAssign,NonDistrQtyToAssign,0,TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. UNTIL TempItemLedgEntry.NEXT = 0; END ELSE ERROR(Text042); END; ... -
變更在 thePurch 的PostItemChargePerSalesShpt函式中的程式碼-張貼 codeunit (90),如下所示︰
現有的程式碼 1...ERROR(Text042);
END; END; // Delete the following line. LOCAL PROCEDURE PostItemChargePerSalesShpt@41(PurchLine@1000 : Record 39); VAR SalesShptLine@1002 : Record 111; TempItemLedgEntry@1010 : TEMPORARY Record 32; ItemTrackingMgt@1009 : Codeunit 6500; ...取代程式碼 1
...ERROR(Text042);
END; END; // Add the following line. LOCAL PROCEDURE PostItemChargePerSalesShpt@41(PurchLine@1000 : Record 39;VAR TotalInvDiscAmtRemaining@1012 : Decimal;VAR TotalQtyRemaining@1013 : Decimal;VAR TotalLineDiscAmtRemaining@1014 : Decimal;VAR TotalLineAmtRemaining@1015 : Decimal); VAR SalesShptLine@1002 : Record 111; TempItemLedgEntry@1010 : TEMPORARY Record 32; ItemTrackingMgt@1009 : Codeunit 6500; ...現有的程式碼 2
...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Delete the following line. AmountToAssign * Sign,QtyToAssign,0); NonDistrQuantity := NonDistrQuantity - TempItemLedgEntry.Quantity; NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...取代程式碼 2
...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Add the following lines. AmountToAssign * Sign,QtyToAssign,0,TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. NonDistrQuantity := NonDistrQuantity - TempItemLedgEntry.Quantity; NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...現有的程式碼 3
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Delete the following line. NonDistrAmountToAssign * Sign,NonDistrQtyToAssign,0); UNTIL TempItemLedgEntry.NEXT = 0; END ELSE ERROR(Text042) ELSE ...取代程式碼 3
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Add the following lines. NonDistrAmountToAssign * Sign,NonDistrQtyToAssign,0,TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. UNTIL TempItemLedgEntry.NEXT = 0; END ELSE ERROR(Text042) ELSE ...現有的程式碼 4
...ELSE
PostItemCharge(PurchLine, SalesShptLine."Item Shpt. Entry No.",-SalesShptLine."Quantity (Base)", TempItemChargeAssgntPurch."Amount to Assign" * Sign, // Delete the following lines. TempItemChargeAssgntPurch."Qty. to Assign",0) END; PROCEDURE PostItemChargePerRetRcpt@37(PurchLine@1001 : Record 39); // End of the deleted lines. VAR ReturnRcptLine@1000 : Record 6661; TempItemLedgEntry@1011 : TEMPORARY Record 32; ItemTrackingMgt@1010 : Codeunit 6500; ...取代程式碼 4
...ELSE
PostItemCharge(PurchLine, SalesShptLine."Item Shpt. Entry No.",-SalesShptLine."Quantity (Base)", TempItemChargeAssgntPurch."Amount to Assign" * Sign, // Add the following lines. TempItemChargeAssgntPurch."Qty. to Assign",0,TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining) END; PROCEDURE PostItemChargePerRetRcpt@37(PurchLine@1001 : Record 39;VAR TotalInvDiscAmtRemaining@1012 : Decimal;VAR TotalQtyRemaining@1013 : Decimal;VAR TotalLineDiscAmtRemaining@1014 : Decimal;VAR TotalLineAmtRemaining@1015 : Decimal); // End of the added lines. VAR ReturnRcptLine@1000 : Record 6661; TempItemLedgEntry@1011 : TEMPORARY Record 32; ItemTrackingMgt@1010 : Codeunit 6500; ... -
變更在 thePurch 的PostItemChargePerRetRcpt函式中的程式碼-張貼 codeunit (90),如下所示︰
現有的程式碼 1...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Delete the following line. AmountToAssign * Sign,QtyToAssign,0); NonDistrQuantity := NonDistrQuantity - TempItemLedgEntry.Quantity; NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...取代程式碼 1
...AmountToAssign := ROUND(NonDistrAmountToAssign * Factor,GLSetup."Amount Rounding Precision");
IF Factor < 1 THEN BEGIN PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Add the following lines. AmountToAssign * Sign,QtyToAssign,0,TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. NonDistrQuantity := NonDistrQuantity - TempItemLedgEntry.Quantity; NonDistrQtyToAssign := NonDistrQtyToAssign - QtyToAssign; NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign; END ELSE // the last time ...現有的程式碼 2
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Delete the following line. NonDistrAmountToAssign * Sign,NonDistrQtyToAssign,0); UNTIL TempItemLedgEntry.NEXT = 0; END ELSE ERROR(Text042) ELSE ...取代程式碼 2
...NonDistrAmountToAssign := NonDistrAmountToAssign - AmountToAssign;
END ELSE // the last time PostItemCharge(PurchLine, TempItemLedgEntry."Entry No.",TempItemLedgEntry.Quantity, // Add the following lines. NonDistrAmountToAssign * Sign,NonDistrQtyToAssign,0,TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining); // End of the added lines. UNTIL TempItemLedgEntry.NEXT = 0; END ELSE ERROR(Text042) ELSE ...現有的程式碼 3
...ELSE
PostItemCharge(PurchLine, ReturnRcptLine."Item Rcpt. Entry No.",ReturnRcptLine."Quantity (Base)", TempItemChargeAssgntPurch."Amount to Assign" * Sign, // Delete the following line. TempItemChargeAssgntPurch."Qty. to Assign",0) END; LOCAL PROCEDURE PostAssocItemJnlLine@3(QtyToBeShipped@1000 : Decimal;QtyToBeShippedBase@1001 : Decimal) : Integer; VAR ...取代程式碼 3
...ELSE
PostItemCharge(PurchLine, ReturnRcptLine."Item Rcpt. Entry No.",ReturnRcptLine."Quantity (Base)", TempItemChargeAssgntPurch."Amount to Assign" * Sign, // Add the following lines. TempItemChargeAssgntPurch."Qty. to Assign",0,TotalInvDiscAmtRemaining, TotalQtyRemaining,TotalLineDiscAmtRemaining,TotalLineAmtRemaining) // End of the added lines. END; LOCAL PROCEDURE PostAssocItemJnlLine@3(QtyToBeShipped@1000 : Decimal;QtyToBeShippedBase@1001 : Decimal) : Integer; VAR ... -
變更在 thePurch 的PostItemCharge函式中的程式碼-張貼 codeunit (90),如下所示︰
現有的程式碼 1...TempValueEntryRelation.DELETEALL;
END; END; // Delete the following line. LOCAL PROCEDURE PostItemCharge@42(PurchLine@1000 : Record 39;ItemEntryNo@1004 : Integer;QuantityBase@1005 : Decimal;AmountToAssign@1006 : Decimal;QtyToAssign@1007 : Decimal;IndirectCostPct@1008 : Decimal); VAR DummyTrackingSpecification@1001 : Record 336; BEGIN WITH TempItemChargeAssgntPurch DO BEGIN ...取代程式碼 1
...TempValueEntryRelation.DELETEALL;
END; END; // Add the following line. LOCAL PROCEDURE PostItemCharge@42(PurchLine@1000 : Record 39;ItemEntryNo@1004 : Integer;QuantityBase@1005 : Decimal;AmountToAssign@1006 : Decimal;QtyToAssign@1007 : Decimal;IndirectCostPct@1008 : Decimal;VAR TotalInvDiscAmtRemaining@1009 : Decimal;VAR TotalQtyRemaining@1010 : Decimal;VAR TotalLineDiscAmtRemaining@1011 : Decimal;VAR TotalLineAmtRemaining@1012 : Decimal); VAR DummyTrackingSpecification@1001 : Record 336; BEGIN WITH TempItemChargeAssgntPurch DO BEGIN ...現有的程式碼 2
...ROUND(
PurchLine.Amount / QuantityBase,GLSetup."Unit-Amount Rounding Precision"); PurchLine."Inv. Discount Amount" := ROUND( // Delete the following lines. PurchLine."Inv. Discount Amount" / PurchLine.Quantity * QtyToAssign, GLSetup."Amount Rounding Precision"); PurchLine."Line Discount Amount" := ROUND( PurchLine."Line Discount Amount" / PurchLine.Quantity * QtyToAssign, GLSetup."Amount Rounding Precision"); // End of the deleted lines. PostItemJnlLine( PurchLine, 0,0, QuantityBase,QuantityBase, ...取代程式碼 2
...ROUND(
PurchLine.Amount / QuantityBase,GLSetup."Unit-Amount Rounding Precision"); PurchLine."Inv. Discount Amount" := ROUND( // Add the following lines. TotalInvDiscAmtRemaining / TotalQtyRemaining * QtyToAssign, GLSetup."Amount Rounding Precision"); PurchLine."Line Discount Amount" := ROUND( TotalLineDiscAmtRemaining / TotalQtyRemaining * QtyToAssign, GLSetup."Amount Rounding Precision"); PurchLine."Line Amount" := ROUND( TotalLineAmtRemaining / TotalQtyRemaining * QtyToAssign, GLSetup."Amount Rounding Precision"); TotalInvDiscAmtRemaining := TotalInvDiscAmtRemaining - PurchLine."Inv. Discount Amount"; TotalLineDiscAmtRemaining := TotalLineDiscAmtRemaining - PurchLine."Line Discount Amount"; TotalLineAmtRemaining := TotalLineAmtRemaining - PurchLine."Line Amount"; TotalQtyRemaining := TotalQtyRemaining - QtyToAssign; // End of the added lines. PostItemJnlLine( PurchLine, 0,0, QuantityBase,QuantityBase, ...
先決條件
您必須具備套用此 hotfix 之後安裝下列產品的其中一個︰
-
Microsoft 動態航行點 2009 R2
-
Microsoft 動態航行點 2009 SP1
移除資訊
您無法移除此 hotfix。
狀態
Microsoft 已確認這是<套用>一節所列出的 Microsoft 產品的問題。
注意這是直接從 Microsoft 支援組織內建立的「快速發行」文件。本文件所包含的現狀資訊是針對新興問題的回應。為縮短使其可用的時程,資料可能會包含印刷錯誤,且可能會隨時進行修改而不另行通知。如其他考量,請參閱 「使用規定」。