]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blob - client/src/app/+admin/follows/followers-list/followers-list.component.html
Add delete/manual approval instance followers in client
[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.target.value)"
10 >
11 </div>
12 </ng-template>
13
14 <ng-template pTemplate="header">
15 <tr>
16 <th i18n style="width: 60px">ID</th>
17 <th i18n>Follower handle</th>
18 <th i18n>State</th>
19 <th i18n>Score</th>
20 <th i18n pSortableColumn="createdAt">Created <p-sortIcon field="createdAt"></p-sortIcon></th>
21 <th></th>
22 </tr>
23 </ng-template>
24
25 <ng-template pTemplate="body" let-follow>
26 <tr>
27 <td>{{ follow.id }}</td>
28 <td>{{ follow.follower.name + '@' + follow.follower.host }}</td>
29
30 <td *ngIf="follow.state === 'accepted'" i18n>Accepted</td>
31 <td *ngIf="follow.state === 'pending'" i18n>Pending</td>
32
33 <td>{{ follow.score }}</td>
34 <td>{{ follow.createdAt }}</td>
35
36 <td class="action-cell">
37 <ng-container *ngIf="follow.state === 'pending'">
38 <my-button i18n-label label="Accept" icon="tick" (click)="acceptFollower(follow)"></my-button>
39 <my-button i18n-label label="Refuse" icon="cross" (click)="rejectFollower(follow)"></my-button>
40 </ng-container>
41
42 <my-delete-button *ngIf="follow.state === 'accepted'" (click)="deleteFollower(follow)"></my-delete-button>
43 </td>
44 </tr>
45 </ng-template>
46 </p-table>