diff options
| author | Andrea Grazioso (agr-odoo) <agr@odoo.com> | 2021-05-03 15:17:13 +0000 |
|---|---|---|
| committer | Andrea Grazioso (agr-odoo) <agr@odoo.com> | 2021-05-04 17:10:39 +0000 |
| commit | 070c2853956c97bd64aac6abe0e208ef11ef8d3d (patch) | |
| tree | 007cd0214cb291786499b53607c8189d0d14077e | |
| parent | 721a88ea3386dc25669c78fb39f2247557780d6f (diff) | |
[FIX] *: avoid cutting 0.0 value in first row
Have in a purchase order a first row with unit price 0
Export the PO adding unit price in the list of fields to export
The unit price is not reported
This occur because the first line of the order lines is meld with the
purchase order line but in the process the 0.0 values is discarded
opw-2510917
closes odoo/odoo#70355
X-original-commit: 242bf5024ce6ae9c32176cd1a65a4f57a242dd45
Signed-off-by: agr-odoo <agr-odoo@users.noreply.github.com>
| -rw-r--r-- | odoo/models.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/odoo/models.py b/odoo/models.py index ff34e09f754..d77c22f4dad 100644 --- a/odoo/models.py +++ b/odoo/models.py @@ -911,7 +911,7 @@ class BaseModel(MetaModel('DummyModel', (object,), {'_register': False})): if lines2: # merge first line with record's main line for j, val in enumerate(lines2[0]): - if val or isinstance(val, bool): + if val or isinstance(val, (int, float)): current[j] = val # append the other lines at the end lines += lines2[1:] |
