getUserModule(); $ticketModule = TicketModule::getInstance(); $adminSettingBag = $this->getSettingModule()->getAdminSettingBag(); $userCurrent = $this->getUserCurrent(); $this->setTitle('Support & contact'); $this->addBreadcrumb($this->getTitle()); $supportOnline = $adminSettingBag->get('supportOnline'); ?>
renderFile('@common/views/alert_message.php', [ 'display' => $adminSettingBag->get('adminSupportAlertMessageDisplay'), 'type' => $adminSettingBag->get('adminSupportAlertMessageType'), 'title' => $adminSettingBag->get('adminSupportAlertMessageTitle'), 'icon' => $adminSettingBag->get('adminSupportAlertMessageIcon'), 'message' => $adminSettingBag->get('adminSupportAlertMessage'), ]) ?>

Pour toutes vos questions, remarques, suggestions et remontées de bugs.

Me contacter directement
Disponible

get('administratorPhoneNumber'); ?>

parameterBag->get('appointmentUrl'), ['class' => 'btn btn-sm btn-default', 'target' => '_blank']); ?>

'btn btn-sm btn-default']); ?>

get('administratorEmail'), ['class' => 'btn btn-sm btn-default']); ?>
get('forumFlarumUrl')): ?>

get('forumFlarumUrl'), ['class' => 'btn btn-sm btn-default', 'target' => '_blank']); ?>
'created_at', 'headerOptions' => ['class' => 'td-created-at column-hide-on-mobile'], 'value' => function ($ticket) { return date('d/m/Y', strtotime($ticket->created_at)); } ]; $columnSubject = [ 'attribute' => 'subject', 'headerOptions' => ['class' => 'td-subject'], 'format' => 'raw', 'value' => function ($ticket) use ($ticketModule, $userCurrent) { $firstTicketMessageUnread = $ticketModule->getFirstTicketMessageUnread($ticket, $userCurrent); if ($ticketModule->isTicketUnread($ticket, $userCurrent) && $firstTicketMessageUnread) { $link = '' . Html::a($ticket->subject, ['view', 'id' => $ticket->id, '#' => $firstTicketMessageUnread->id]) . ''; } else { $link = Html::a($ticket->subject, ['view', 'id' => $ticket->id]); } return $link; } ]; $columnLastMessage = [ 'label' => 'Dernier message', 'headerOptions' => ['class' => 'td-last-message column-hide-on-mobile'], 'value' => function ($ticket) { $ticketMessages = $ticket->ticketMessages; if ($ticketMessages && is_array($ticketMessages)) { $lastTicketMessage = end($ticketMessages); $origin = date_create(date('Y-m-d', strtotime($lastTicketMessage->created_at))); $target = date_create(); $interval = date_diff($origin, $target); $days = (int)$interval->format('%R%a'); if ($days == 0) { return "Aujourd'hui"; } elseif ($days == 1) { return "Hier"; } else { return $days . ' jours'; } } return ''; } ]; $columnMessages = [ 'label' => 'Messages', 'headerOptions' => ['class' => 'td-messages column-hide-on-mobile'], 'value' => function ($ticket) { return count($ticket->ticketMessages); } ]; $columnButtonActions = [ 'class' => 'yii\grid\ActionColumn', 'template' => '{view} {close-open}', 'headerOptions' => ['class' => 'column-actions'], 'contentOptions' => ['class' => 'column-actions'], 'buttons' => [ 'view' => function ($url, $ticket) { $url = ['view', 'id' => $ticket->id]; return Html::a('', $url, [ 'title' => 'Voir le ticket', 'class' => 'btn btn-default' ]); }, 'close-open' => function ($url, $ticket) use ($ticketModule) { if ($ticketModule->isTicketOpen($ticket)) { $title = 'Fermer'; $url = ['close', 'id' => $ticket->id]; $glyphicon = 'glyphicon-folder-close'; } else { $title = 'Ré-ouvrir'; $url = ['open', 'id' => $ticket->id]; $glyphicon = 'glyphicon-folder-open'; } return Html::a('', $url, [ 'title' => $title, 'class' => 'btn btn-default' ]); } ], ]; $columnProducer = [ 'attribute' => 'id_producer', 'headerOptions' => ['class' => 'td-producer'], 'value' => function ($ticket) { return $ticket->producer->name; } ]; if ($context == 'producer') { $columns = [ $columnCreatedAt, $columnSubject, $columnLastMessage, $columnMessages, $columnButtonActions ]; } elseif ($context == 'admin') { $columns = [ $columnCreatedAt, $columnProducer, $columnSubject, $columnLastMessage, $columnMessages, $columnButtonActions ]; } $optionsGridView = [ 'summary' => '', 'filterModel' => $searchTicket, 'dataProvider' => $dataProviderTicket, 'columns' => $columns, ]; return GridView::widget($optionsGridView); } ?>