Non puoi selezionare più di 25 argomenti Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.
 
 
 
 
 
 

284 righe
13 KiB

<?php
use Cake\Core\Configure;
echo $this->Breadcrumb->render([
[
'title' => 'Home',
'icon' => 'fa fa-home',
'url' => '/',
],
[
'title' => __('Configurazioni'),
'icon' => 'fa fa-wrench',
],
[
'title' => __('Lista {0}', $actor->hasValue('organisation') ? __('Organizzazioni') : __('Utenti')),
'icon' => 'fa fa-list',
'url' => ['controller' => $actor->hasValue('organisation') ? 'organisations' : 'users', 'action' => 'index'],
],
[
'title' => __('Dettaglio {0}', $actor->hasValue('organisation') ? __('Organizzazione') : __('Utente')),
'icon' => 'fa fa-info',
'url' => ['controller' => $actor->hasValue('organisation') ? 'organisations' : 'users', 'action' => 'view', $actor->organisation->id ?? $actor->user->id],
],
[
'title' => __('Gestione recapiti'),
'icon' => 'fa fa-phone',
],
]);
?>
<div class="card card-primary card-outline">
<div class="card-header d-sm-flex">
<h2 class="card-title">
<?php echo __('Recapiti associati a {0} "{1}"', $actor->actor_type->description, $actor->description); ?>
</h2>
</div>
<div class="card-body table-responsive p-0">
<table class="table table-hover text-nowrap">
<thead>
</thead>
<tbody>
</tbody>
</table>
</div>
<div class="card-footer d-flex">
<div class="ml-auto">
</div>
</div>
</div>
<!-- Lista MobilePhones -->
<div class="card card-primary card-outline">
<div class="card-header d-sm-flex">
<h2 class="card-title">
<?php echo __('Cellulare: {0}', $mobile_phones->count()); ?>
</h2>
</div>
<div class="card-body table-responsive p-0">
<table class="table table-hover text-nowrap">
<thead>
<tr>
<th scope="col"><?= __('Descrizione') ?></th>
<th scope="col"><?= __('Cellulare') ?></th>
<th scope="col"><?= __('Ricevi notifiche a questo recapito') ?></th>
<th scope="col" class="actions text-right"><?= __('Azioni') ?></th>
</tr>
</thead>
<tbody>
<?php foreach ($mobile_phones as $mobile_phone): ?>
<tr>
<td><?= h($mobile_phone->mobile_phone_description->description) ?></td>
<td><?= h($mobile_phone->value) ?></td>
<td><?= $mobile_phone->enable_notifications ? __('SI') : __('NO') ?></td>
<td class="actions text-right">
<?= $can_edit_mobile_phone ? $this->Html->link(__('Modifica'), ['controller' => 'MobilePhones', 'action' => 'edit', $mobile_phone->id], ['class'=>'btn btn-warning btn-xs']) : null ?>
<?= $can_delete_mobile_phone ? $this->Form->postLink(__('Cancella'), ['action' => 'delete', $mobile_phone->delivery_id], ['confirm' => __('Sei sicuro che vuoi cancellare il Cellulare "{0}" ?', $mobile_phone->value), 'class'=>'btn btn-danger btn-xs']) : null ?>
</td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
<div class="card-footer d-flex">
<div class="ml-auto">
<?= $can_add_mobile_phone ? $this->Html->link(__('Aggiungi Cellulare'), ['controller' => 'MobilePhones', 'action' => 'add', $actor->id], ['class'=>'btn btn-success btn-xs']) : null ?>
</div>
</div>
</div>
<!-- Lista Faxes -->
<div class="card card-primary card-outline">
<div class="card-header d-sm-flex">
<h2 class="card-title">
<?php echo __('Fax: {0}', $faxes->count()); ?>
</h2>
</div>
<div class="card-body table-responsive p-0">
<table class="table table-hover text-nowrap">
<thead>
<tr>
<th scope="col"><?= __('Descrizione') ?></th>
<th scope="col"><?= __('Fax') ?></th>
<th scope="col"><?= __('Ricevi notifiche a questo recapito') ?></th>
<th scope="col" class="actions text-right"><?= __('Azioni') ?></th>
</tr>
</thead>
<tbody>
<?php foreach ($faxes as $fax): ?>
<tr>
<td><?= h($fax->fax_description->description) ?></td>
<td><?= h($fax->value) ?></td>
<td><?= $fax->enable_notifications ? __('SI') : __('NO') ?></td>
<td class="actions text-right">
<?= $can_edit_fax ? $this->Html->link(__('Modifica'), ['controller' => 'Faxes', 'action' => 'edit', $fax->id], ['class'=>'btn btn-warning btn-xs']) : null ?>
<?= $can_delete_fax ? $this->Form->postLink(__('Cancella'), ['action' => 'delete', $fax->delivery_id], ['confirm' => __('Sei sicuro che vuoi cancellare il Fax "{0}" ?', $fax->value), 'class'=>'btn btn-danger btn-xs']) : null ?>
</td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
<div class="card-footer d-flex">
<div class="ml-auto">
<?= $can_add_fax ? $this->Html->link(__('Aggiungi Fax'), ['controller' => 'Faxes', 'action' => 'add', $actor->id], ['class'=>'btn btn-success btn-xs']) : null ?>
</div>
</div>
</div>
<!-- Lista Emails -->
<div class="card card-primary card-outline">
<div class="card-header d-sm-flex">
<h2 class="card-title">
<?php echo __('Email: {0}', $emails->count()); ?>
</h2>
</div>
<div class="card-body table-responsive p-0">
<table class="table table-hover text-nowrap">
<thead>
<tr>
<th scope="col"><?= __('Descrizione') ?></th>
<th scope="col"><?= __('Email') ?></th>
<th scope="col"><?= __('Ricevi notifiche a questo recapito') ?></th>
<th scope="col" class="actions text-right"><?= __('Azioni') ?></th>
</tr>
</thead>
<tbody>
<?php foreach ($emails as $email): ?>
<tr>
<td><?= h($email->email_description->description) ?></td>
<td><?= h($email->value) ?></td>
<td><?= $email->enable_notifications ? __('SI') : __('NO') ?></td>
<td class="actions text-right">
<?= $can_edit_email ? $this->Html->link(__('Modifica'), ['controller' => 'Emails', 'action' => 'edit', $email->id], ['class'=>'btn btn-warning btn-xs']) : null ?>
<?= $can_delete_email ? $this->Form->postLink(__('Cancella'), ['action' => 'delete', $email->delivery_id], ['confirm' => __('Sei sicuro che vuoi cancellare l\'Email "{0}" ?', $email->value), 'class'=>'btn btn-danger btn-xs']) : null ?>
</td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
<div class="card-footer d-flex">
<div class="ml-auto">
<?= $can_add_email ? $this->Html->link(__('Aggiungi Email'), ['controller' => 'Emails', 'action' => 'add', $actor->id], ['class'=>'btn btn-success btn-xs']) : null ?>
</div>
</div>
</div>
<!-- Lista Phones -->
<div class="card card-primary card-outline">
<div class="card-header d-sm-flex">
<h2 class="card-title">
<?php echo __('Telefono: {0}', $phones->count()); ?>
</h2>
</div>
<div class="card-body table-responsive p-0">
<table class="table table-hover text-nowrap">
<thead>
<tr>
<th scope="col"><?= __('Descrizione') ?></th>
<th scope="col"><?= __('Telefono') ?></th>
<th scope="col" class="actions text-right"><?= __('Azioni') ?></th>
</tr>
</thead>
<tbody>
<?php foreach ($phones as $phone): ?>
<tr>
<td><?= h($phone->phone_description->description) ?></td>
<td><?= h($phone->value) ?></td>
<td class="actions text-right">
<?= $can_edit_phone ? $this->Html->link(__('Modifica'), ['controller' => 'Phones', 'action' => 'edit', $phone->id], ['class'=>'btn btn-warning btn-xs']) : null ?>
<?= $can_delete_phone ? $this->Form->postLink(__('Cancella'), ['action' => 'delete', $phone->delivery_id], ['confirm' => __('Sei sicuro che vuoi cancellare il Telefono "{0}" ?', $phone->value), 'class'=>'btn btn-danger btn-xs']) : null ?>
</td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
<div class="card-footer d-flex">
<div class="ml-auto">
<?= $can_add_phone ? $this->Html->link(__('Aggiungi Telefono'), ['controller' => 'Phones', 'action' => 'add', $actor->id], ['class'=>'btn btn-success btn-xs']) : null ?>
</div>
</div>
</div>
<!-- Lista TelegramChats -->
<div class="card card-primary card-outline">
<div class="card-header d-sm-flex">
<h2 class="card-title">
<?php echo __('Chat Telegram: {0}', $telegram_chats->count()); ?>
</h2>
</div>
<div class="card-header d-sm-flex">
<h2 class="card-title">
<?php echo __('(Per ottenere il proprio ID, aprire l\'app Telegram, cercare il BOT "{0}" e chiedere il proprio ID mediante l\'apposito comando)', Configure::read('App.messaging_broker_config.ies.telegram.bot_username', __('N.D.'))); ?>
</h2>
</div>
<div class="card-body table-responsive p-0">
<table class="table table-hover text-nowrap">
<thead>
<tr>
<th scope="col"><?= __('ID') ?></th>
<th scope="col"><?= __('Ricevi notifiche a questo recapito') ?></th>
<th scope="col" class="actions text-right"><?= __('Azioni') ?></th>
</tr>
</thead>
<tbody>
<?php foreach ($telegram_chats as $telegram_chat): ?>
<tr>
<td><?= h($telegram_chat->value) ?></td>
<td><?= $telegram_chat->enable_notifications ? __('SI') : __('NO') ?></td>
<td class="actions text-right">
<?= $can_edit_telegram_chat ? $this->Html->link(__('Modifica'), ['controller' => 'TelegramChats', 'action' => 'edit', $telegram_chat->id], ['class'=>'btn btn-warning btn-xs']) : null ?>
<?= $can_delete_telegram_chat ? $this->Form->postLink(__('Cancella'), ['action' => 'delete', $telegram_chat->delivery_id], ['confirm' => __('Sei sicuro che vuoi cancellare la Chat Telegram con ID "{0}" ?', $telegram_chat->value), 'class'=>'btn btn-danger btn-xs']) : null ?>
</td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
<div class="card-footer d-flex">
<div class="ml-auto">
<?= $can_add_telegram_chat ? $this->Html->link(__('Aggiungi Chat Telegram'), ['controller' => 'TelegramChats', 'action' => 'add', $actor->id], ['class'=>'btn btn-success btn-xs']) : null ?>
</div>
</div>
</div>
<!-- Lista Pecs -->
<div class="card card-primary card-outline">
<div class="card-header d-sm-flex">
<h2 class="card-title">
<?php echo __('PEC: {0}', $pecs->count()); ?>
</h2>
</div>
<div class="card-body table-responsive p-0">
<table class="table table-hover text-nowrap">
<thead>
<tr>
<th scope="col"><?= __('Descrizione') ?></th>
<th scope="col"><?= __('PEC') ?></th>
<th scope="col"><?= __('Ricevi notifiche a questo recapito') ?></th>
<th scope="col" class="actions text-right"><?= __('Azioni') ?></th>
</tr>
</thead>
<tbody>
<?php foreach ($pecs as $pec): ?>
<tr>
<td><?= h($pec->pec_description->description) ?></td>
<td><?= h($pec->value) ?></td>
<td><?= $pec->enable_notifications ? __('SI') : __('NO') ?></td>
<td class="actions text-right">
<?= $can_edit_pec ? $this->Html->link(__('Modifica'), ['controller' => 'Pecs', 'action' => 'edit', $pec->id], ['class'=>'btn btn-warning btn-xs']) : null ?>
<?= $can_delete_pec ? $this->Form->postLink(__('Cancella'), ['action' => 'delete', $pec->delivery_id], ['confirm' => __('Sei sicuro che vuoi cancellare la PEC "{0}" ?', $pec->value), 'class'=>'btn btn-danger btn-xs']) : null ?>
</td>
</tr>
<?php endforeach; ?>
</tbody>
</table>
</div>
<div class="card-footer d-flex">
<div class="ml-auto">
<?= $can_add_pec ? $this->Html->link(__('Aggiungi PEC'), ['controller' => 'Pecs', 'action' => 'add', $actor->id], ['class'=>'btn btn-success btn-xs']) : null ?>
</div>
</div>
</div>