Files
odoo_source/addons/pos_sale/models/__init__.py
T
Nicolas Seinlet e8f01b94ce [IMP] sale,sale_*: denormalize sale.order to speed up sale.report
Impacted modules: sale, sale_margin, sale_timesheet, pos_sale

This speed up a lot reports like sale.report when multiple currencies
with multiple rates are used, even with few currencies and few rates.
Using `_select_companies_rates` in SQL view bring lots of JOINs,
which slow down the view generation. This commit adds a computed
stored field containing the currency rate at the order date to speed
up report generation (database schema denormalisation).

This commit also use this new column on sale.report extensions and on
the project.profitability.report in sale_timesheet module.

Since a4d6bff197, the pos.report is
included in the sale.report. So, the same change had to be
applied on the pos.order model.

Task #1877418
Closes #25089
2018-08-21 13:28:42 +02:00

8 lines
198 B
Python

# -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.
from . import pos_config
from . import pos_order
from . import crm_team
from . import pos_session