<div id="content">
<form action="index.php?module=contact&event=merge" method="POST" >  
<input type='hidden' name='id' value='[% $ContactID %]' />
<div class="card panel-info shadow-sm rounded">
    <div class="card-header">
        <div class="row">
            <div class="col-lg-6">
                <span class="fcs-card-title h3">[% $user->gettext('Kontakte zusammenfügen') %]</span>
            </div>
            <div class="col-lg-6 text-end">
                <button type='submit' class='btn btn-outline-primary'>[% $user->gettext('Zusammenfügen') %]</button>
            </div>
        </div>
    </div>
    <div class="card-body">

  
        <div class="form-group row mb-3">
            <label class="control-label" for="mergeContacts">[% $user->gettext('Wählen Sie die zu ersetzenden Kontakte.Die Tickets und sonstigen Verknüpfungen dieser Kontakte werden dem aktuellen Kontakt zugeordnet. Die gewählten Kontakte werden anschließend deaktiviert.') %]</label>
             <br>
             <select name="MergeIDs[]" id="mergeContacts" class="multiple" multiple='multiple' style="width:100%;">
                [% foreach from=$Contacts item=Contact %]
                    <option value="[% $Contact.contact_id %]">
                        [% $Contact.name %] ([% $Contact.email %]) ([% $Contact.username %]) [% if $Tools->FCS_Count($Contact.count) %](Tickets: [% $Tools->FCS_Count($Contact.count) %])[% /if %]
                    </option>
                [% /foreach %]
            </select>
          
           
        </div>
    </div>
</div>
</form>
</div>

<script type="text/javascript">

        
    $("#mergeContacts").select2({theme: 'bootstrap-5'});

    



    -->
</script>