Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BOM Item price not fetched unless UOM matches Item Price UOM #44298

Open
mepoland opened this issue Nov 22, 2024 · 0 comments
Open

BOM Item price not fetched unless UOM matches Item Price UOM #44298

mepoland opened this issue Nov 22, 2024 · 0 comments
Labels

Comments

@mepoland
Copy link

Information about bug

ERPNext will not fetch a price/rate for an Item added to a BOM unless the UOM entered in the Item Price matches the UOM entered for the BOM Item. This happens even when you have:

  • BOM "Rate Of Materials Based On" = Price List
  • The selected Price List option "Price not UOM Dependent" set to True
  • A UOM Conversion Factor establishing the relationship between the two UOMs concerned
  • No other Item Price constraints set that would prevent the fetching of the price (date valid from, etc)

Consider the documentation for Price List settings:

Price Not UOM Dependent: Consider an item, Tomatoes which you buy in Boxes and sell in Kilos. 1 Box = 10 Kilos and 1 Kilo buying price is 10rs. If this Box is unchecked and you select 1 Box in your transaction, the price will show up only for a Kilo since that's the only Item Price saved.
Now, if you tick this checkbox and make a transaction with a Box of Tomatoes, then the price will be automatically set as 100 since the price of 1 Box (10 Kilos) is 100. * Standard Buying and Selling Price Lists are created by default.

While the documentation does not specifically cover the case of adding items to a BOM, it implies that the "not dependent" setting would apply to any time erpnext tries to fetch the price for an Item. So I think the current behavior is a bug, but maybe some would consider it a feature request. Either way it's caused plenty of headaches.

See https://discuss.frappe.io/t/bom-price-calculation-per-used-uom-conversion-not-working/66183

Example:

  • Let’s say you typically buy a part in units “Pack of 5”, so you create an Item Price using that UOM. In the Price List settings you’ve checked “Price not UOM dependent.”
  • You’ve set up a UOM Conversion Factor to establish one Pack of 5 = five Pcs.
  • Then you add the item to a BOM and specify the quantity in Pcs.
  • If the BOM valuation method is set to “Price list”, you’ll find it fails to fetch a price for the item. If you change the BOM Item UOM to match your Item Price though, it does fetch the price.

Why is this annoying / why not just pick one UOM or the other?

  • Requires manual conversion of qty or price by the user, either when entering Item Price or BOM Item qty
  • Sometimes there's an order of magnitude difference between units; like you buy something by the kilo and use it by the gram. This can force you to use very high precision / decimal places in your prices; it is better if you can rely on the nice existing UOM conversion feature to avoid rounding errors.
  • The same-UOM requirement is counter intuitive and frustrating to those who've not figured out this workaround (or who figured it out but forget how it works in the 6 months intervening between each time they run into it).

Module

manufacturing

Version

ERPNext: v15.43.0
Frappe Framework: v15.48.0

Installation method

docker

Relevant log output / Stack trace / Full Error Message.

No response

@mepoland mepoland added the bug label Nov 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant