Closed cubells closed 2 years ago
Do you have a patch for this?
I'm trying to find the best solution for this.
OK, let me know
There hasn't been any activity on this issue in the past 6 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 30 days. If you want this issue to never become stale, please ask a PSC member to apply the "no stale" label.
If pricelist discount_policy is equal to 'without_discount', and you search for a template in sale order line, then an error is raised because this line:
https://github.com/OCA/product-variant/blob/11.0/sale_variant_configurator/models/sale_order.py#L143
generate a list of tuples with a product.product recordset null, as product_id field is empty at this moment:
https://github.com/OCA/product-variant/blob/11.0/product_variant_configurator/models/pricelist.py#L21
To reproduce the error only have to change the discount_policy of the pricelist of the sale order and search for a template with variants in the sale order line.
The log I've got: