Files
odoo_source/addons/base_sparse_field/__init__.py
T
Raphael Collet b0646f9d2c [REF] move support for sparse fields into a separate module (#15070)
This removal has led to a necessary refactoring:
- make the setup of field attributes extensible;
- make the instantiation of custom fields extensible;
- delegate model and field reflection to `ir.model` and `ir.model.fields`;
- move the implementation of sparse and serialized fields to module `base_sparse_field`;
2017-01-19 16:29:29 +01:00

13 lines
378 B
Python

# -*- coding: utf-8 -*-
from . import models
from . import tests
def _update_database_schema(cr):
# The reflection of fields is done before updating the model's schema,
# therefore we first update the schema.
cr.execute("""
ALTER TABLE ir_model_fields
ADD COLUMN serialization_field_id integer REFERENCES ir_model_fields ON DELETE cascade
""")