Browse Source

Merge pull request #243 from leemannd/personal_information-fix

Port of partner_contact_birthdate
pull/306/head
Alexandre Fayolle 8 years ago
committed by GitHub
parent
commit
691c6a16fe
  1. 1
      partner_contact_birthdate/README.rst
  2. 17
      partner_contact_birthdate/__init__.py
  3. 25
      partner_contact_birthdate/__openerp__.py
  4. 16
      partner_contact_birthdate/data/res_partner.yml
  5. 5
      partner_contact_birthdate/models/__init__.py
  6. 17
      partner_contact_birthdate/models/res_partner.py
  7. 17
      partner_contact_birthdate/tests/__init__.py
  8. 16
      partner_contact_birthdate/tests/test_birthdate.py
  9. 11
      partner_contact_birthdate/views/res_partner.xml
  10. 2
      partner_contact_gender/__openerp__.py
  11. 23
      partner_contact_gender/views/res_partner.xml
  12. 3
      partner_contact_in_several_companies/__openerp__.py
  13. 21
      partner_contact_in_several_companies/views/res_partner.xml
  14. 2
      partner_contact_nationality/__openerp__.py
  15. 25
      partner_contact_nationality/views/res_partner.xml
  16. 2
      partner_contact_personal_information_page/views/res_partner.xml

1
partner_contact_birthdate/README.rst

@ -58,6 +58,7 @@ Contributors
* Jairo Llopis <j.llopis@grupoesoc.es> * Jairo Llopis <j.llopis@grupoesoc.es>
* Matjaž Mozetič <m.mozetic@matmoz.si> * Matjaž Mozetič <m.mozetic@matmoz.si>
* Rudolf Schnapka <schnapkar@golive-saar.de> * Rudolf Schnapka <schnapkar@golive-saar.de>
* Denis Leemann <denis.leemann@camptocamp.com>
Maintainer Maintainer
---------- ----------

17
partner_contact_birthdate/__init__.py

@ -1,19 +1,4 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Odoo, Open Source Management Solution
# Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es> # Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from . import models from . import models

25
partner_contact_birthdate/__openerp__.py

