14 lines
392 B
Python
14 lines
392 B
Python
|
# -*- coding: utf-8 -*-
|
||
|
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||
|
|
||
|
from odoo import models
|
||
|
|
||
|
|
||
|
class SaleOrder(models.Model):
|
||
|
_inherit = 'sale.order'
|
||
|
_mailing_enabled = True
|
||
|
|
||
|
def _mailing_get_default_domain(self, mailing):
|
||
|
""" Exclude by default canceled orders when performing a mass mailing. """
|
||
|
return [('state', '!=', 'cancel')]
|