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

Rounding Quantity based on UoM for various doctypes #41476

Open
aceIsHere opened this issue May 15, 2024 · 0 comments
Open

Rounding Quantity based on UoM for various doctypes #41476

aceIsHere opened this issue May 15, 2024 · 0 comments

Comments

@aceIsHere
Copy link

Information about bug

Referencing #15995,

If the UoM has "is whole number" checked, currently, the system just triggers a warning to the user and disallows them from entering fraction values.

A new setting is to be added in stock setting which would automatically round-off the Quantity to the nearest whole number (next bigger or smaller) according to the setting.

The issue was closed without referencing any PR update. I have raised this as a bug due to the ambiguity regarding its current status—whether it is completed (and therefore a bug for my system setup) or involved in other indirect developments. If needed, please update the tag accordingly.

There is indeed a rounding feature available, but it is limited to accounts and sales, specifically banking and commercial rounding. However, I could not find any such feature for the Manufacturing and Stock modules. I thoroughly checked the ERPNext documentation, forums, GitHub Issues page, and other discussions about ERPNext on the internet.

I also looked within ERPNext itself, exploring the settings of each module, system settings, and almost every doctype in their accompanying child tables.

The Requirement:

The ability to round up or round down (as necessary) the quantities, especially those mentioned in numbers (e.g., packaging items).

Proposed Workflow:

  1. A Bill of Materials (BOM) [Formulation/Recipe] is created beforehand.
  2. A Sales Order is raised.
  3. A Work Order is generated in conjunction with the Sales Order and associated BOM for the items mentioned in the BOM.

While floating numbers for kilograms are required, using floating numbers for items in numbers causes unnecessary confusion. Subsequent processes, like Pick Lists, Material Requests, and Stock Entries, perpetuate this confusion and do not accept the values as expected. This requires manual modifications, introducing the potential for human error.

Meanwhile, as a temporary solution, I have started customizing the form to add another field labeled "Estimated Required Quantity" with an integer datatype, as opposed to the system default "Required Quantity" which has a float datatype. Should I continue down this path, or should I consider server/client scripting instead?
Also, if possible I would be grateful if you share an idea to achieve the requirement.

Module

stock, manufacturing

Version

ERPNext: v15.21.2 (version-15)
Frappe Framework: v15.24.1 (version-15)
Frappe HR: v15.20.0 (version-15)

Installation method

manual install

Relevant log output / Stack trace / Full Error Message.

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants