Browse Source

[IMP] add birth country in pc_birthplace

16.0
RemiFr82 7 months ago
parent
commit
62ccb5fc62
  1. 2
      partner_contact_birthplace/__manifest__.py
  2. 10
      partner_contact_birthplace/i18n/fr.po
  3. 4
      partner_contact_birthplace/models/res_partner.py
  4. 8
      partner_contact_birthplace/views/res_partner.xml

2
partner_contact_birthplace/__manifest__.py

@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl.html).
{
"name": "Contact's birth place",
"name": "Contact birth place",
"version": "16.0.1.0.0",
"summary": "Module summary",
"description": """

10
partner_contact_birthplace/i18n/fr.po

@ -6,8 +6,8 @@ msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 16.0-20230613\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-05-27 20:05+0000\n"
"PO-Revision-Date: 2024-05-27 20:05+0000\n"
"POT-Creation-Date: 2024-05-29 12:58+0000\n"
"PO-Revision-Date: 2024-05-29 12:58+0000\n"
"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
@ -15,6 +15,12 @@ msgstr ""
"Content-Transfer-Encoding: \n"
"Plural-Forms: \n"
#. module: partner_contact_birthplace
#: model:ir.model.fields,field_description:partner_contact_birthplace.field_res_partner__birthplace_country_id
#: model:ir.model.fields,field_description:partner_contact_birthplace.field_res_users__birthplace_country_id
msgid "Birth country"
msgstr "Pays de naissance"
#. module: partner_contact_birthplace
#: model:ir.model.fields,field_description:partner_contact_birthplace.field_res_partner__birthplace
#: model:ir.model.fields,field_description:partner_contact_birthplace.field_res_users__birthplace

4
partner_contact_birthplace/models/res_partner.py

@ -7,3 +7,7 @@ class ResPartner(models.Model):
_inherit = "res.partner"
birthplace = fields.Char("Birth place")
birthplace_country_id = fields.Many2one(
comodel_name="res.country",
string="Birth country",
)

8
partner_contact_birthplace/views/res_partner.xml

@ -3,7 +3,7 @@
<odoo>
<record id="personal_information_form_inherit" model="ir.ui.view">
<field name="name">res.partner.form.inherit Birth place</field>
<field name="name">res.partner.form.inherit.birthplace</field>
<field name="model">res.partner</field>
<field name="inherit_id" ref="partner_contact_personal_information_page.personal_information" />
<field name="priority">18</field>
@ -19,7 +19,11 @@
</group>
</group>
<field name="birthdate_date" position="after">
<field name="birthplace" />
<label for="birthplace" />
<div class="o_row">
<field name="birthplace" nolabel="1" />
<field name="birthplace_country_id" options="{'no_create': 1, 'no_open':1}" nolabel="1" class="oe_inline" />
</div>
</field>
</field>
</record>

Loading…
Cancel
Save