{#
/*
 * Copyright © ProgramCMS. All rights reserved.
 * See COPYING.txt for license details.
 *
 * Developed by Mohamed EL QUCHIRI <elquchiri@gmail.com>
 */
#}
<h3>{{ block.trans('Addresses') }}</h3>
<table class="table table-striped mt-4">
    <tr>
        <th>{{ block.trans('First Name') }}</th>
        <th>{{ block.trans('Last Name') }}</th>
        <th>{{ block.trans('Street Address') }}</th>
        <th>{{ block.trans('City') }}</th>
        <th>{{ block.trans('Country') }}</th>
        <th>{{ block.trans('State') }}</th>
        <th>{{ block.trans('Postal Code') }}</th>
        <th>{{ block.trans('Phone') }}</th>
        <th></th>
    </tr>
    {% for address in block.getAddresses() %}
        <tr>
            <td>{{ address.getFirstname() }}</td>
            <td>{{ address.getLastname() }}</td>
            <td>{{ address.getStreet() }}</td>
            <td>{{ address.getCity() }}</td>
            <td>{{ address.getCountry() }}</td>
            <td>{{ address.getState() }}</td>
            <td>{{ address.getZipcode() }}</td>
            <td>{{ address.getTelephone() }}</td>
            <td>
                <a href="{{ block.getEditAddressUrl(address) }}">{{ block.trans('Edit') }}</a>
                &middot;
                <a href="{{ block.getRemoveAddressUrl(address) }}" class="text-danger">{{ block.trans('Delete') }}</a>
            </td>
        </tr>
    {% endfor %}
</table>

<a href="{{ block.getNewAddressUrl() }}" class="btn btn-primary mt-5">{{ block.trans('Add New Address') }}</a>