Hi all,
i'm trying to combine few custom fields to form product name in tree view. This is my code in py file
prod_name = fields.Char(compute="full_product_name", string="Product Name - CUSTOM")
def full_product_name(self):
for rec in self:
rec.prod_name = rec.name + " " + rec.tension
The problem is I get error
"TypeError: can only concatenate str (not "product.template.tension") to str"
Field "tension" is of type Manytoone
How can I get value from this field to concatenate with my rec.name? Thank you!
Thank you Niyas,
I just had to add .name -> it's actually defined in class. I inherited this project and I'm real newbie in Odoo so I'm trying to figure it out :)