# CR

**URL:** <https://community.hubspot.com/t/cr/68288>\
**Category:** APIs & Integrations\
**Tags:** enterprise\
**Created:** [November 1, 2022, 9:54am UTC](https://community.hubspot.com/t/cr/68288 "2022-11-01T09:54:46Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jun22](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jun22/32/34870_2.png) [@Jun22](https://community.hubspot.com/u/Jun22)\
**Post date:** [November 1, 2022, 9:54am UTC](https://community.hubspot.com/t/cr/68288/1 "2022-11-01T09:54:46Z")

</div>

Hi Loads,  
Anyone out there has a good heart to share some tips how to “Get a contact’s associated deals and Get contact’s associated company deals”

Right now I am able to display my own deals, I need to display including the company deals associated with my contact.  
Here’s my code for getting my own deal: Please let me know if you know how to make it work. thanks

```lia-code-sample
{% set associated_deals = crm_associations(request.contact.contact_vid, 'HUBSPOT_DEFINED', 4, 'dealname,amount,dealstage,createdate,closedate') %}

<div class="profile">
<p>Full Name: {{ membership_contact.firstname }} {{ membership_contact.lastname }}</p>
</div>
<div class="deals">
{% for deal in associated_deals.results %}
{% set membership_contact = crm_object('contact', request.contact.contact_vid, 'firstname,lastname') %}
<div class="deal">
<p>Deal name: {{ deal.dealname }}</p>
<p>Amount: {{ deal.amount }}</p>

{% if deal.dealstage == "1a4e48ef-e214-468c-9d51-fe5547933286"%}
<p>Prospecting</p>
{% elif deal.dealstage == "72c0e000-d43b-4ed9-a762-fd59723134bc"%}
<p>Qualifying</p>
{% elif deal.dealstage == "79795644-3df1-4060-afbe-560f26a8aaad"%}
<p>Developing Solution</p>
{% elif deal.dealstage == "3e872ef2-3101-4dbf-a85e-417396969466"%}
<p>Negotiating</p>
{% elif deal.dealstage == "0a14ba1e-dacd-4ce5-8ddf-ead56613e16b"%}
<p>Won</p>
{% else %}
<p>
{{deals.dealstage}}
</p>
{% endif %}
<p> Dealowner: {{ membership_contact.firstname }} {{ membership_contact.lastname }}</p>
<p> created: {{ deal.createdate }}</p>
<p> close: {{ deal.closedate }}</p>
</div>
{% endfor %}
</div>

```

Can someone edit to get my Company Deals associated with my contact . THanks loads

---

<div class="post-metadata">

**Author:** ![Jaycee\_Lewis](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jaycee_lewis/32/61352_2.png) [@Jaycee\_Lewis](https://community.hubspot.com/u/Jaycee_Lewis)\
**Post date:** [November 3, 2022, 10:37pm UTC](https://community.hubspot.com/t/cr/68288/2 "2022-11-03T22:37:43Z")

</div>

Hi, @Jun22 👋 Thanks for reaching out and including those details. Hey, @Anton [@Phil\_Vallender](https://community.hubspot.com/t5/user/viewprofilepage/user-id/74) @Sjardo, do you have any tips you can share with @Jun22?

Thank you very much! — Jaycee
