mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
[ADF-506] Unify thumbnail service (#2014)
* move thumbnail service in core * fix folder
This commit is contained in:
@@ -28,33 +28,6 @@ export class ObjectDataTableAdapter implements DataTableAdapter {
|
||||
private _sorting: DataSorting;
|
||||
private _rows: DataRow[];
|
||||
private _columns: DataColumn[];
|
||||
private icons: string[] = [
|
||||
'empty_doc_lib.svg',
|
||||
'ft_ic_archive.svg',
|
||||
'ft_ic_audio.svg',
|
||||
'ft_ic_database.svg',
|
||||
'ft_ic_document.svg',
|
||||
'ft_ic_ebook.svg',
|
||||
'ft_ic_folder.svg',
|
||||
'ft_ic_folder_empty.svg',
|
||||
'ft_ic_form.svg',
|
||||
'ft_ic_google_docs.svg',
|
||||
'ft_ic_google_drawings.svg',
|
||||
'ft_ic_google_forms.svg',
|
||||
'ft_ic_google_sheets.svg',
|
||||
'ft_ic_google_slides.svg',
|
||||
'ft_ic_miscellaneous.svg',
|
||||
'ft_ic_ms_excel.svg',
|
||||
'ft_ic_ms_powerpoint.svg',
|
||||
'ft_ic_ms_word.svg',
|
||||
'ft_ic_pdf.svg',
|
||||
'ft_ic_presentation.svg',
|
||||
'ft_ic_raster_image.svg',
|
||||
'ft_ic_spreadsheet.svg',
|
||||
'ft_ic_vector_image.svg',
|
||||
'ft_ic_video.svg',
|
||||
'ft_ic_website.svg'
|
||||
];
|
||||
|
||||
selectedRow: DataRow;
|
||||
|
||||
@@ -142,20 +115,13 @@ export class ObjectDataTableAdapter implements DataTableAdapter {
|
||||
}
|
||||
|
||||
if (col.type === 'icon') {
|
||||
const iconName = row.getValue(col.key);
|
||||
if (this.icons.indexOf(iconName) > -1) {
|
||||
return this.getImagePath(iconName);
|
||||
}
|
||||
return this.getImagePath('ft_ic_miscellaneous.svg');
|
||||
const icon = row.getValue(col.key);
|
||||
return icon;
|
||||
}
|
||||
|
||||
return value;
|
||||
}
|
||||
|
||||
getImagePath(id: string): any {
|
||||
return require('./../assets/images/' + id);
|
||||
}
|
||||
|
||||
getSorting(): DataSorting {
|
||||
return this._sorting;
|
||||
}
|
||||
|
Reference in New Issue
Block a user