web icon indicating copy to clipboard operation
web copied to clipboard

[12.0][FIX] web_widget_one2many_product_picker: Decimal precision

Open Tardo opened this issue 4 years ago • 10 comments

cc @tecnativa TT28298

Tardo avatar Feb 18 '21 20:02 Tardo

I insist: can we avoid to retrieve all the currencies rounding. I guess the proper data should be around already thanks to monetary widget.

pedrobaeza avatar Feb 19 '21 22:02 pedrobaeza

Know the rounding value is necessary when the widget calculates the subtotal using the discount... we lost the server side rounding.

Tardo avatar Feb 22 '21 10:02 Tardo

But how the monetary widget does it? I don't think that's a server operation.

pedrobaeza avatar Feb 22 '21 10:02 pedrobaeza

@pedrobaeza For example here, Monetary rounds the value to use in the SQL: https://github.com/odoo/odoo/blob/12.0/odoo/fields.py#L1411

Tardo avatar Feb 22 '21 16:02 Tardo

/ocabot merge patch

dreispt avatar Dec 04 '21 14:12 dreispt

On my way to merge this fine PR! Prepared branch 12.0-ocabot-merge-pr-1827-by-dreispt-bump-patch, awaiting test results.

OCA-git-bot avatar Dec 04 '21 14:12 OCA-git-bot

Is this needed in v13, @Tardo ?

pedrobaeza avatar Dec 04 '21 14:12 pedrobaeza

It looks like something changed on 12.0 in the meantime. Let me try again (no action is required from you). Prepared branch 12.0-ocabot-merge-pr-1827-by-dreispt-bump-patch, awaiting test results.

OCA-git-bot avatar Dec 04 '21 20:12 OCA-git-bot

/ocabot merge patch

dreispt avatar May 11 '24 17:05 dreispt

@dreispt The merge process could not start, because command `git merge --no-ff -m 'Merge PR #1827 into 12.0

Signed-off-by dreispt' tmp-pr-1827` failed with output:

Auto-merging web_widget_one2many_product_picker/static/src/js/widgets/field_one2many_product_picker.js
CONFLICT (content): Merge conflict in web_widget_one2many_product_picker/static/src/js/widgets/field_one2many_product_picker.js
Auto-merging web_widget_one2many_product_picker/static/src/js/views/One2ManyProductPicker/record.js
CONFLICT (content): Merge conflict in web_widget_one2many_product_picker/static/src/js/views/One2ManyProductPicker/record.js
Automatic merge failed; fix conflicts and then commit the result.

OCA-git-bot avatar May 11 '24 17:05 OCA-git-bot