Skip to Content
Меню
Вам необхідно зареєструватися, щоб взаємодіяти зі спільнотою.
Це запитання позначене
1 Відповісти
4359 Переглядів

I need to change the name of the "Product name" field to "Description" of the products template in odoo v13. I don't want to do that name change from the odoo interface, but from a custom addon. And if it is possible to change the characteristics of the existing field from the custom addon.

Аватар
Відмінити
Найкраща відповідь

You can change the string attribute using a custom module you may use the below code for reference:


<xpath expr="//field[@name='reference_filed']" position="attributes">
    <attribute name="string">Your String Here</attribute>
</xpath>

. You may override the field as below:


class YourModel(models.Model):
    _inherit = 'your.model'

    reference_filed = fields.FieldType(string="Your String Here")
Аватар
Відмінити
Related Posts Відповіді Переглядів Дія
1
трав. 24
1147
1
черв. 21
2882
1
квіт. 21
1968
0
груд. 19
5381
1
лист. 19
4033