Align follower handle display on instance display in tables
This commit is contained in:
parent
df4c603dea
commit
1d26d05fd9
6 changed files with 27 additions and 8 deletions
|
@ -1,6 +1,6 @@
|
|||
<p-table
|
||||
[value]="followers" [lazy]="true" [paginator]="totalRecords > 0" [totalRecords]="totalRecords" [rows]="rowsPerPage" [rowsPerPageOptions]="rowsPerPageOptions"
|
||||
[sortField]="sort.field" [sortOrder]="sort.order" (onLazyLoad)="loadLazy($event)"
|
||||
[sortField]="sort.field" [sortOrder]="sort.order" (onLazyLoad)="loadLazy($event)" (onPage)="onPage($event)"
|
||||
[showCurrentPageReport]="true" i18n-currentPageReportTemplate
|
||||
currentPageReportTemplate="Showing {{'{first}'}} to {{'{last}'}} of {{'{totalRecords}'}} followers"
|
||||
>
|
||||
|
@ -29,7 +29,12 @@
|
|||
|
||||
<ng-template pTemplate="body" let-follow>
|
||||
<tr>
|
||||
<td><a [href]="follow.follower.url" target="_blank" rel="noopener noreferrer">{{ follow.follower.name + '@' + follow.follower.host }}</a></td>
|
||||
<td>
|
||||
<a [href]="follow.follower.url" i18n-title title="Open actor page in a new tab" target="_blank" rel="noopener noreferrer">
|
||||
{{ follow.follower.name + '@' + follow.follower.host }}
|
||||
<span class="glyphicon glyphicon-new-window"></span>
|
||||
</a>
|
||||
</td>
|
||||
|
||||
<td *ngIf="follow.state === 'accepted'" i18n>Accepted</td>
|
||||
<td *ngIf="follow.state === 'pending'" i18n>Pending</td>
|
||||
|
|
|
@ -9,6 +9,20 @@
|
|||
}
|
||||
}
|
||||
|
||||
a {
|
||||
@include disable-default-a-behaviour;
|
||||
display: inline-block;
|
||||
|
||||
&, &:hover {
|
||||
color: var(--mainForegroundColor);
|
||||
}
|
||||
|
||||
span {
|
||||
font-size: 80%;
|
||||
color: var(--inputPlaceholderColor);
|
||||
}
|
||||
}
|
||||
|
||||
.action-cell {
|
||||
my-button:first-child {
|
||||
margin-right: 10px;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<p-table
|
||||
[value]="following" [lazy]="true" [paginator]="totalRecords > 0" [totalRecords]="totalRecords" [rows]="rowsPerPage" [rowsPerPageOptions]="rowsPerPageOptions"
|
||||
[sortField]="sort.field" [sortOrder]="sort.order" (onLazyLoad)="loadLazy($event)"
|
||||
[sortField]="sort.field" [sortOrder]="sort.order" (onLazyLoad)="loadLazy($event)" (onPage)="onPage($event)"
|
||||
[showCurrentPageReport]="true" i18n-currentPageReportTemplate
|
||||
currentPageReportTemplate="Showing {{'{first}'}} to {{'{last}'}} of {{'{totalRecords}'}} hosts"
|
||||
>
|
||||
|
|
|
@ -12,8 +12,8 @@
|
|||
</div>
|
||||
|
||||
<p-table
|
||||
[value]="videoRedundancies" [lazy]="true" [paginator]="totalRecords > 0" [totalRecords]="totalRecords" [rows]="rowsPerPage"
|
||||
[sortField]="sort.field" [sortOrder]="sort.order" (onLazyLoad)="loadLazy($event)" dataKey="id"
|
||||
[value]="videoRedundancies" [lazy]="true" [paginator]="totalRecords > 0" [totalRecords]="totalRecords" [rows]="rowsPerPage" [rowsPerPageOptions]="rowsPerPageOptions"
|
||||
[sortField]="sort.field" [sortOrder]="sort.order" (onLazyLoad)="loadLazy($event)" dataKey="id" (onPage)="onPage($event)"
|
||||
(onPage)="onPage($event)" [expandedRowKeys]="expandedRows"
|
||||
>
|
||||
<ng-template pTemplate="header">
|
||||
|
|
|
@ -37,13 +37,13 @@
|
|||
</a>
|
||||
</div>
|
||||
<div>
|
||||
<a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': user?.account.displayName }">
|
||||
<a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': 'reportee:' + user?.account.displayName }">
|
||||
<div class="dashboard-num">{{ user.videoAbusesCount }}</div>
|
||||
<div class="dashboard-label" i18n>Incriminated in reports</div>
|
||||
</a>
|
||||
</div>
|
||||
<div>
|
||||
<a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': user?.account.displayName }">
|
||||
<a [routerLink]="[ '/admin/moderation/video-abuses/list' ]" [queryParams]="{ 'search': 'reporter:' + user?.account.displayName + ' state:accepted' }">
|
||||
<div class="dashboard-num">{{ user.videoAbusesAcceptedCount }} / {{ user.videoAbusesCreatedCount }}</div>
|
||||
<div class="dashboard-label" i18n>Authored reports accepted</div>
|
||||
</a>
|
||||
|
|
|
@ -154,5 +154,5 @@ async function reportVideoAbuse (req: express.Request, res: express.Response) {
|
|||
|
||||
logger.info('Abuse report for video %s created.', videoInstance.name)
|
||||
|
||||
return res.json({ videoAbuseJSON }).end()
|
||||
return res.json({ videoAbuse: videoAbuseJSON }).end()
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue