Skip to Content
Menu
This question has been flagged
1 Reply
8893 Views

In the Odoo 12 release notes in section Usability, there is a section

Email Digest

Get KPIs sent by email periodically according to your preferences: new leads, opportunities won, revenues,  cash, tickets closed, open tasks, etc.

However I have not been able to find any information about how - and where - it is configured on this site.

So for anyone who is in the same situation and finds this via search:

The module is named "digest" and only shows up under Apps when the filter "Apps" is closed. You have to enable debug mode to find anything useful in the module information, like where the menu is created (but then, you have to enable debug anyway to access that menu):  Settings/Technical/Email/Digest Email, in German Einstellungen>Technisch>E-Mail>Übersicht E-Mails (I've suggested "E-Mail-Digests" at transifex because the current translation is really misleading and translates back to "E-Mail Overview" which is something entirely different).

Best regards,

mow


Avatar
Discard
Best Answer

There is a simple explanation in the Digest Emails.


  1. Enabled Debug Mode

  2. From the Top Nav bar in the right Select 'Technical > Email > Digest Email'

  3. Press 'CREATE'

  4. in the New Tab press 'How to Customize your digest?, Here below is what reports.


-------------------------

In order to build your customized digest, follow these steps:

  1. You may want to add new computed fields with Odoo Studio:
    • you must create 2 fields on the digest object:
    • first create a boolean field called kpi_myfield and display it in the KPI's tab;
    • then create a computed field called kpi_myfield_value that will compute your customized KPI.
  2. Select your KPIs in the KPI's tab.
  3. Create or edit the mail template: you may get computed KPI's value using these fields:

-------------------------

The Digest Module is found in 'odoo > Addons > Digest'.

From that Folder you can find a template: 'Views > digest_templates.xml'

From 'Models > digest.py' you will find function:

def _action_send_to_user()


With the following dictionary:

 
        mail_values = {
            'subject': '%s%s' % (user.company_id.name, self.name),
            'email_from': self.company_id.partner_id.email_formatted if self.company_id else self.env.user.email_formatted,
            'email_to': user.email_formatted,
            'body_html': full_mail,
            'auto_delete': True,
        }
        mail = self.env['mail.mail'].sudo().create(mail_values)
        mail.send(raise_exception=False)





Avatar
Discard
Related Posts Replies Views Activity
1
Mar 20
8444
1
Jul 23
1328
0
May 23
1492
3
Apr 23
18826
1
Nov 22
861