{% if proprietaire is defined and proprietaire.id is not null %}
    {{ form_start(form, {'action': path('admin.acteurs.proprietaires.edit', {'id': proprietaire.id}), 'method': 'POST'}) }}
{% else %}
    {{ form_start(form, {'action': path('admin.acteurs.proprietaires.new'), 'method': 'POST'}) }}
{% endif %}
{{ alert_infos('NB!', 'Tous les champs comportant un (*) sont obligatoires.') }}
<ul class="nav nav-tabs nav-tabs-highlight">
    <li class="nav-item">
        <a href="#vertical-left-infos" class="nav-link active" data-toggle="tab">
            <i class="icon-info22 mr-2"></i> Infos
        </a>
    </li>
    <li class="nav-item">
        <a href="#vertical-left-adresses" class="nav-link" data-toggle="tab">
            <i class="icon-address-book mr-2"></i> Adresses
        </a>
    </li>
</ul>

<div class="tab-content">
    <div class="tab-pane fade show active" id="vertical-left-infos">
        <div class="row">
            <div class="col-sm-6">
                <div class="form-group">
                    <label class="form-label">{{ form_label(form.civilite) }}</label>
                    {{ form_widget(form.civilite) }}
                    <a href="javascript:void(0)">{{ form_help(form.civilite) }}</a>
                </div>
            </div>
            <div class="col-sm-6">
                <div class="form-group">
                    <label class="form-label">{{ form_label(form.name) }}</label>
                    {{ form_widget(form.name) }}
                    <a href="javascript:void(0)">{{ form_help(form.name) }}</a>
                </div>
            </div>
        </div>

        <div class="row">
            <div class="col-sm-6">
                <div class="form-group">
                    <label class="form-label">{{ form_label(form.numeroCniPassport) }}</label>
                    {{ form_widget(form.numeroCniPassport) }}
                    <a href="javascript:void(0)">{{ form_help(form.numeroCniPassport) }}</a>
                </div>
            </div>
            <div class="col-sm-6">
                <div class="form-group">
                    <label class="form-label">{{ form_label(form.adresses.phone) }}</label>
                    {{ form_widget(form.adresses.phone) }}
                    <a href="javascript:void(0)">{{ form_help(form.adresses.phone) }}</a>
                </div>
            </div>
        </div>

        <div class="row">
            <div class="col-md-12">
                {{ form_widget(form.isActif) }}
            </div>
        </div>
    </div>
    <div class="tab-pane fade" id="vertical-left-adresses">
        {% include 'admin/acteurs/commons/_address_form.html.twig' with {'form': form} %}
    </div>
</div>

<div class="text-right mt-3">
    <button type="reset" class="btn btn-sm btn-default">Annuler</button> &nbsp;
    <button type="submit" id="sendProprietaireBtn" class="btn btn-sm btn-primary"><i class="icon-floppy-disk"></i> {{ button_label|default('Enregistrer') }}</button>
</div>
{{ form_end(form) }}

