[MIG] base_report_to_printer: Migration to 13.0

This commit is contained in:
Rod Schouteden
2019-09-30 12:13:42 +02:00
committed by Carlos Roca
parent 32352977ed
commit b1103c7b6d
20 changed files with 69 additions and 76 deletions

View File

@@ -2,7 +2,7 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
import logging
from odoo import models, fields, api
from odoo import models, fields
_logger = logging.getLogger(__name__)
@@ -85,12 +85,10 @@ class PrintingJob(models.Model):
'The id of the job must be unique per server !'),
]
@api.multi
def action_cancel(self):
self.ensure_one()
return self.cancel()
@api.multi
def cancel(self, purge_job=False):
for job in self:
connection = job.server_id._open_connection()