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

Hello,


On an order/invoice, i select a customer and at the shipping address it displays all of the contacts on record. I want to display only the contacts and addresses of the customer I've selected.


Thank you.

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

Gagea,

Step 1 : Set boolean field on res.partner model

example :

_inherit = 'res.partner'
is_shipping_contact = fields.Boolean("Is Shipping Contact?")
# Inherit partner view and add this boolean field

Step 2 :  Based on that boolean field use condition/ apply condition where you have a selection of customer field.

Apply this domain in the field, partner wherever you want to list the contacts/customers/partner which should be flagged with shipping.

This would be domain :


domain = "[('is_shipping_contact','=',True)]

Hope this will give you an idea, what needs to be done.


Rgds,

Anil.

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

Hello, i have the same issue, do you find a solution?

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

Hello,

In Contact Menu You will find One Page Contact&Address,

Click on Create Button And One Wizard Open Now, Create Address Using Boolean That which type of Address You Want to Create,

For Example

Click On Invoice address or

and Fill Details and save Then,
Go to Sales>

Configuration>Settings

Click On

Display 3 fields on sales orders: customer, invoice address, delivery address

Using This Configuration It'll Display Both Address On Order/Invoice.


Thanks


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

@Anil : I'm unable to reply to your comment, however, initially i added in studio on the res.contact model a boolean checkbox ( ex: is shipping contact) and on an invoice, at the shipping address I've added the exact domain  [('is_shipping_contact','=',True)] 

you provided. If i check the shipping box on 2 different companies( at the contact & addresses info ), it will give me in the invoice - shipping address, the contacts from both companies. I'm not exactly sure how to do it in studio to give it only from the selected customer...


@Pujara :  I have the option activated, in those address fields, i want to have only the contact and address of the customer i select. At the moment its displaying all of the contacts

Аватар
Відмінити
Related Posts Відповіді Переглядів Дія
1
жовт. 24
1270
2
вер. 24
1618
2
жовт. 23
2707
1
бер. 24
2781
2
лют. 24
7160