diff options
| author | Adrian Torres <adt@odoo.com> | 2018-11-12 19:03:15 +0100 |
|---|---|---|
| committer | Romain Derie <rde@odoo.com> | 2018-11-15 15:56:14 +0100 |
| commit | 51c7afff48871335a79af849d16bbaea15454e0e (patch) | |
| tree | 0d3544e7a1a316601abe7ef00a29ea4131aca429 /tests/test_program_with_code_operations.py | |
| parent | 7633f963066c4962a5d722b7e755e8468b4c2b54 (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
Diffstat (limited to 'tests/test_program_with_code_operations.py')
0 files changed, 0 insertions, 0 deletions
