diff options
| author | Arnaud Baes <arb@odoo.com> | 2020-01-20 14:10:10 +0000 |
|---|---|---|
| committer | Arnaud Baes <arb@odoo.com> | 2020-01-27 19:51:58 +0000 |
| commit | 97af72330a79f69352e293e0758e2a22b83720b7 (patch) | |
| tree | a478ccf7fd74864977af3d89691c8f9fafb27726 /odoo/modules/loading.py | |
| parent | c51b02701992d02ef332c7271e3c1a275d8bdfa5 (diff) | |
[FIX] product: Add products without 'combination_indices' to cart.
Sometimes when we try to buy a product that doesn't have any variants,
it would result in an error saying there isn't any valid combination
for that product.
This was happening because `_get_variant_id_for_combination` was
considering that the field `combination_indices` would always be
equal to `''` (empty string) in such a case.
This isn't true as `combination_indices` isn't a required field
thus allowing `null` \ `None` to be valid values for that field.
This fix will simply include products with no values set for their
`combination_indices` when searching a corresponding variant from
the `product_template`.
closes odoo/odoo#44056
X-original-commit: 03e7efc3b4592c5f063c665130011a91fcc4d683
Signed-off-by: Toufik Benjaa (tbe) <tbe@odoo.com>
Diffstat (limited to 'odoo/modules/loading.py')
0 files changed, 0 insertions, 0 deletions
