Purpose ======= An alert is sent when the vehicle contract will be outdated in less than a month. This could be a parameter than could be set on the res.config. Specification ============= Use ir.config.parameter in all the cases Default value is 30 days Consider 'diesoon' contract as an 'in progress' contract closes odoo/odoo#29704
11 lines
366 B
Python
11 lines
366 B
Python
# -*- coding: utf-8 -*-
|
|
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
|
|
|
from odoo import fields, models
|
|
|
|
|
|
class ResConfigSettings(models.TransientModel):
|
|
_inherit = ['res.config.settings']
|
|
|
|
delay_alert_contract = fields.Integer(string='Delay alert contract outdated', default=30, config_parameter='hr_fleet.delay_alert_contract')
|