[MIG] mail_tracking_mailgun: Migrated to 10.0
This commit is contained in:
parent
9adb6bd763
commit
24e5044065
@ -4,14 +4,14 @@
|
|||||||
{
|
{
|
||||||
"name": "Mail tracking for Mailgun",
|
"name": "Mail tracking for Mailgun",
|
||||||
"summary": "Mail tracking and Mailgun webhooks integration",
|
"summary": "Mail tracking and Mailgun webhooks integration",
|
||||||
"version": "9.0.1.0.0",
|
"version": "10.0.1.0.0",
|
||||||
"category": "Social Network",
|
"category": "Social Network",
|
||||||
"website": "https://odoo-community.org/",
|
"website": "https://odoo-community.org/",
|
||||||
"author": "Tecnativa, "
|
"author": "Tecnativa, "
|
||||||
"Odoo Community Association (OCA)",
|
"Odoo Community Association (OCA)",
|
||||||
"license": "AGPL-3",
|
"license": "AGPL-3",
|
||||||
"application": False,
|
"application": False,
|
||||||
'installable': False,
|
'installable': True,
|
||||||
"depends": [
|
"depends": [
|
||||||
"mail_tracking",
|
"mail_tracking",
|
||||||
],
|
],
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
||||||
|
|
||||||
import json
|
import json
|
||||||
from openerp import models
|
from odoo import models
|
||||||
|
|
||||||
|
|
||||||
class IrMailServer(models.Model):
|
class IrMailServer(models.Model):
|
||||||
@ -14,9 +14,7 @@ class IrMailServer(models.Model):
|
|||||||
tracking_email_id, headers)
|
tracking_email_id, headers)
|
||||||
headers = headers or {}
|
headers = headers or {}
|
||||||
metadata = {
|
metadata = {
|
||||||
# NOTE: We can not use 'self.env.cr.dbname' because self is
|
'odoo_db': self.env.cr.dbname,
|
||||||
# ir.mail_server object in old API (osv.osv)
|
|
||||||
'odoo_db': self.pool.db_name,
|
|
||||||
'tracking_email_id': tracking_email_id,
|
'tracking_email_id': tracking_email_id,
|
||||||
}
|
}
|
||||||
headers['X-Mailgun-Variables'] = json.dumps(metadata)
|
headers['X-Mailgun-Variables'] = json.dumps(metadata)
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
import hashlib
|
import hashlib
|
||||||
import hmac
|
import hmac
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
from openerp import models, api, fields
|
from odoo import models, api, fields
|
||||||
|
|
||||||
import logging
|
import logging
|
||||||
_logger = logging.getLogger(__name__)
|
_logger = logging.getLogger(__name__)
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
# Copyright 2016 Antonio Espinosa - <antonio.espinosa@tecnativa.com>
|
# Copyright 2016 Antonio Espinosa - <antonio.espinosa@tecnativa.com>
|
||||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
|
||||||
|
|
||||||
from openerp.tests.common import TransactionCase
|
from odoo.tests.common import TransactionCase
|
||||||
|
|
||||||
|
|
||||||
class TestMailgun(TransactionCase):
|
class TestMailgun(TransactionCase):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user