Browse Source

Port of Birthdate

pull/243/head
Denis Leemann 9 years ago
parent
commit
601d8bacb5
  1. 1
      partner_contact_birthdate/README.rst
  2. 19
      partner_contact_birthdate/__init__.py
  3. 6
      partner_contact_birthdate/__openerp__.py
  4. 25
      partner_contact_birthdate/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
---------- ----------

19
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>
#
# 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/>.
# © <YEAR(S)> <AUTHOR(S)>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from . import models from . import models

6
partner_contact_birthdate/__openerp__.py

@ -18,15 +18,15 @@
{ {
"name": "Contact's birthdate", "name": "Contact's birthdate",
"version": "8.0.1.0.0",
"version": "9.0.1.0.0",
"author": "Odoo Community Association (OCA)", "author": "Odoo Community Association (OCA)",
"category": "Customer Relationship Management", "category": "Customer Relationship Management",
"website": "https://odoo-community.org/", "website": "https://odoo-community.org/",
"depends": [ "depends": [
"partner_contact_personal_information_page",
"base",
], ],
"data": [ "data": [
"views/res_partner.xml", "views/res_partner.xml",
], ],
'installable': False,
'installable': True,
} }

25
partner_contact_birthdate/views/res_partner.xml

@ -1,11 +1,30 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<openerp>
<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_personal_information_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="base.personal_contact_information"/>
<field name="arch" type="xml"> <field name="arch" type="xml">
<data> <data>
<xpath expr="//group[@name='personal_information_group']"> <xpath expr="//group[@name='personal_information_group']">
@ -16,4 +35,4 @@
</record> </record>
</data> </data>
</openerp>
</odoo>
Loading…
Cancel
Save