Hello,
I want to create two field for email adresses for my contacts and I want to erase the mobile field? How can I achieve that? I'm only using the contact app and helpdesk. Odoo 16
Thanks
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
Hello,
I want to create two field for email adresses for my contacts and I want to erase the mobile field? How can I achieve that? I'm only using the contact app and helpdesk. Odoo 16
Thanks
Hello,
Is there no easier way to do so because I'm not confortable with the XML.
Thanks for your response though
Hi,
Try like following code
class ResPartners(models.Model):
_inherit = 'res.partner'
email_test = fields.Char(string='Email Test')
In .xml
<odoo>
<record id="contact_email" model="ir.ui.view">
<field name="name">res.partner.form</field>
<field name="model">res.partner</field>
<field name="inherit_id" ref="base.view_partner_form"/>
<field name="arch" type="xml">
<xpath expr="//form/sheet/group/group/field[@name='email']" position="after">
<field name="email_test"/>
</xpath>
<xpath expr="//form/sheet/group/group/field[@name='phone']" position="attributes">
<attribute name="invisible">1</attribute>
</field>
</record>
</odoo>
Regards
Tạo tài khoản ngay hôm nay để tận hưởng các tính năng độc đáo và tham gia cộng đồng tuyệt vời của chúng tôi!
Đăng kýBài viết liên quan | Trả lời | Lượt xem | Hoạt động | |
---|---|---|---|---|
|
0
thg 3 24
|
1800 | ||
|
2
thg 7 25
|
1283 | ||
|
0
thg 2 25
|
1679 | ||
|
0
thg 1 25
|
1425 | ||
Field service upgrade
Đã xử lý
|
|
1
thg 12 24
|
1853 |