diff options
| author | Rémi Rahir <rar@odoo.com> | 2018-04-23 16:04:43 +0200 |
|---|---|---|
| committer | Rémi Rahir <rar@odoo.com> | 2018-07-19 15:54:00 +0200 |
| commit | 4cb91942751130f003a5c2a8dce545a7cd877bee (patch) | |
| tree | a13bd21c5056a2bb4c00420096899ce416d3299c /addons/account/models | |
| parent | 01efffc472760d717953e6659ad84323094cea8e (diff) | |
[ADD] snailmail: new iap module to send letters by post
Diffstat (limited to 'addons/account/models')
| -rw-r--r-- | addons/account/models/__init__.py | 1 | ||||
| -rw-r--r-- | addons/account/models/account_invoice.py | 4 | ||||
| -rw-r--r-- | addons/account/models/res_company.py | 11 |
3 files changed, 14 insertions, 2 deletions
diff --git a/addons/account/models/__init__.py b/addons/account/models/__init__.py index 95d9fcbf996..3865c09ee2d 100644 --- a/addons/account/models/__init__.py +++ b/addons/account/models/__init__.py @@ -16,3 +16,4 @@ from . import res_config_settings from . import account_cash_rounding from . import reconciliation_widget from . import res_users +from . import res_company diff --git a/addons/account/models/account_invoice.py b/addons/account/models/account_invoice.py index 9b8afa4791c..980a6e92adc 100644 --- a/addons/account/models/account_invoice.py +++ b/addons/account/models/account_invoice.py @@ -593,7 +593,7 @@ class AccountInvoice(models.Model): """ self.ensure_one() template = self.env.ref('account.email_template_edi_invoice', False) - compose_form = self.env.ref('mail.email_compose_message_wizard_form', False) + compose_form = self.env.ref('account.multi_compose_message_wizard_form', False) ctx = dict( default_model='account.invoice', default_res_id=self.id, @@ -609,7 +609,7 @@ class AccountInvoice(models.Model): 'type': 'ir.actions.act_window', 'view_type': 'form', 'view_mode': 'form', - 'res_model': 'mail.compose.message', + 'res_model': 'multi.compose.message', 'views': [(compose_form.id, 'form')], 'view_id': compose_form.id, 'target': 'new', diff --git a/addons/account/models/res_company.py b/addons/account/models/res_company.py new file mode 100644 index 00000000000..522bd956fc3 --- /dev/null +++ b/addons/account/models/res_company.py @@ -0,0 +1,11 @@ +# -*- coding: utf-8 -*- +# Part of Odoo. See LICENSE file for full copyright and licensing details. + +from odoo import fields, models + + +class ResCompany(models.Model): + _inherit = 'res.company' + + is_email = fields.Boolean('Email by default', default=True) + is_print = fields.Boolean('Print by default', default=True) |
