Browse Source

[Administration] Tickets admin : savoir si un ticket a été lu #1194

feature/souke
Guillaume Bourgeois 1 year ago
parent
commit
586199317c
2 changed files with 10 additions and 1 deletions
  1. +9
    -0
      backend/views/support/view.php
  2. +1
    -1
      common/logic/Ticket/Ticket/Service/TicketSolver.php

+ 9
- 0
backend/views/support/view.php View File

<td><strong>Statut</strong></td> <td><strong>Statut</strong></td>
<td><?= $ticketManager->getTicketStatusLabelAsHtml($ticket); ?></td> <td><?= $ticketManager->getTicketStatusLabelAsHtml($ticket); ?></td>
</tr> </tr>
<?php if($userManager->isCurrentAdmin()): ?>
<tr>
<td><strong>Producteur</strong></td>
<td><?= $ticketManager->isTicketUnread($ticket, $ticket->user) ?
'<span class="label label-warning">Non lu</span>' :
'<span class="label label-success">Lu</span>'; ?>
</td>
</tr>
<?php endif; ?>
</tbody> </tbody>
</table> </table>
</div> </div>

+ 1
- 1
common/logic/Ticket/Ticket/Service/TicketSolver.php View File

return false; return false;
} }


public function isTicketUnread(Ticket $ticket, User $user): int
public function isTicketUnread(Ticket $ticket, User $user): bool
{ {
$ticketUser = $this->getTicketUser($ticket, $user); $ticketUser = $this->getTicketUser($ticket, $user);



Loading…
Cancel
Save