[ACA-3672] - added server order for document -list (#5899)

* [ACA-3672] - added sorting server side for document-list

* [ACA-3672] - added and fixed unit tests for backend order

* [ACA-3672] - fixed failing test

* [ACA-3672] - regenerated doc and renamed variable

Co-authored-by: Vito Albano <vitoalbano@Vitos-MacBook-Pro.local>
This commit is contained in:
Vito
2020-07-23 14:04:05 +01:00
committed by GitHub
parent a5972e753a
commit 30c5c58d40
57 changed files with 132 additions and 81 deletions

View File

@@ -716,7 +716,8 @@
"type": "text",
"title": "ADF-DOCUMENT-LIST.LAYOUT.NAME",
"cssClass": "full-width ellipsis-cell",
"sortable": true
"sortable": true,
"sortingKey": "name"
},
{
"key": "visibility",

View File

@@ -229,7 +229,7 @@
[sortingMode]="sortingMode"
[showHeader]="showHeader"
[thumbnails]="thumbnails"
[stickyHeader]="stickyHeader"
[stickyHeader]="stickyHeader"
(error)="onNavigationError($event)"
(success)="resetError()"
(ready)="emitReadyEvent($event)"
@@ -269,6 +269,7 @@
<data-column
*ngIf="showNameColumn && hyperlinkNavigation"
key="name"
sortingKey="name"
class="app-ellipsis-cell"
title="{{'DOCUMENT_LIST.COLUMNS.DISPLAY_NAME' | translate}}"
[formatTooltip]="getNodeNameTooltip">
@@ -279,6 +280,7 @@
<data-column
*ngIf="showNameColumn && !hyperlinkNavigation"
key="name"
sortingKey="name"
title="{{'DOCUMENT_LIST.COLUMNS.DISPLAY_NAME' | translate}}"
[formatTooltip]="getNodeNameTooltip"
class="app-ellipsis-cell adf-expand-cell-5">
@@ -296,6 +298,7 @@
key="content.sizeInBytes"
title="{{'DOCUMENT_LIST.COLUMNS.SIZE' | translate}}"
type="fileSize"
sortingKey="sizeInBytes"
class="app-desktop-only adf-ellipsis-cell">
</data-column>
<data-column
@@ -328,6 +331,7 @@
title="{{'DOCUMENT_LIST.COLUMNS.IS_LOCKED' | translate}}"
key="id"
[focus]="false"
[sortable]="false"
class="app-desktop-only adf-ellipsis-cell">
<ng-template let-entry="$implicit">
<button mat-icon-button [adf-node-lock]="entry.row.node.entry" class="app-lock-button">
@@ -339,11 +343,13 @@
<data-column
title="{{'DOCUMENT_LIST.COLUMNS.CREATED_BY' | translate}}"
key="createdByUser.displayName"
sortingKey="createdByUser"
class="app-desktop-only adf-ellipsis-cell">
</data-column>
<data-column
title="{{'DOCUMENT_LIST.COLUMNS.CREATED' | translate}}"
key="createdAt"
sortingKey="createdAt"
type="date"
[format]="enableMediumTimeFormat ? 'medium' : 'timeAgo'"
class="app-desktop-only adf-ellipsis-cell">

View File

@@ -92,7 +92,7 @@ export class FilesComponent implements OnInit, OnChanges, OnDestroy {
sorting = ['name', 'asc'];
@Input()
sortingMode = 'client';
sortingMode = 'server';
@Input()
showRecentFiles = true;