Repository
OCA/l10n-italy · module folder · Try on Runboat
Module version
1.0
Category
Certified Mailing
Folder size
0.35 MB
License
AGPL-3
Application
No
Auto-installable
No
Website
http://www.agilebg.com
Last tracking update
2026-08-07 06:56:11
Authors
Odoo Community Association (OCA), Agile Business Group
Maintainers
Odoo Community Association (OCA), Agile Business Group
Committers
eLBati, Lorenzo Battistini, Stéphane Bidoul (ACSONE), OCA Transbot, archetipo, zeroincombenze, thinkstudio, angedras, Alessio Gerace
Odoo dependencies
OCA/l10n-italy:
odoo/odoo:
- web
Python dependencies
None
System dependencies
None
Required by
None
Description
Pec Messages Management
-----------------------

This module allows to correctly parse PEC messages.
According to 'daticert.xml' file, it identifies the message type and other
message data.
'consegna', 'accettazione' and the other notification messages are linked to
the original message that originated them.
It also correctly parses the mail attachments and attaches the original 'eml'
PEC message.
The module adds a 'PEC' menu where to handle PEC messages.


Configuration
-------------

Create a new user associated to the PEC mailbox.
Set 'Never' for 'Receive Messages by Email'.
Configure the fetchmail server (incoming mail server, IMAP or POP)
used to fetch PEC messages and set it as 'PEC'.
Set the users allowed to use that server.
Configure the 'outgoing mail server' (SMTP) used for PEC and set it as 'PEC'.
Link the outgoing mail server to the 'incoming PEC server'.
Add your user to 'PEC reader' group.


Contributors
------------

 - Alessio Gerace <alessio.gerace@gmail.com>
 - Lorenzo Battistini <lorenzo.battistini@agilebg.com>
 - Roberto Onnis <roberto.onnis@innoviu.com>

Code Analysis

Views touched (9)
XML IDNameModelTypeStatus
email_compose_message_wizard_form_pec mail.compose.message.form.pec mail.compose.message form New
ir_mail_server_form_pec ir.mail_server.form.pec ir.mail_server form Inherits base.ir_mail_server_form
message_pec_form message.pec.form mail.message form New
message_pec_partner_tree res.partner.pec.tree res.partner tree New
message_pec_tree message.pec.tree mail.message tree New
pec_message_search_view message.search.form mail.message search New
view_document_file_protocol_form_pec fetchmail.server.form.pec fetchmail.server form Inherits fetchmail.view_email_server_form
view_message_form_pec mail.message.form.pec mail.message form Inherits mail.view_message_form
view_user_form_pec res.users.form.pec res.users form Inherits base.view_users_form
HTTP endpoints (0)

No HTTP endpoints found for this module.

Models touched (9)

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (0)

No new fields.

Public methods (2)
  • get_message_data(self, cr, uid, message_id, context=None)
  • send_mail(self, cr, uid, ids, context=None)
    Override of send_mail to duplicate attachments linked to the email.template. Indeed, basic mail.compose.message wizard duplicates attachments in mass mailing mode. But in 'single post' mode, attachments of an email template also have to be duplicated to avoid changing their ownership.

New fields (0)

No new fields.

Public methods (3)
  • create(self, cr, uid, values, context=None)
    when replying to a PEC message, or sending a new PEC message, use the linked SMTP server and SMTP user
  • send(self, cr, uid, ids, auto_commit=False, recipient_ids=None, context=None)
  • send_get_email_dict(self, cr, uid, mail, partner=None, context=None)

New fields (0)

No new fields.

Public methods (2)
  • CheckNotificationStatus(self, cr, uid, ids, context=None)
  • check_access_rule(self, cr, uid, ids, operation, context=None)

New fields (0)

No new fields.

Public methods (1)
  • get_partners_to_notify(self, cr, uid, message, partners_to_notify=None, context=None)
    this allows to send PEC mail to partners without standard email

New fields (0)

No new fields.

Public methods (4)
  • force_create_partner(self, cr, uid, context=None)
  • is_server_pec(self, cr, uid, context=None)
  • message_parse(self, cr, uid, message, save_original=False, context=None)
  • parse_daticert(self, cr, uid, daticert, context=None)

New fields (0)

No new fields.

Public methods (2)
  • message_post(self, cr, uid, thread_id, body='', subject=None, type='notification', subtype=None, parent_id=False, attachments=None, context=None, content_subtype='html', **kwargs)
    if pec_type is accettazione and non-accettazione link message as reception type in parent message if pec_type is avvenuta-consegna errore-consegna rilevazione-virus link message as delivery type in parent message if pec_type is error type like: non-accettazione errore-consegna rilevazione-virus marks parent message with error flag
  • name_get(self, cr, uid, ids, context=None)

New fields (0)

No new fields.

Public methods (0)

No public methods.