# Sales Order to include "Customer shipping contact" and "Customer invoice contact"

**URL:** <https://www.dolibarr.org/forum/t/sales-order-to-include-customer-shipping-contact-and-customer-invoice-contact/29411>\
**Category:** Using my Dolibarr\
**Tags:** v19, Question, Help, Issue\
**Created:** [September 25, 2024, 9:20pm UTC](https://www.dolibarr.org/forum/t/sales-order-to-include-customer-shipping-contact-and-customer-invoice-contact/29411 "2024-09-25T21:20:49Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![jh482002](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/j/8e7dd6/32.png) [@jh482002](https://www.dolibarr.org/forum/u/jh482002)\
**Post date:** [September 25, 2024, 9:20pm UTC](https://www.dolibarr.org/forum/t/sales-order-to-include-customer-shipping-contact-and-customer-invoice-contact/29411/1 "2024-09-25T21:20:50Z")

</div>

How can I include the “Customer shipping contact” and “Customer invoice contact” on Sales Order?

---

<div class="post-metadata">

**Author:** ![jh482002](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/j/8e7dd6/32.png) [@jh482002](https://www.dolibarr.org/forum/u/jh482002)\
**Post date:** [September 26, 2024, 7:55pm UTC](https://www.dolibarr.org/forum/t/sales-order-to-include-customer-shipping-contact-and-customer-invoice-contact/29411/2 "2024-09-26T19:55:29Z")

</div>

Can anyone help me to compute a Contact Address? I think that’s the key.

Thanks

---

<div class="post-metadata">

**Author:** ![jonbendtsen](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/j/977dab/32.png) [@jonbendtsen](https://www.dolibarr.org/forum/u/jonbendtsen)\
**Post date:** [September 27, 2024, 5:43am UTC](https://www.dolibarr.org/forum/t/sales-order-to-include-customer-shipping-contact-and-customer-invoice-contact/29411/3 "2024-09-27T05:43:48Z")

</div>

In the GUI or API?

Here are 2 pictures from 18.0.5, the big one is from Contacts on a Proposal, and the small one is the Contact roles that one can choose.

 ![proposal_contacts](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/9/91cb600920ad5406d543e618a6c4c01c3f34525f.jpeg)  
 ![contact_role](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/b/b91ca801d24c142e0db39aa926a00f5941ab3491.png)

This last picture is from Home, Setup, Dictionaries, Contact/Address types where I have defined those extra Contact roles.

The LEAD, FOLLOW and PARTNER is a leftover from an experiment I did in my Dance Class Registration system

 ![dictionary_proposal_contact_roles](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/8/82b74bebf135ca32ec16f7822e9e912f4383bdcb.png)

---

<div class="post-metadata">

**Author:** ![jh482002](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/j/8e7dd6/32.png) [@jh482002](https://www.dolibarr.org/forum/u/jh482002)\
**Post date:** [September 27, 2024, 4:15pm UTC](https://www.dolibarr.org/forum/t/sales-order-to-include-customer-shipping-contact-and-customer-invoice-contact/29411/4 "2024-09-27T16:15:36Z")

</div>

@jonbendtsen  
Thank you for your reply. Yes, I see the Contacts/Addresses tab and I’ve made some selections. The problem I’m having is… How do I get a Contact (& their address) to show up on a Sales Order (pdf)?

FYI, I’ve been preparing templates in the .ODT style for now, to give me more control of appearances. To that end, I would need a final ‘tag’ to link to my template(s).

Much appreciated!

---

<div class="post-metadata">

**Author:** ![jonbendtsen](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/j/977dab/32.png) [@jonbendtsen](https://www.dolibarr.org/forum/u/jonbendtsen)\
**Post date:** [September 27, 2024, 4:31pm UTC](https://www.dolibarr.org/forum/t/sales-order-to-include-customer-shipping-contact-and-customer-invoice-contact/29411/5 "2024-09-27T16:31:51Z")

</div>

> [@jh482002](#):
>
> The problem I’m having is… How do I get a Contact (& their address) to show up on a Sales Order (pdf)?

I’m afraid I do not know, I do not use this functionality.

But I have noticed that I can set different kinds of contacts on proposals than on orders.

---

<div class="post-metadata">

**Author:** ![jh482002](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/j/8e7dd6/32.png) [@jh482002](https://www.dolibarr.org/forum/u/jh482002)\
**Post date:** [September 27, 2024, 4:57pm UTC](https://www.dolibarr.org/forum/t/sales-order-to-include-customer-shipping-contact-and-customer-invoice-contact/29411/6 "2024-09-27T16:57:25Z")

</div>

There must be a way to load Contact Addresses (perhaps through a Computed Field). From there its not that hard with …options… tag.

Help!!!

---

<div class="post-metadata">

**Author:** ![jh482002](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/j/8e7dd6/32.png) [@jh482002](https://www.dolibarr.org/forum/u/jh482002)\
**Post date:** [October 1, 2024, 2:31pm UTC](https://www.dolibarr.org/forum/t/sales-order-to-include-customer-shipping-contact-and-customer-invoice-contact/29411/7 "2024-10-01T14:31:16Z")

</div>

OK. Having trouble ‘computing’ address. I have come up with the following formula that results in nothing:

(($reloadedobj = new socpeople($db)) && ($reloadedobj-\>fetch(8) \> 0)) ? $reloadedobj-\>address : ‘not found’

I’m trying to simply compute the ‘address’ field for record 8 in the Contacts table. Why does it not work?

 ![image](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/2/2886b78eec61177e92f0882a37876264513bf0a7.png)
