<commit_before>{% set translationDomain = "client-profile" %}
{% trans_default_domain translationDomain %}
{% set page = "clientContacts" %}
{% set client = report.client %}

<details class="panel panel-admin hard behat-region-client-profile-contacts">

    <summary class="panel-heading flush--bottom">
        <span class="summary heading-medium">{{ (page ~ '.heading') | trans }}</span>
    </summary>

    <div class="panel-body soft-half">

        {% if is_granted('add-client-contact', client) %}
        <a href="{{ path('clientcontact_add', {'clientId': report.client.id}) }}" class="bold-small action-link right behat-link-add-contact-button">
            <span class="icon icon-plus"></span>
            {{ (page ~ '.addContact') | trans }}
        </a>
        {% endif %}

        {% if contacts is not empty %}

            <table>
                <thead>
                    <th>{{ (page ~ '.contactName') | trans }}</th>
                    <th>{{ (page ~ '.organisation') | trans }}</th>
                    <th>{{ (page ~ '.contactInfo') | trans }}</th>
                    <th><span class="visually-hidden">Actions</span></th>
                </thead>

                <tbody>
                 {% for contact in contacts %}
                     <tr class="align--top dont-break-out">
                        <td class="width-quarter behat-region-client-profile-contacts-display-contact">
                            <dl>
                                <dt class="visually-hidden">{{ 'name' | trans({}, 'common') }}</dt>
                                <dd>
                                    <strong>{{ contact.firstName }} {{ contact.lastName }}</strong>
                                </dd>
                                {% if contact.jobTitle != "" %}
                                    <dt class="visually-hidden">{{ 'role' | trans({}, 'common') }}</dt>
                                    <dd>{{ contact.jobTitle }}</dd>
                                {% endif %}
                            </dl>
                        </td>
                        <td class="width-third behat-region-client-profile-contacts-display-organisation">
                            {% if
                                contact.orgName == "" and
                                contact.address1 == "" and
                                contact.address2 == "" and
                                contact.address3 == "" and
                                contact.addressPostcode == "" and
                                contact.addressCountry == ""
                            %}
                                -
                            {% else %}
                                <dl>
                                    <dt class="visually-hidden">{{ 'address' | trans({}, 'common') }}</dt>
                                    <dd>
                                        {% if contact.orgName %}
                                            {{ contact.orgName }}<br/>
                                        {% endif %}
                                        {% if contact.address1 %}
                                            {{ contact.address1 }}<br/>
                                        {% endif %}
                                        {% if contact.address2 %}
                                            {{ contact.address2 }}<br/>
                                        {% endif %}
                                        {% if contact.address3 %}
                                            {{ contact.address3 }}<br/>
                                        {% endif %}
                                        {% if contact.addressPostcode %}
                                            {{ contact.addressPostcode }}<br/>
                                        {% endif %}
                                        {% if contact.addressCountry %}
                                            {{ contact.addressCountry }}
                                        {% endif %}
                                    </dd><commit_msg>DDPB-801 Display full country name<commit_after>{% set translationDomain = "client-profile" %}
{% trans_default_domain translationDomain %}
{% set page = "clientContacts" %}
{% set client = report.client %}

<details class="panel panel-admin hard behat-region-client-profile-contacts">

    <summary class="panel-heading flush--bottom">
        <span class="summary heading-medium">{{ (page ~ '.heading') | trans }}</span>
    </summary>

    <div class="panel-body soft-half">

        {% if is_granted('add-client-contact', client) %}
        <a href="{{ path('clientcontact_add', {'clientId': report.client.id}) }}" class="bold-small action-link right behat-link-add-contact-button">
            <span class="icon icon-plus"></span>
            {{ (page ~ '.addContact') | trans }}
        </a>
        {% endif %}

        {% if contacts is not empty %}

            <table>
                <thead>
                    <th>{{ (page ~ '.contactName') | trans }}</th>
                    <th>{{ (page ~ '.organisation') | trans }}</th>
                    <th>{{ (page ~ '.contactInfo') | trans }}</th>
                    <th><span class="visually-hidden">Actions</span></th>
                </thead>

                <tbody>
                 {% for contact in contacts %}
                     <tr class="align--top dont-break-out">
                        <td class="width-quarter behat-region-client-profile-contacts-display-contact">
                            <dl>
                                <dt class="visually-hidden">{{ 'name' | trans({}, 'common') }}</dt>
                                <dd>
                                    <strong>{{ contact.firstName }} {{ contact.lastName }}</strong>
                                </dd>
                                {% if contact.jobTitle != "" %}
                                    <dt class="visually-hidden">{{ 'role' | trans({}, 'common') }}</dt>
                                    <dd>{{ contact.jobTitle }}</dd>
                                {% endif %}
                            </dl>
                        </td>
                        <td class="width-third behat-region-client-profile-contacts-display-organisation">
                            {% if
                                contact.orgName == "" and
                                contact.address1 == "" and
                                contact.address2 == "" and
                                contact.address3 == "" and
                                contact.addressPostcode == "" and
                                contact.addressCountry == ""
                            %}
                                -
                            {% else %}
                                <dl>
                                    <dt class="visually-hidden">{{ 'address' | trans({}, 'common') }}</dt>
                                    <dd>
                                        {% if contact.orgName %}
                                            {{ contact.orgName }}<br/>
                                        {% endif %}
                                        {% if contact.address1 %}
                                            {{ contact.address1 }}<br/>
                                        {% endif %}
                                        {% if contact.address2 %}
                                            {{ contact.address2 }}<br/>
                                        {% endif %}
                                        {% if contact.address3 %}
                                            {{ contact.address3 }}<br/>
                                        {% endif %}
                                        {% if contact.addressPostcode %}
                                            {{ contact.addressPostcode }}<br/>
                                        {% endif %}
                                        {% if contact.addressCountry %}
                                            {{ contact.addressCountry | country_name }}
                                        {% endif %}
                                    </dd>
{'fraction_non_alphanumeric': 0.12790982602303358, 'fraction_numerical': 0.002572898799313894, 'mean_word_length': 0.8418321299638989, 'pattern_counts': {'":': 0, '<': 103, '<?xml version=': 0, '>': 103, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 90, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1115895', 'n_tokens_mistral': 1795, 'n_tokens_neox': 1597, 'n_words': 340}