summaryrefslogtreecommitdiff
path: root/tests/test_program_with_code_operations.py
diff options
context:
space:
mode:
authorAdrian Torres <adt@odoo.com>2018-10-19 12:47:04 +0000
committerAdrian Torres <adt@odoo.com>2018-10-23 06:57:50 +0000
commitc8d5ff55ffa552984e71391eff0b51baae5e6c90 (patch)
treec8ba5429bc1dfaf70a5dc02dae48217d98ed2a0e /tests/test_program_with_code_operations.py
parent879aef37f3034556b310ad7b1beb396467153ca7 (diff)
[FIX] sale_coupon: restore SO processing time
This optimizes the confirmation of a sale_order in the ecommerce by ~73%, for a cart with 160 unique items, the processing time goes from 7m46s to 39s, which is roughly the same amount of processing time if the module `sale_coupon` is not installed. This optimization is achieved in two steps: 1. By validating promotional/discounted products in batch instead of validating each product one at a time. 2. By performing an unlink() on invalid reward lines instead of sending a delete command by writing to the one2many, as delete commands are not (yet) performed in batch, which means record recomputation after every delete. opw-1893277 closes odoo/enterprise#2905
Diffstat (limited to 'tests/test_program_with_code_operations.py')
0 files changed, 0 insertions, 0 deletions