Live Chat
True
FAQs
Odoo Miscellaneous

How to use KPI digests?

  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)



Was this article helpful?

FAQ HOME

To install this Web App in your iPhone/iPad press and then Add to Home Screen.