Purpose is to reorganize code according to guidelines and split the main badly named python file, to understand that 3 models are impacted: res.company, res.country and res.partner. Task ID 2158302 PR odoo/odoo#42678
19 lines
814 B
Python
19 lines
814 B
Python
# -*- coding: utf-8 -*-
|
|
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
|
|
|
from odoo import fields, models
|
|
|
|
|
|
class ResCountry(models.Model):
|
|
_inherit = 'res.country'
|
|
|
|
street_format = fields.Text(
|
|
help="Format to use for streets belonging to this country.\n\n"
|
|
"You can use the python-style string pattern with all the fields of the street "
|
|
"(for example, use '%(street_name)s, %(street_number)s' if you want to display "
|
|
"the street name, followed by a comma and the house number)"
|
|
"\n%(street_name)s: the name of the street"
|
|
"\n%(street_number)s: the house number"
|
|
"\n%(street_number2)s: the door number",
|
|
default='%(street_number)s/%(street_number2)s %(street_name)s', required=True)
|