]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blob - client/src/app/+admin/follows/followers-list/followers-list.component.html
Merge branch 'release/2.1.0' into develop
[github/Chocobozzz/PeerTube.git] / client / src / app / +admin / follows / followers-list / followers-list.component.html
1 <p-table
2 [value]="followers" [lazy]="true" [paginator]="true" [totalRecords]="totalRecords" [rows]="rowsPerPage"
3 [sortField]="sort.field" [sortOrder]="sort.order" (onLazyLoad)="loadLazy($event)"
4 >
5 <ng-template pTemplate="caption">
6 <div class="caption">
7 <input
8 type="text" name="table-filter" id="table-filter" i18n-placeholder placeholder="Filter..."
9 (keyup)="onSearch($event)"
10 >
11 </div>
12 </ng-template>
13
14 <ng-template pTemplate="header">
15 <tr>
16 <th i18n>Follower handle</th>
17 <th i18n pSortableColumn="state">State <p-sortIcon field="state"></p-sortIcon></th>
18 <th i18n pSortableColumn="score">Score <p-sortIcon field="score"></p-sortIcon></th>
19 <th i18n pSortableColumn="createdAt">Created <p-sortIcon field="createdAt"></p-sortIcon></th>
20 <th></th>
21 </tr>
22 </ng-template>
23
24 <ng-template pTemplate="body" let-follow>
25 <tr>
26 <td><a [href]="follow.follower.url" target="_blank" rel="noopener noreferrer">{{ follow.follower.name + '@' + follow.follower.host }}</a></td>
27
28 <td *ngIf="follow.state === 'accepted'" i18n>Accepted</td>
29 <td *ngIf="follow.state === 'pending'" i18n>Pending</td>
30
31 <td>{{ follow.score }}</td>
32 <td>{{ follow.createdAt }}</td>
33
34 <td class="action-cell">
35 <ng-container *ngIf="follow.state === 'pending'">
36 <my-button i18n-label label="Accept" icon="tick" (click)="acceptFollower(follow)"></my-button>
37 <my-button i18n-label label="Refuse" icon="cross" (click)="rejectFollower(follow)"></my-button>
38 </ng-container>
39
40 <my-delete-button *ngIf="follow.state === 'accepted'" (click)="deleteFollower(follow)"></my-delete-button>
41 </td>
42 </tr>
43 </ng-template>
44 </p-table>