Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[16.0] [MIG] event_contact #368

Merged
merged 18 commits into from
May 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
114 changes: 114 additions & 0 deletions event_contact/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,114 @@
==============
Event Contacts
==============

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:bafc114c15b34c69ec046ec94097f24619a35662c8e3abebc37c63e541d60527
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
:alt: Beta
.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fevent-lightgray.png?logo=github
:target: https://github.com/OCA/event/tree/16.0/event_contact
:alt: OCA/event
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/event-16-0/event-16-0-event_contact
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
:target: https://runboat.odoo-community.org/builds?repo=OCA/event&target_branch=16.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|

This module adds the possibility to define contacts for the event.
Contacts are needed due to inform the people who should be contacted for
the event.

**Table of contents**

.. contents::
:local:

Usage
=====

To set contacts to event, you need to:

#. Go to *Events > Events*.
#. Edit or create one.
#. You will see a new field under field *Organizer* named *Contacts*.

To set contacts for an event type, you need to:

#. Go to *Events > Configuration > Event Templates*.
#. Edit or create one.
#. You will see a new field under field *Tags* named *Contacts*.
#. After doing this, if you create an event and set it this type, the event
will get appended these contacts automatically.

Bug Tracker
===========

Bugs are tracked on `GitHub Issues <https://github.com/OCA/event/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
`feedback <https://github.com/OCA/event/issues/new?body=module:%20event_contact%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

Do not contact contributors directly about support or help with technical issues.

Credits
=======

Authors
~~~~~~~

* OpenSynergy Indonesia
* Tecnativa

Contributors
~~~~~~~~~~~~

* Michael Viriyananda <viriyananda.michael@gmail.com>
* David Alonso <david.alonso@solvos.es>
* `Tecnativa <https://www.tecnativa.com>`__:

* Jairo Llopis
* Alexandre Díaz
* Ernesto Tejeda
* Eduardo López <elp@moduon.team>

Maintainers
~~~~~~~~~~~

This module is maintained by the OCA.

.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org

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.

.. |maintainer-rafaelbn| image:: https://github.com/rafaelbn.png?size=40px
:target: https://github.com/rafaelbn
:alt: rafaelbn
.. |maintainer-edlopen| image:: https://github.com/edlopen.png?size=40px
:target: https://github.com/edlopen
:alt: edlopen

Current `maintainers <https://odoo-community.org/page/maintainer-role>`__:

|maintainer-rafaelbn| |maintainer-edlopen|

