Hi to all
I build a custom app within I try to calculate a Date from an other one and an Int.
# Odoo saas~15.2+e (Enterprise Edition)
for record in self :
d = datetime.date(record['x_studio_dde'].year,record['x_studio_dde'].month,record['x_studio_dde'].day)
record['x_studio_dfe'] = d + datetime.timedelta(days = (record['x_studio_dure'] * 30))
On existing records, it works then Odoo sends me the following error
Traceback (most recent call last): File "/home/odoo/src/odoo/saas-15.2/odoo/tools/safe_eval.py", line 330, in safe_eval return unsafe_eval(c, globals_dict, locals_dict) File "", line 2, in AttributeError: 'bool' object has no attribute 'year'
If I change the root date... it works without error
If I change the Int value... error
If i remove all existing records and create a new first one.... error
Any idea ? Thanks in advance
Regards