You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
583 B
29 lines
583 B
import logging
|
|
|
|
from openerp.openupgrade import openupgrade
|
|
|
|
logger = logging.getLogger("OpenUpgrade")
|
|
|
|
column_renames = {
|
|
"job_sync_line": [
|
|
("adresse", "address"),
|
|
("ville", "city"),
|
|
("codepostal", "zip"),
|
|
("sync_date", "date"),
|
|
]
|
|
}
|
|
|
|
tables_renames = [
|
|
("job_sync_line", "subscription_request"),
|
|
("job_sync", None),
|
|
("external_db", None),
|
|
]
|
|
|
|
|
|
@openupgrade.migrate()
|
|
def migrate(cr, version):
|
|
if not version:
|
|
return
|
|
|
|
openupgrade.rename_columns(cr, column_renames)
|
|
openupgrade.rename_tables(cr, tables_renames)
|