mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
[ADF-1805] added some peer review changes and documentation changes
This commit is contained in:
@@ -59,6 +59,10 @@
|
||||
],
|
||||
"private": true,
|
||||
"dependencies": {
|
||||
"@alfresco/adf-content-services": "2.0.0-303d0166157d305ebfbf1578bf5d1eadcaa631cc",
|
||||
"@alfresco/adf-core": "2.0.0-303d0166157d305ebfbf1578bf5d1eadcaa631cc",
|
||||
"@alfresco/adf-insights": "2.0.0-303d0166157d305ebfbf1578bf5d1eadcaa631cc",
|
||||
"@alfresco/adf-process-services": "2.0.0-303d0166157d305ebfbf1578bf5d1eadcaa631cc",
|
||||
"@angular/animations": "5.0.0",
|
||||
"@angular/cdk": "5.0.0-rc0",
|
||||
"@angular/common": "5.0.0",
|
||||
@@ -72,11 +76,7 @@
|
||||
"@angular/platform-browser-dynamic": "5.0.0",
|
||||
"@angular/router": "5.0.0",
|
||||
"@ngx-translate/core": "8.0.0",
|
||||
"alfresco-js-api": "2.0.0-de41fd8ca9c1c6f6072d2e06415eef0a71330dc0",
|
||||
"@alfresco/adf-content-services": "2.0.0-303d0166157d305ebfbf1578bf5d1eadcaa631cc",
|
||||
"@alfresco/adf-process-services": "2.0.0-303d0166157d305ebfbf1578bf5d1eadcaa631cc",
|
||||
"@alfresco/adf-core": "2.0.0-303d0166157d305ebfbf1578bf5d1eadcaa631cc",
|
||||
"@alfresco/adf-insights": "2.0.0-303d0166157d305ebfbf1578bf5d1eadcaa631cc",
|
||||
"alfresco-js-api": "^2.0.0-a5057a6373212ca42e5c29a1a2550cc78dca53ad",
|
||||
"chart.js": "2.5.0",
|
||||
"classlist.js": "1.1.20150312",
|
||||
"core-js": "2.4.1",
|
||||
|
@@ -255,6 +255,7 @@
|
||||
</content-actions>
|
||||
</adf-document-list>
|
||||
<adf-pagination
|
||||
#standardPagination
|
||||
*ngIf="!infiniteScrolling"
|
||||
class="adf-documentlist-pagination"
|
||||
[pagination]="pagination"
|
||||
|
@@ -25,7 +25,8 @@ import { MinimalNodeEntity, NodePaging, Pagination } from 'alfresco-js-api';
|
||||
import {
|
||||
AlfrescoApiService, ContentService, TranslationService,
|
||||
FileUploadEvent, FolderCreatedEvent, LogService, NotificationService,
|
||||
SiteModel, UploadService, DataColumn, DataRow, UserPreferencesService
|
||||
SiteModel, UploadService, DataColumn, DataRow, UserPreferencesService,
|
||||
PaginationComponent
|
||||
} from '@alfresco/adf-core';
|
||||
|
||||
import { DocumentListComponent, PermissionStyleModel, DownloadZipDialogComponent } from '@alfresco/adf-content-services';
|
||||
@@ -116,6 +117,9 @@ export class FilesComponent implements OnInit, OnChanges, OnDestroy {
|
||||
@ViewChild(DocumentListComponent)
|
||||
documentList: DocumentListComponent;
|
||||
|
||||
@ViewChild(PaginationComponent)
|
||||
standardPagination: PaginationComponent;
|
||||
|
||||
permissionsStyle: PermissionStyleModel[] = [];
|
||||
supportedPages: number[] = [5, 10, 15, 20];
|
||||
infiniteScrolling: boolean;
|
||||
@@ -133,9 +137,9 @@ export class FilesComponent implements OnInit, OnChanges, OnDestroy {
|
||||
private dialog: MatDialog,
|
||||
private translateService: TranslationService,
|
||||
private router: Router,
|
||||
@Optional() private route: ActivatedRoute,
|
||||
private logService: LogService,
|
||||
private preference: UserPreferencesService) {
|
||||
private preference: UserPreferencesService,
|
||||
@Optional() private route: ActivatedRoute) {
|
||||
}
|
||||
|
||||
showFile(event) {
|
||||
@@ -254,8 +258,16 @@ export class FilesComponent implements OnInit, OnChanges, OnDestroy {
|
||||
}
|
||||
|
||||
emitReadyEvent(event: any) {
|
||||
this.documentListReady.emit(event);
|
||||
this.pagination = event.list.pagination;
|
||||
if (this.pageIsEmpty(event)) {
|
||||
this.standardPagination.goPrevious();
|
||||
} else {
|
||||
this.documentListReady.emit(event);
|
||||
this.pagination = event.list.pagination;
|
||||
}
|
||||
}
|
||||
|
||||
pageIsEmpty(node: NodePaging) {
|
||||
return node && node.list && node.list.entries.length === 0;
|
||||
}
|
||||
|
||||
onContentActionError(errors) {
|
||||
|
Reference in New Issue
Block a user