@ -1,25 +1,12 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Odoo, Open Source Management Solution
# Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# Copyright 2014-2015 Grupo ESOC <www.grupoesoc.es>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
{ {
"name": "Contact's birthdate", "name": "Contact's birthdate",
"version": "8.0.1.0.0",
"author": "Odoo Community Association (OCA)",
"version": "9.0.1.0.0",
"author": "Jairo Llopis,"
"Odoo Community Association (OCA)",
"category": "Customer Relationship Management", "category": "Customer Relationship Management",
"website": "https://odoo-community.org/", "website": "https://odoo-community.org/",
"depends": [ "depends": [
@ -28,5 +15,5 @@
"data": [ "data": [
"views/res_partner.xml", "views/res_partner.xml",
], ],
'installable': False,
'installable': True,
} }

16
partner_contact_birthdate/data/res_partner.yml

@ -1,19 +1,5 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Odoo, Open Source Management Solution
# Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es> # Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
- !function {model: res.partner, name: _birthdate_install} - !function {model: res.partner, name: _birthdate_install}

5
partner_contact_birthdate/models/__init__.py

@ -0,0 +1,5 @@
# -*- coding: utf-8 -*-
# Copyright 2014-2015 Grupo ESOC <www.grupoesoc.es>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from . import res_partner

17
partner_contact_birthdate/models.py → partner_contact_birthdate/models/res_partner.py

@ -1,21 +1,6 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Odoo, Open Source Management Solution
# Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es> # Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from openerp import _, api, fields, models from openerp import _, api, fields, models
import logging import logging

17
partner_contact_birthdate/tests/__init__.py

@ -1,19 +1,4 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Odoo, Open Source Management Solution
# Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es> # Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from . import test_birthdate from . import test_birthdate

16
partner_contact_birthdate/tests/test_birthdate.py

@ -1,20 +1,6 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Odoo, Open Source Management Solution
# Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es> # Copyright (C) 2014-2015 Grupo ESOC <www.grupoesoc.es>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from openerp import fields from openerp import fields
from openerp.tests.common import TransactionCase from openerp.tests.common import TransactionCase

11
partner_contact_birthdate/views/res_partner.xml

@ -1,8 +1,10 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<!-- License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
© 2015 Grupo ESOC Ingeniería de Servicios, S.L.U. -->
<odoo>
<record id="birthdate_date" model="ir.ui.view">
<record id="view_personal_information_birthdate_date" model="ir.ui.view">
<field name="name">Birthdate Date field</field> <field name="name">Birthdate Date field</field>
<field name="model">res.partner</field> <field name="model">res.partner</field>
<field name="inherit_id" ref="partner_contact_personal_information_page.personal_information"/> <field name="inherit_id" ref="partner_contact_personal_information_page.personal_information"/>
@ -15,5 +17,4 @@
</field> </field>
</record> </record>
</data>
</openerp>
</odoo>

2
partner_contact_gender/__openerp__.py

@ -18,7 +18,7 @@
'installable': True, 'installable': True,
'auto_install': False, 'auto_install': False,
"depends": [ "depends": [
"base",
"partner_contact_personal_information_page",
], ],
"data": [ "data": [
"views/res_partner.xml", "views/res_partner.xml",

23
partner_contact_gender/views/res_partner.xml

@ -2,29 +2,10 @@
<odoo> <odoo>
<data> <data>
<!-- Declared the same in every module that may need it -->
<record id="base.personal_contact_information" model="ir.ui.view">
<field name="name">Personal information page for contacts form</field>
<field name="model">res.partner</field>
<field name="inherit_id" ref="base.view_partner_form"/>
<field name="priority">2</field>
<field name="arch" type="xml">
<data>
<xpath expr="//page[@name='internal_notes']" position="after">
<page name="personal_information_page"
string="Personal Information"
attrs="{'invisible': [('is_company','=',True)]}">
<group name="personal_information_group"/>
</page>
</xpath>
</data>
</field>
</record>
<record id="personal_contact_information" model="ir.ui.view">
<record id="view_personal_information_gender" model="ir.ui.view">
<field name="name">Partner gender: personal info</field> <field name="name">Partner gender: personal info</field>
<field name="model">res.partner</field> <field name="model">res.partner</field>
<field name="inherit_id" ref="base.personal_contact_information"/>
<field name="inherit_id" ref="partner_contact_personal_information_page.personal_information"/>
<field name="arch" type="xml"> <field name="arch" type="xml">
<data> <data>
<xpath expr="//page[@name='personal_information_page']/group[@name='personal_information_group']"> <xpath expr="//page[@name='personal_information_page']/group[@name='personal_information_group']">

3
partner_contact_in_several_companies/__openerp__.py

@ -23,7 +23,8 @@
'installable': True, 'installable': True,
'auto_install': False, 'auto_install': False,
"depends": [ "depends": [
"base"
"base",
"partner_contact_personal_information_page",
], ],
"data": [ "data": [
"views/res_partner.xml", "views/res_partner.xml",

21
partner_contact_in_several_companies/views/res_partner.xml

@ -2,25 +2,6 @@
<odoo> <odoo>
<data> <data>
<!-- Declared the same in every module that may need it -->
<record id="base.personal_contact_information" model="ir.ui.view">
<field name="name">Personal information page for contacts form</field>
<field name="model">res.partner</field>
<field name="inherit_id" ref="base.view_partner_form"/>
<field name="priority">2</field>
<field name="arch" type="xml">
<data>
<xpath expr="//page[@name='internal_notes']" position="after">
<page name="personal_information_page"
string="Personal Information"
attrs="{'invisible': [('is_company','=',True)]}">
<group name="personal_information_group"/>
</page>
</xpath>
</data>
</field>
</record>
<record id="view_res_partner_filter_contact" model="ir.ui.view"> <record id="view_res_partner_filter_contact" model="ir.ui.view">
<field name="name">res.partner.select.contact</field> <field name="name">res.partner.select.contact</field>
<field name="model">res.partner</field> <field name="model">res.partner</field>
@ -162,7 +143,7 @@
<record id="personal_contact_information" model="ir.ui.view"> <record id="personal_contact_information" model="ir.ui.view">
<field name="name">Contacts in several partners: personal info</field> <field name="name">Contacts in several partners: personal info</field>
<field name="model">res.partner</field> <field name="model">res.partner</field>
<field name="inherit_id" ref="base.personal_contact_information"/>
<field name="inherit_id" ref="partner_contact_personal_information_page.personal_information"/>
<field name="arch" type="xml"> <field name="arch" type="xml">
<data> <data>
<xpath expr="//page[@name='personal_information_page']/group[@name='personal_information_group']" <xpath expr="//page[@name='personal_information_page']/group[@name='personal_information_group']"

2
partner_contact_nationality/__openerp__.py

@ -18,7 +18,7 @@
'installable': True, 'installable': True,
'auto_install': False, 'auto_install': False,
"depends": [ "depends": [
"base",
"partner_contact_personal_information_page",
], ],
"data": [ "data": [
"views/res_partner.xml", "views/res_partner.xml",

25
partner_contact_nationality/views/res_partner.xml

@ -1,30 +1,10 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<odoo> <odoo>
<data>
<!-- Declared the same in every module that may need it -->
<record id="base.personal_contact_information" model="ir.ui.view">
<field name="name">Personal information page for contacts form</field>
<field name="model">res.partner</field>
<field name="inherit_id" ref="base.view_partner_form"/>
<field name="priority">2</field>
<field name="arch" type="xml">
<data>
<xpath expr="//page[@name='internal_notes']" position="after">
<page name="personal_information_page"
string="Personal Information"
attrs="{'invisible': [('is_company','=',True)]}">
<group name="personal_information_group"/>
</page>
</xpath>
</data>
</field>
</record>
<record id="personal_contact_information" model="ir.ui.view">
<record id="view_personal_information_page_nationality" model="ir.ui.view">
<field name="name">Partner nationality: personal info</field> <field name="name">Partner nationality: personal info</field>
<field name="model">res.partner</field> <field name="model">res.partner</field>
<field name="inherit_id" ref="base.personal_contact_information"/>
<field name="inherit_id" ref="partner_contact_personal_information_page.personal_information"/>
<field name="arch" type="xml"> <field name="arch" type="xml">
<data> <data>
<xpath expr="//page[@name='personal_information_page']/group[@name='personal_information_group']"> <xpath expr="//page[@name='personal_information_page']/group[@name='personal_information_group']">
@ -34,5 +14,4 @@
</field> </field>
</record> </record>
</data>
</odoo> </odoo>

2
partner_contact_personal_information_page/views/res_partner.xml

@ -3,7 +3,7 @@
<data> <data>
<!-- Declared the same in every module that may need it --> <!-- Declared the same in every module that may need it -->
<record id="base.personal_contact_information" model="ir.ui.view">
<record id="personal_information" model="ir.ui.view">
<field name="name">Personal information page for contacts form</field> <field name="name">Personal information page for contacts form</field>
<field name="model">res.partner</field> <field name="model">res.partner</field>
<field name="inherit_id" ref="base.view_partner_form"/> <field name="inherit_id" ref="base.view_partner_form"/>

Loading…
Cancel
Save