Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
1712 Lượt xem

Goodnight,

Create a customer with data that is needed for customer billing, additionally delivery addresses, contacts, private addresses were created. But I see that they appear when I look for a client in any document, be it a sales order, invoice, etc. there is some way to only see 1 customer and not the same customer list for each address, contact, etc.

I get problems if they mistakenly select a client that does not have the complete data.

observation:

The data of additional addresses, contacts, private addresses is created incomplete.

thanks,

Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

Hi, GiancaFTx


Yes, By default Odoo shows all the address and contact inside the sale order, invoice, picking. As doesn't restrict user to add address as partner.


So, if you only wants to show exact customer then you need to add domain,

 "domain="[('child_ids','!=',False)]""

inside the partner_id field like below, 

Kindly inherit Order, Invoice and Picking form and replace "partner_id" line with the below line,

<field name="partner_id" widget="res_partner_many2one" context="{'res_partner_search_mode': 'customer', 'show_address': 1, 'show_vat': True}" options="{&quot;always_reload&quot;: True}" domain="[('child_ids','!=',False)]"/> 

Then after adding domain you will only see the partner inside the customer section,

https://prnt.sc/rmae8y 

Hope above points are clear to you feel free to ask in case you have any doubt related to above point.

Thanks,
Ashish Singh (Team Lead)
Webkul Software Private Limited
Ảnh đại diện
Huỷ bỏ