From 18a5c221605dddff677d3160b91f20e1a12d2937 Mon Sep 17 00:00:00 2001 From: Alexis de Lattre Date: Thu, 14 Mar 2024 17:19:20 +0100 Subject: [PATCH] sale_margin_no_onchange: fix digits in field declaration --- sale_margin_no_onchange/models/sale.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/sale_margin_no_onchange/models/sale.py b/sale_margin_no_onchange/models/sale.py index 847438c..2e6cfff 100644 --- a/sale_margin_no_onchange/models/sale.py +++ b/sale_margin_no_onchange/models/sale.py @@ -4,7 +4,6 @@ from odoo import api, fields, models -import odoo.addons.decimal_precision as dp class SaleOrderLine(models.Model): @@ -16,13 +15,13 @@ class SaleOrderLine(models.Model): store=True, string='Company Currency') standard_price_company_currency = fields.Float( string='Cost Price in Company Currency', readonly=True, - digits=dp.get_precision('Product Price'), + digits="Product Price", help="Cost price in company currency in the unit of measure " "of the sale order line") standard_price_sale_currency = fields.Float( string='Cost Price in Sale Currency', compute='_compute_margin', store=True, - digits=dp.get_precision('Product Price'), + digits="Product Price", help="Cost price in sale currency in the unit of measure " "of the sale order line") margin_sale_currency = fields.Monetary(