mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-3499] adding new dialog for external content file (#3799)
* [ADF-3499] start creation of login dialog component with extra auth service feature * [ADF-3499] adding new dialog for external content file * [ADF-3499] fixed condition for pop up and added prefix ticket * [ADF-3499] fixed smartfolder bug for content node selector * [ADF-3499] disabling preview after uploading for external resource files * [ADF-3499] fixed unit test for document list service * [ADF-3499] added unit test to new components * [ADF-3499] added translation and some fix * [ADF-3499] fixed labels * [ADF-3499] fixed problem with node and node entry for smart folders * [ADF-3499] fixed compilation problem
This commit is contained in:
@@ -168,8 +168,13 @@ export class ShareDataTableAdapter implements DataTableAdapter {
|
||||
}
|
||||
|
||||
isSmartFolder(node: any) {
|
||||
return node.entry.aspectNames && (node.entry.aspectNames.indexOf('smf:customConfigSmartFolder') > -1 ||
|
||||
(node.entry.aspectNames.indexOf('smf:systemConfigSmartFolder') > -1));
|
||||
let nodeAspects = this.getNodeAspectNames(node);
|
||||
return nodeAspects.indexOf('smf:customConfigSmartFolder') > -1 ||
|
||||
(nodeAspects.indexOf('smf:systemConfigSmartFolder') > -1);
|
||||
}
|
||||
|
||||
private getNodeAspectNames(node: any): any[] {
|
||||
return node.entry && node.entry.aspectNames ? node.entry.aspectNames : node.aspectNames ? node.aspectNames : [];
|
||||
}
|
||||
|
||||
private sortRows(rows: DataRow[], sorting: DataSorting) {
|
||||
|
@@ -182,7 +182,7 @@ export class CustomResourcesService {
|
||||
*/
|
||||
loadSites(pagination: PaginationModel): Observable<NodePaging> {
|
||||
const options = {
|
||||
include: ['properties'],
|
||||
include: ['properties', 'aspectNames'],
|
||||
maxItems: pagination.maxItems,
|
||||
skipCount: pagination.skipCount
|
||||
};
|
||||
@@ -345,7 +345,7 @@ export class CustomResourcesService {
|
||||
}
|
||||
|
||||
private getIncludesFields(includeFields: string[]): string[] {
|
||||
return ['path', 'properties', 'allowableOperations', 'permissions', ...includeFields]
|
||||
return ['path', 'properties', 'allowableOperations', 'permissions', 'aspectNames', ...includeFields]
|
||||
.filter((element, index, array) => index === array.indexOf(element));
|
||||
}
|
||||
|
||||
|
@@ -168,7 +168,7 @@ describe('DocumentListService', () => {
|
||||
|
||||
expect(spyGetNodeInfo).toHaveBeenCalledWith('-root-', {
|
||||
includeSource: true,
|
||||
include: ['path', 'properties', 'allowableOperations', 'permissions', 'isLocked'],
|
||||
include: ['path', 'properties', 'allowableOperations', 'permissions', 'aspectNames', 'isLocked'],
|
||||
relativePath: '/fake-root/fake-name'
|
||||
});
|
||||
});
|
||||
@@ -180,7 +180,7 @@ describe('DocumentListService', () => {
|
||||
|
||||
expect(spyGetNodeInfo).toHaveBeenCalledWith('-root-', {
|
||||
includeSource: true,
|
||||
include: ['path', 'properties', 'allowableOperations', 'permissions'],
|
||||
include: ['path', 'properties', 'allowableOperations', 'permissions', 'aspectNames'],
|
||||
relativePath: '/fake-root/fake-name'
|
||||
});
|
||||
});
|
||||
@@ -192,7 +192,7 @@ describe('DocumentListService', () => {
|
||||
|
||||
expect(spyGetNodeInfo).toHaveBeenCalledWith('test-id', {
|
||||
includeSource: true,
|
||||
include: ['path', 'properties', 'allowableOperations', 'permissions', 'isLocked']
|
||||
include: ['path', 'properties', 'allowableOperations', 'permissions', 'aspectNames', 'isLocked']
|
||||
});
|
||||
});
|
||||
|
||||
@@ -203,7 +203,7 @@ describe('DocumentListService', () => {
|
||||
|
||||
expect(spyGetNodeInfo).toHaveBeenCalledWith('test-id', {
|
||||
includeSource: true,
|
||||
include: ['path', 'properties', 'allowableOperations', 'permissions']
|
||||
include: ['path', 'properties', 'allowableOperations', 'permissions', 'aspectNames']
|
||||
}
|
||||
);
|
||||
});
|
||||
|
@@ -44,7 +44,7 @@ export class DocumentListService {
|
||||
rootNodeId = opts.rootFolderId;
|
||||
}
|
||||
|
||||
let includeFieldsRequest = ['path', 'properties', 'allowableOperations', 'permissions', ...includeFields]
|
||||
let includeFieldsRequest = ['path', 'properties', 'allowableOperations', 'permissions', 'aspectNames', ...includeFields]
|
||||
.filter((element, index, array) => index === array.indexOf(element));
|
||||
|
||||
let params: any = {
|
||||
@@ -158,7 +158,7 @@ export class DocumentListService {
|
||||
*/
|
||||
getFolderNode(nodeId: string, includeFields: string[] = []): Observable<MinimalNodeEntryEntity> {
|
||||
|
||||
let includeFieldsRequest = ['path', 'properties', 'allowableOperations', 'permissions', ...includeFields]
|
||||
let includeFieldsRequest = ['path', 'properties', 'allowableOperations', 'permissions', 'aspectNames', ...includeFields]
|
||||
.filter((element, index, array) => index === array.indexOf(element));
|
||||
|
||||
let opts: any = {
|
||||
|
Reference in New Issue
Block a user