mirror of
https://gitlab.com/flectra-community/mis-builder.git
synced 2024-11-16 19:22:04 +00:00
21 lines
521 B
Python
21 lines
521 B
Python
|
# Copyright 2017 ACSONE SA/NV (<http://acsone.eu>)
|
||
|
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
|
||
|
|
||
|
|
||
|
def migrate(cr, version):
|
||
|
cr.execute(
|
||
|
"""
|
||
|
ALTER TABLE mis_report_kpi
|
||
|
RENAME COLUMN expression TO old_expression
|
||
|
"""
|
||
|
)
|
||
|
# this migration to date_range type is partial,
|
||
|
# actual date ranges needs to be created manually
|
||
|
cr.execute(
|
||
|
"""
|
||
|
UPDATE mis_report_instance_period
|
||
|
SET type='date_range'
|
||
|
WHERE type='fp'
|
||
|
"""
|
||
|
)
|