Add logs page in client
[oweals/peertube.git] / client / src / app / +admin / system / logs / logs.component.html
1 <div class="header">
2   <div class="peertube-select-container">
3     <select [(ngModel)]="startDate" (ngModelChange)="refresh()">
4       <option *ngFor="let timeChoice of timeChoices" [value]="timeChoice.id">{{ timeChoice.label }}</option>
5     </select>
6   </div>
7
8   <div class="peertube-select-container">
9     <select [(ngModel)]="level" (ngModelChange)="refresh()">
10       <option *ngFor="let levelChoice of levelChoices" [value]="levelChoice.id">{{ levelChoice.label }}</option>
11     </select>
12   </div>
13
14   <my-button i18n-label label="Refresh" icon="refresh" (click)="refresh()"></my-button>
15 </div>
16
17 <div class="logs">
18   <div *ngIf="loading">Loading...</div>
19
20   <div #logsElement>
21     <div *ngFor="let log of logs" class="log-row" [ngClass]="{ error: log.level === 'error', warn: log.level === 'warn' }">
22       <span class="log-level">{{ log.level }}</span>
23
24       <span class="log-date">[{{ log.localeDate }}]</span>
25
26       {{ log.message }}
27
28       {{ log.meta }}
29     </div>
30   </div>
31 </div>