Browse Source

Merge remote-tracking branch 'origin/8.0' into 9.0-res_partner_mails_count-merge

pull/23/head
Ivan Yelizariev 9 years ago
parent
commit
033214c327
  1. 2
      mail_fix_553/README.rst
  2. 5
      mail_fix_553/data.xml
  3. 3
      mail_fix_553/mail_fix_553.py
  4. 2
      mail_sent/__openerp__.py
  5. 2
      res_partner_mails_count/static/src/js/res_partner_mails_count_tour.js

2
mail_fix_553/README.rst

@ -19,6 +19,8 @@ Configuration
You can configure default alias at Settings -> System Parameters -> mail.catchall.alias_from You can configure default alias at Settings -> System Parameters -> mail.catchall.alias_from
You can configure name for default alias at Settings -> System Parameters -> mail.catchall.name_alias_from
Known issues / Roadmap Known issues / Roadmap
====================== ======================

5
mail_fix_553/data.xml

@ -6,5 +6,10 @@
<field name="key">mail.catchall.alias_from</field> <field name="key">mail.catchall.alias_from</field>
<field name="value">portal</field> <field name="value">portal</field>
</record> </record>
<!-- Name for Catchall Email Alias -->
<record id="icp_mail_catchall_name_alias_from" model="ir.config_parameter">
<field name="key">mail.catchall.name_alias_from</field>
<field name="value">Odoo</field>
</record>
</data> </data>
</openerp> </openerp>

3
mail_fix_553/mail_fix_553.py

@ -38,6 +38,7 @@ class mail_mail(osv.Model):
# NEW STUFF # NEW STUFF
catchall_alias = self.pool['ir.config_parameter'].get_param(cr, uid, "mail.catchall.alias_from", context=context) catchall_alias = self.pool['ir.config_parameter'].get_param(cr, uid, "mail.catchall.alias_from", context=context)
catchall_alias_name = self.pool['ir.config_parameter'].get_param(cr, uid, "mail.catchall.name_alias_from", context=context)
catchall_domain = self.pool['ir.config_parameter'].get_param(cr, uid, "mail.catchall.domain", context=context) catchall_domain = self.pool['ir.config_parameter'].get_param(cr, uid, "mail.catchall.domain", context=context)
correct_email_from = '@%s>?\s*$'%catchall_domain correct_email_from = '@%s>?\s*$'%catchall_domain
@ -101,6 +102,8 @@ class mail_mail(osv.Model):
email_from = mail.email_from email_from = mail.email_from
if re.search(correct_email_from, email_from) is None: if re.search(correct_email_from, email_from) is None:
email_from = default_email_from email_from = default_email_from
if catchall_alias_name:
email_from = formataddr((catchall_alias_name, email_from))
msg = ir_mail_server.build_email( msg = ir_mail_server.build_email(
email_from=email_from, # NEW STUFF email_from=email_from, # NEW STUFF

2
mail_sent/__openerp__.py

@ -9,7 +9,7 @@
"author": "IT-Projects LLC, Ivan Yelizariev, Pavel Romanchenko", "author": "IT-Projects LLC, Ivan Yelizariev, Pavel Romanchenko",
"website": "https://it-projects.info", "website": "https://it-projects.info",
"license": "LGPL-3", "license": "LGPL-3",
'price': 9.00,
'price': 40.00,
'currency': 'EUR', 'currency': 'EUR',
"depends": [ "depends": [

2
res_partner_mails_count/static/src/js/res_partner_mails_count_tour.js

@ -8,7 +8,7 @@ odoo.define('res_partner_mails_count.res_partner_mails_count_tour', function (re
id: 'mails_count_tour', id: 'mails_count_tour',
name: _t("Mails count Tour"), name: _t("Mails count Tour"),
mode: 'test', mode: 'test',
path: '/web?&res_partner_mails_count=tutorial#id=3&view_type=form&model=res.partner',
path: '/web?res_partner_mails_count=tutorial#id=3&view_type=form&model=res.partner',
steps: [ steps: [
{ {
title: _t("Mails count tutorial"), title: _t("Mails count tutorial"),

Loading…
Cancel
Save