This module is part of the `OCA/event <https://github.com/OCA/event/tree/16.0/event_contact>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
3 changes: 3 additions & 0 deletions event_contact/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).

from . import models
20 changes: 20 additions & 0 deletions event_contact/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Copyright 2016 OpenSynergy Indonesia
# Copyright 2016-2017 Jairo Llopis <jairo.llopis@tecnativa.com>
# Copyright 2019 Alexandre Díaz <alexandre.diaz@tecnativa.com>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).

{
"name": "Event Contacts",
"version": "16.0.1.0.0",
"summary": "Add contacts to event and event type",
"author": "OpenSynergy Indonesia, "
"Tecnativa, "
"Odoo Community Association (OCA)",
"website": "https://github.com/OCA/event",
"category": "Marketing",
"depends": ["event"],
"maintainers": ["rafaelbn", "edlopen"],
"data": ["views/event_event_view.xml", "views/event_type_view.xml"],
"installable": True,
"license": "AGPL-3",
}
71 changes: 71 additions & 0 deletions event_contact/i18n/es.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * event_contact
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 8.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-05-05 22:25+0000\n"
"PO-Revision-Date: 2023-12-29 10:33+0000\n"
"Last-Translator: Ivorra78 <informatica@totmaterial.es>\n"
"Language-Team: \n"
"Language: es\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 4.17\n"

#. module: event_contact
#: model:ir.model.fields,field_description:event_contact.field_event_event__contact_ids
#: model:ir.model.fields,field_description:event_contact.field_event_type__contact_ids
msgid "Contacts"
msgstr "Contactos"

#. module: event_contact
#: model:ir.model.fields,field_description:event_contact.field_event_event__display_name
#: model:ir.model.fields,field_description:event_contact.field_event_type__display_name
msgid "Display Name"
msgstr "Mostrar Nombre"

#. module: event_contact
#: model:ir.model,name:event_contact.model_event_event
msgid "Event"
msgstr "Evento"

#. module: event_contact
#: model:ir.model,name:event_contact.model_event_type
msgid "Event Template"
msgstr "Plantilla del Evento"

#. module: event_contact
#: model:ir.model.fields,field_description:event_contact.field_event_event__id
#: model:ir.model.fields,field_description:event_contact.field_event_type__id
msgid "ID"
msgstr "ID"

#. module: event_contact
#: model:ir.model.fields,field_description:event_contact.field_event_event____last_update
#: model:ir.model.fields,field_description:event_contact.field_event_type____last_update
msgid "Last Modified on"
msgstr "Última Modificación el"

#. module: event_contact
#: model:ir.model.fields,help:event_contact.field_event_type__contact_ids
msgid ""
"Partners available to attend attendees requests by default for events of "
"this type."
msgstr ""
"Contactos disponibles por defecto para atender las peticiones de los "
"asistentes para los eventos de este tipo."

#. module: event_contact
#: model:ir.model.fields,help:event_contact.field_event_event__contact_ids
msgid "Partners available to attend attendees requests for this event."
msgstr ""
"Contactos disponibles para atender las peticiones de los asistentes para "
"este evento."

#~ msgid "Event Type"
#~ msgstr "Tipo de evento"
60 changes: 60 additions & 0 deletions event_contact/i18n/event_contact.pot
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * event_contact
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 14.0\n"
"Report-Msgid-Bugs-To: \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: event_contact
#: model:ir.model.fields,field_description:event_contact.field_event_event__contact_ids
#: model:ir.model.fields,field_description:event_contact.field_event_type__contact_ids
msgid "Contacts"
msgstr ""

#. module: event_contact
#: model:ir.model.fields,field_description:event_contact.field_event_event__display_name
#: model:ir.model.fields,field_description:event_contact.field_event_type__display_name
msgid "Display Name"
msgstr ""

#. module: event_contact
#: model:ir.model,name:event_contact.model_event_event
msgid "Event"
msgstr ""

#. module: event_contact
#: model:ir.model,name:event_contact.model_event_type
msgid "Event Template"
msgstr ""

#. module: event_contact
#: model:ir.model.fields,field_description:event_contact.field_event_event__id
#: model:ir.model.fields,field_description:event_contact.field_event_type__id
msgid "ID"
msgstr ""

#. module: event_contact
#: model:ir.model.fields,field_description:event_contact.field_event_event____last_update
#: model:ir.model.fields,field_description:event_contact.field_event_type____last_update
msgid "Last Modified on"
msgstr ""

#. module: event_contact
#: model:ir.model.fields,help:event_contact.field_event_type__contact_ids
msgid ""
"Partners available to attend attendees requests by default for events of "
"this type."
msgstr ""

#. module: event_contact
#: model:ir.model.fields,help:event_contact.field_event_event__contact_ids
msgid "Partners available to attend attendees requests for this event."
msgstr ""
65 changes: 65 additions & 0 deletions event_contact/i18n/it.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * event_contact
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 14.0\n"
"Report-Msgid-Bugs-To: \n"
"PO-Revision-Date: 2023-07-20 08:09+0000\n"
"Last-Translator: mymage <stefano.consolaro@mymage.it>\n"
"Language-Team: none\n"
"Language: it\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 4.17\n"

#. module: event_contact
#: model:ir.model.fields,field_description:event_contact.field_event_event__contact_ids
#: model:ir.model.fields,field_description:event_contact.field_event_type__contact_ids
msgid "Contacts"
msgstr "Contatti"

#. module: event_contact
#: model:ir.model.fields,field_description:event_contact.field_event_event__display_name
#: model:ir.model.fields,field_description:event_contact.field_event_type__display_name
msgid "Display Name"
msgstr "Nome visualizzato"

#. module: event_contact
#: model:ir.model,name:event_contact.model_event_event
msgid "Event"
msgstr "Evento"

#. module: event_contact
#: model:ir.model,name:event_contact.model_event_type
msgid "Event Template"
msgstr "Modello evento"

#. module: event_contact
#: model:ir.model.fields,field_description:event_contact.field_event_event__id
#: model:ir.model.fields,field_description:event_contact.field_event_type__id
msgid "ID"
msgstr "ID"

#. module: event_contact
#: model:ir.model.fields,field_description:event_contact.field_event_event____last_update
#: model:ir.model.fields,field_description:event_contact.field_event_type____last_update
msgid "Last Modified on"
msgstr "Ultima modifica il"

#. module: event_contact
#: model:ir.model.fields,help:event_contact.field_event_type__contact_ids
msgid ""
"Partners available to attend attendees requests by default for events of "
"this type."
msgstr ""
"Partner disponibili in modo predefinito ad iscrivere partecipanti per eventi "
"di questo tipo."

#. module: event_contact
#: model:ir.model.fields,help:event_contact.field_event_event__contact_ids
msgid "Partners available to attend attendees requests for this event."
msgstr "Partner disponibili ad iscrivere partecipanti per questo evento."
4 changes: 4 additions & 0 deletions event_contact/models/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).

from . import event_event
from . import event_type
23 changes: 23 additions & 0 deletions event_contact/models/event_event.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Copyright 2016 OpenSynergy Indonesia
# Copyright 2017 Jairo Llopis <jairo.llopis@tecnativa.com>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).

from odoo import api, fields, models


class EventEvent(models.Model):
_inherit = "event.event"

contact_ids = fields.Many2many(
string="Contacts",
comodel_name="res.partner",
help="Partners available to attend attendees requests for this event.",
compute="_compute_contact_ids",
store=True,
readonly=False,
)

@api.depends("event_type_id")
def _compute_contact_ids(self):
for one in self:
one.contact_ids |= one.event_type_id.contact_ids
16 changes: 16 additions & 0 deletions event_contact/models/event_type.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Copyright 2016 OpenSynergy Indonesia
# Copyright 2017 Jairo Llopis <jairo.llopis@tecnativa.com>
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).

from odoo import fields, models


class EventType(models.Model):
_inherit = "event.type"

contact_ids = fields.Many2many(
string="Contacts",
comodel_name="res.partner",
help="Partners available to attend attendees requests by default for "
"events of this type.",
)
8 changes: 8 additions & 0 deletions event_contact/readme/CONTRIBUTORS.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
* Michael Viriyananda <viriyananda.michael@gmail.com>
* David Alonso <david.alonso@solvos.es>
* `Tecnativa <https://www.tecnativa.com>`__:

* Jairo Llopis
* Alexandre Díaz
* Ernesto Tejeda
* Eduardo López <elp@moduon.team>
3 changes: 3 additions & 0 deletions event_contact/readme/DESCRIPTION.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
This module adds the possibility to define contacts for the event.
Contacts are needed due to inform the people who should be contacted for
the event.
Loading
Loading