summaryrefslogtreecommitdiff
path: root/addons/mass_mailing/models/mail_thread.py
AgeCommit message (Collapse)Author
2018-10-05[FIX] mail, mass_mailing: remove implicit dependency on mass_mailinglen-odoo
Fix to commit: a1d6064dcc6d349c02556453e1aa052e60db41c0 Which erroneously put a mass_mailing method in mail, as mail.mail.statistics is defined in mass_mailing. Since it does not depend on the records, it been extracted from the loop. opw 1890461 closes odoo/odoo#27431
2018-08-14[MERGE] forward port branch saas-11.4 up to dabe59df9c8Christophe Simonis
2018-08-13[FIX] mass_mailing: bounced statisticsNicolas Martinelli
A mass mailing can be considered both as bounced and opened. This can occur with some email providers, such as Gmail. Indeed, Gmail sends out-of-office replies to the `Return-Path` address, which is also used for bounced emails. Therefore, it is not possible to determine accurately if a message sent to to the `Return-Path` is a genuine bounced email, or an out-of-office reply. However, if the recipient opens the email, it is possible to determine that the bounce was counted incorrectly. In this case, we empty the `bounced` field. Similarly, we only write on the `bounced` filed if the `opened` field is empty. This could occur if the recipient opens the email before the out-of-office reply is received. As a bonus, we also make sure to avoid updating the status if no route was found. No route means that the email was bounced, so no reason to set it as opened. opw-1869957
2018-08-10[IMP] mass_mailing : include invalid emails into ignored stateDavid Beguin
If the email is invalid (incorrect pattern), the mailing status is set to canceled and will be flaged as ignored in the mail.mail.statistics
2018-08-10[IMP] mail : auto-blacklist rule when too much email bouncedDavid Beguin
In order to avoid sending mail indefinitely to a wrong email address, Take the mail statistics for the recipient of the last 3 month : if more than 5 mails bounced (with interval of more than 1 week) the email is blacklisted.
2017-09-15[IMP] mass_mailing: consider replying to an email imply opening itThibault Delavallée
Currently when people answers an email its statistics are set to replied updating its replied field. However if the blank gif used to track the opening fails for whatever reason we could have mail considered as replies but not opened. We consider that it is not common to reply to an email people did not open. Let us therefore set a replied email as also opened.
2017-07-19[MERGE] forward port branch 10.0 up to 11270336fa7Christophe Simonis
2017-07-18[FIX] mass_mailing: avoid creating mass mailing for messages postsChristophe Simonis
In case a default value is set for the field `mass_mailing_name` of the mail composer, the automatic messages sent via message_post_with_* are considered as a mass mailing. It may also create an AccessError if the current user is not a mass mailing user. In the case of the "assign user" email (for auto-subscribed users), the url wasn't shorten, which resulted in invalid links (opw-752941) (fixed by 3228694bddff75a9c04504f09b6da56c5f5a5647)
2017-01-03[IMP] base, *: tighten `ir.config_parameter` access rightsRaphael Collet
Add `base.group_system` on existing parameters: - `auth_signup.allow_uninvited`, - `auth_signup.reset_password`, - `auth_signup.template_user_id`, - `google_redirect_uri`, - `mail.bounce.alias`, - `mail.catchall.alias`, - `mail.catchall.domain`.
2016-09-01[IMP] mail: bounce managementThibault Delavallée
Handle bounces using bounce alias directly in mailgateway. Previously bounces were used only in mass mailing to update campaign statistics. Now the mailgateway tries to find data from standard delivery status emails. This data is used to update state of emails sent to customers, to display it in the Chatter. It is also used to increment the message_bounce counter on the bounced partner and bounced record, if any and if the field exists. Previous more generic code that detect bounces is kept. This code is more specific to standard delivery failure notifications by parsing its content.
2016-09-01[FIX][IMP] mail, mass_mailing: improve making of Return-Path aliasThibault Delavallée
Previously Return-Path were composed using bounce_alias-<mail_id>-<model>- <thread_id> . However this may lead to return adresses not supported by the incoming mail server. We now form the bounce alias using bounce_alis+ <mail_id>-<model>-<thread_id>. Using a + indicates that the right part of the address is for information and used to manage the bounce. Only the left part is used for the email routing, allowing the return email to effectively land in the alias mailbox.
2016-09-01[CLEAN] mail, tools: factorize decode email toolsThibault Delavallée
mail.mail and mail.thread have methods to decode headers. This commit move them in mail tools. It is indeed simplier to have all email tools in the same file. Moreover they have been renamed to avoid confusion with standard library methods: decode and decode_header already exist. * decode in mail_message is now decode_smtp_header * decode_header in mail_thread is now decode_message_header A method to data from references is also moved into tools. A regex was already defined in tools. Now the method using it is already put in tools. Mailgateway will now simply call this method.
2016-08-09[MIG] mass_mailing: Remaining self.pool in 'message_route_check_bounce'Yannick Tivisse
2016-06-17[MIG] mass_mailing: code migration to new apiKeyur Gajjar
NB: A controller in website_mass_mailing has been migrated too. It's not a real issue as this module will also be migrated in the days to come
2015-10-26[MERGE] forward port of branch saas-6 up to ↵Denis Ledoux
20dba161d022f8c818f1ab4800b5631c75afc2a4
2015-10-06[FIX] mass_mailing: Check if bounce_alias is not NoneDanimar Ribeiro
If the parameter mail.bounce.alias is not found
2015-06-02[LEGAL] Use global LICENSE/COPYRIGHT files, remove boilerplate textOlivier Dony
- Preserved explicit 3rd-party copyright notices - Explicit boilerplate should not be necessary - copyright law applies automatically in all countries thanks to Berne Convention + WTO rules, and a reference to the applicable license is clear enough.
2015-04-27[MOV] mail: moved files according to the new module organizationThibault Delavallée
2014-11-04[IMP] use model._fields instead of model._all_columns to cover all fieldsRaphael Collet
The old-api model._all_columns contains information about model._columns and inherited columns. This dictionary is missing new-api computed non-stored fields, and the new field objects provide a more readable api... This commit contains the following changes: - adapt several methods of BaseModel to use fields instead of columns and _all_columns - copy all semantic-free attributes of related fields from their source - add attribute 'group_operator' on integer and float fields - base, base_action_rule, crm, edi, hr, mail, mass_mailing, pad, payment_acquirer, share, website, website_crm, website_mail: simply use _fields instead of _all_columns - base, decimal_precision, website: adapt qweb rendering methods to use fields instead of columns
2014-08-11[FIX] mail: fixed bounce email recognition + invite email headers + mass ↵Thibault Delavallée
mailing statistics not lost anymore - [FIX] bounce regex: too many emails were considered as bounce and therefore not displayed in the chatter and lost for the communication history. The regex was not correctly looking for the bounce alias in the email_to. - [FIX] invite email: replying to the invitation email (invitation as new follower) now replies to the user sending the invitation. - [FIX] mass_mailing: added a column to store the id of the original email in addition to the many2one column. The many2one is set to null when deleting the original email. As the information is necessary, it is saved on another field. The many2one is necessary for indexes purpose as the inverse of a one2many.
2014-04-16[MERGE] Sync with trunkThibault Delavallée
bzr revid: tde@openerp.com-20140416082925-eph1x8vnwj6o31rt
2014-03-17[REF] mass_mailing: moved files in models/data/views directories.Thibault Delavallée
bzr revid: tde@openerp.com-20140317143231-4jp3egoqvolenwxs