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

Create shipment rounds decimal values up or down, instead of maintaining decimal points #32453

Closed
bosss7 opened this issue Dec 23, 2024 · 1 comment
Labels
Bug This is a bug (something does not work as expected)

Comments

@bosss7
Copy link

bosss7 commented Dec 23, 2024

Bug

If a shipment is created where the quantity contains a decimal point (eg 18.55), after creating the shipment, the quantity is rounded up or rounded down to a whole number.

As of version 19.0.2, this decimal value would be retained but as of 20.0.2, it is not.

This can be fixed by editing the value after creation, after which the decimal point is maintained.

Dolibarr Version

20.0.2

Environment PHP

8.1.2

Environment Database

MYSQL 8.1.2

Steps to reproduce the behavior and expected behavior

Create a shipment and enter a quantity containing a decimal point in "Qty to ship" (eg 18.22) and click Create
Step 1

The value is then rounded down to 18
Step 2

To correct this, we need to edit the shipment back to 18.22 and save.
Step 3

The value is then retained.
Step 4

The value should not be rounded up or down as we ship our products as square meters.

This was not an issue with 19.0.2

Attached files

No response

@bosss7 bosss7 added the Bug This is a bug (something does not work as expected) label Dec 23, 2024
@bosss7 bosss7 changed the title Create shipment rounds up values instead of maintaining decimal points Create shipment rounds decimal values up or down, instead of maintaining decimal points Dec 23, 2024
@bosss7
Copy link
Author

bosss7 commented Dec 23, 2024

Apologies, it looks like this has already been addressed in the following fix:

#31967

@bosss7 bosss7 closed this as completed Dec 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug This is a bug (something does not work as expected)
Projects
None yet
Development

No branches or pull requests

1 participant