1
0
forked from Mapan/odoo17e
odoo17e-kedaikipas58/addons/iot/models/update.py
2024-12-10 09:04:09 +07:00

16 lines
484 B
Python

# -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.
from odoo import api, models
class PublisherWarrantyContract(models.AbstractModel):
_inherit = "publisher_warranty.contract"
_description = 'Publisher Warranty Contract For IoT Box'
@api.model
def _get_message(self):
msg = super(PublisherWarrantyContract, self)._get_message()
msg['IoTBox'] = self.env['iot.box'].search_count([])
return msg