diff --git a/partner_contact_gender/README.rst b/partner_contact_gender/README.rst new file mode 100644 index 000000000..9ec0f96f0 --- /dev/null +++ b/partner_contact_gender/README.rst @@ -0,0 +1,58 @@ +.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg + :alt: License: AGPL-3 + +Partner Gender +============== + +This module was written to extend the functionality of Odoo contacts manager to +support setting the gender of a partner. + +Installation +============ + +To install this module, you need to: + +* Install the `partner-contact`_ repository. + + +.. _partner-contact: https://github.com/OCA/partner-contact/ + +Usage +===== + +To use this module, you need to: + +* Edit a partner or create a new one. +* Ensure the partner is **not** a company. +* Go to the *Personal information* sheet. +* Set the gender there. + +For further information, please visit: + +* https://www.odoo.com/forum/help-1 +* https://github.com/OCA/partner-contact/ + +Credits +======= + +* Icon from `Font Awesome `_. + +Contributors +------------ + +* Jairo Llopis + +Maintainer +---------- + +.. image:: https://odoo-community.org/logo.png + :alt: Odoo Community Association + :target: https://odoo-community.org + +This module is maintained by the OCA. + +OCA, or the Odoo Community Association, is a nonprofit organization whose +mission is to support the collaborative development of Odoo features and +promote its widespread use. + +To contribute to this module, please visit http://odoo-community.org. diff --git a/partner_contact_gender/__init__.py b/partner_contact_gender/__init__.py new file mode 100644 index 000000000..685080d25 --- /dev/null +++ b/partner_contact_gender/__init__.py @@ -0,0 +1,19 @@ +# -*- encoding: utf-8 -*- + +# Odoo, Open Source Management Solution +# Copyright (C) 2014-2015 Grupo ESOC +# +# 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 . + +from . import models diff --git a/partner_contact_gender/__openerp__.py b/partner_contact_gender/__openerp__.py new file mode 100644 index 000000000..a6638811e --- /dev/null +++ b/partner_contact_gender/__openerp__.py @@ -0,0 +1,35 @@ +# -*- encoding: utf-8 -*- + +# Odoo, Open Source Management Solution +# Copyright (C) 2014-2015 Grupo ESOC +# +# 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 . + +{ + "name": "Contact gender", + "version": "8.0.1.0.0", + "category": "Customer Relationship Management", + "author": "Odoo Community Association (OCA), Grupo ESOC", + "license": "AGPL-3", + "website": "https://odoo-community.org/", + "installable": True, + "application": False, + "summary": "Add gender field to contacts", + "depends": [ + "partner_contact_personal_information_page", + ], + "data": [ + "views/res_partner.xml", + ], +} diff --git a/partner_contact_gender/i18n/es.po b/partner_contact_gender/i18n/es.po new file mode 100644 index 000000000..f58f87b5a --- /dev/null +++ b/partner_contact_gender/i18n/es.po @@ -0,0 +1,38 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * partner_gender +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 8.0-20150514\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2015-05-18 10:55+0000\n" +"PO-Revision-Date: 2015-05-18 12:57+0100\n" +"Last-Translator: Jairo Llopis \n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" +"X-Generator: Poedit 1.7.6\n" +"Language: es_ES\n" + +#. module: partner_gender +#: selection:res.partner,gender:0 +msgid "Female" +msgstr "Femenino" + +#. module: partner_gender +#: field:res.partner,gender:0 +msgid "Gender" +msgstr "Género" + +#. module: partner_gender +#: selection:res.partner,gender:0 +msgid "Male" +msgstr "Masculino" + +#. module: partner_gender +#: model:ir.model,name:partner_gender.model_res_partner +msgid "Partner" +msgstr "Empresa" diff --git a/partner_contact_gender/i18n/partner_gender.pot b/partner_contact_gender/i18n/partner_gender.pot new file mode 100644 index 000000000..b7839051f --- /dev/null +++ b/partner_contact_gender/i18n/partner_gender.pot @@ -0,0 +1,37 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * partner_gender +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 8.0-20150514\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2015-05-18 10:55+0000\n" +"PO-Revision-Date: 2015-05-18 10:55+0000\n" +"Last-Translator: <>\n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: partner_gender +#: selection:res.partner,gender:0 +msgid "Female" +msgstr "" + +#. module: partner_gender +#: field:res.partner,gender:0 +msgid "Gender" +msgstr "" + +#. module: partner_gender +#: selection:res.partner,gender:0 +msgid "Male" +msgstr "" + +#. module: partner_gender +#: model:ir.model,name:partner_gender.model_res_partner +msgid "Partner" +msgstr "" + diff --git a/partner_contact_gender/models.py b/partner_contact_gender/models.py new file mode 100644 index 000000000..88f632381 --- /dev/null +++ b/partner_contact_gender/models.py @@ -0,0 +1,26 @@ +# -*- encoding: utf-8 -*- + +# Odoo, Open Source Management Solution +# Copyright (C) 2014-2015 Grupo ESOC +# +# 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 . + +from openerp import fields, models + + +class Partner(models.Model): + """Partners with gender.""" + _inherit = "res.partner" + + gender = fields.Selection([('male', 'Male'), ('female', 'Female')]) diff --git a/partner_contact_gender/static/description/icon.png b/partner_contact_gender/static/description/icon.png new file mode 100644 index 000000000..e3761210a Binary files /dev/null and b/partner_contact_gender/static/description/icon.png differ diff --git a/partner_contact_gender/static/description/icon.svg b/partner_contact_gender/static/description/icon.svg new file mode 100644 index 000000000..2a087ff6d --- /dev/null +++ b/partner_contact_gender/static/description/icon.svg @@ -0,0 +1,45 @@ + + + + + + + image/svg+xml + + + + + + + + diff --git a/partner_contact_gender/views/res_partner.xml b/partner_contact_gender/views/res_partner.xml new file mode 100644 index 000000000..fdaa83893 --- /dev/null +++ b/partner_contact_gender/views/res_partner.xml @@ -0,0 +1,38 @@ + + + + + + + + + Partner gender + res.partner + + + + + + + + + + + +