Zum Inhalt springen
Menü
Sie müssen registriert sein, um mit der Community zu interagieren.
Diese Frage wurde gekennzeichnet
3 Antworten
2090 Ansichten

I have many2one field with relation to res.partner

The current setting is to return partner  address after selecting partner and i have plan to add the phone number also. How can i do that?


The current code is :


....field name="x_partner" invisible="maintenance_team_id not in []" context="{'res_partner_search_mode': 'customer', 'show_address': 1}"/...

Avatar
Verwerfen
Beste Antwort

Hi Rickey Raymond,

You can add new field mobile_number in sale order (using odoo studio or code through) and

Then then based on this field add Onchange method.

so when you select partner instead of that partner mobile_number auto fill.

 

Thanks.

Avatar
Verwerfen
Beste Antwort

 HI  Ricky Raymond


You can add new field below of your many2one field and then 

You can achieve your result by two Ways.

  1. Onchange method 
  2. Related Field 


  • You can do this by Onchange method like below,

        First add new field mobile into your py file.



  • you can do this by Related field like below,




After this put this field into your xml file after your many2one field.



 I hope this is helpful to you.


 Thanks & Regards,

 Email: odoo@devintellecs.com

 Skype: devintelle




Avatar
Verwerfen
Autor Beste Antwort

Thanks bro. It works.

Avatar
Verwerfen
Verknüpfte Beiträge Antworten Ansichten Aktivität
0
Juni 24
2230
0
Juni 24
3
0
März 21
3479
1
Juli 24
3370
0
Mai 24
1795