Total Incoming Value Not Updated When Using Additional Costs with Zero Valuation Rate in Stock Entry

Issue Statement:
Total Incoming Value Not Updated When Using Additional Costs with Zero Valuation Rate in Stock Entry


Issue Detailed Description:
I created a Stock Entry (Material Receipt) transaction in ERPNext with the “Allow Zero Valuation Rate” option enabled. The items in the Item table were entered with a valuation rate of 0.

I then added Additional Costs totaling IDR 60 USD in the Additional Costs section. However, the Total Incoming Value (Receipt) field does not update to reflect these additional costs.

The system only updates the Total Incoming Value if a valuation rate is manually entered in the Item table. This behavior prevents proper capitalization of additional costs when using zero valuation items, which is a common scenario in certain operational workflows.


Steps to Replicate the Issue:

  1. Create a new Stock Entry with type Material Receipt.

  2. Add one or more items in the Item table with valuation rate = 0.

  3. Enable the checkbox “Allow Zero Valuation Rate”.

  4. Add a value in the Additional Costs section (e.g., IDR 60 USD).

  5. Save or submit the document.

  6. Check the Total Incoming Value (Receipt) field.


Current Behavior:

  • Total Incoming Value remains 0 despite having Additional Costs.

  • Additional Costs are not reflected in the total valuation.

  • Total Incoming Value only updates if a valuation rate is entered in the Item table.


Expected Behavior:

  • Total Incoming Value should reflect Additional Costs, even if item valuation rate is 0.

  • The system should allow capitalization of costs purely from Additional Costs when “Allow Zero Valuation Rate” is enabled.

  • Additional Costs should be distributed to item valuation and included in Total Incoming Value automatically.


Supporting Screenshots / Documents / Videos / Dashboard Links:

Installed Apps

Frappe Framework: v16.14.0 (HEAD)

ERPNext: v16.13.1 (HEAD)

Frappe HR: v16.4.8 (HEAD)

Insights: v3.6.0 (HEAD)

Wiki: v2.0.0 (HEAD)