mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-05-26 17:24:56 +00:00
Fix tests and loading rows regression
This commit is contained in:
parent
f596dd7a06
commit
ae809266ea
@ -52,9 +52,8 @@ describe('ContentColumn', () => {
|
||||
});
|
||||
|
||||
it('should setup screen reader title for thumbnail column', () => {
|
||||
let column = new ContentColumn(columnList, {
|
||||
key: '$thumbnail'
|
||||
});
|
||||
let column = new ContentColumn(columnList);
|
||||
column.key = '$thumbnail';
|
||||
column.ngOnInit();
|
||||
|
||||
expect(column.srTitle).toBe('Thumbnail');
|
||||
|
@ -49,17 +49,7 @@ export class ContentColumn implements OnInit, DataColumn {
|
||||
@Input('class')
|
||||
cssClass: string;
|
||||
|
||||
constructor(private list: ContentColumnList, opts?: any) {
|
||||
if (opts) {
|
||||
this.key = opts.key;
|
||||
this.type = opts.type || 'text';
|
||||
this.format = opts.format;
|
||||
this.sortable = opts.sortable ? true : false;
|
||||
this.title = opts.title || '';
|
||||
this.srTitle = opts.srTitle;
|
||||
this.cssClass = opts.cssClass;
|
||||
}
|
||||
}
|
||||
constructor(private list: ContentColumnList) {}
|
||||
|
||||
ngOnInit() {
|
||||
if (!this.srTitle && this.key === '$thumbnail') {
|
||||
|
@ -184,7 +184,7 @@ export class ShareDataTableAdapter implements DataTableAdapter {
|
||||
}
|
||||
}
|
||||
|
||||
this.rows = [];
|
||||
this.rows = rows;
|
||||
},
|
||||
error => console.log(error));
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user