mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
enable prefer-const rule for tslint, fix issues (#4409)
* enable prefer-const rule for tslint, fix issues * Update content-node-selector.component.spec.ts * Update content-node-selector.component.spec.ts * fix const * fix lint issues * update tests * update tests * update tests * fix code * fix page class
This commit is contained in:
committed by
Eugenio Romano
parent
26c5982a1a
commit
a7a48e8b2b
@@ -51,7 +51,7 @@ export class DocumentActionsService {
|
||||
*/
|
||||
getHandler(key: string): ContentActionHandler {
|
||||
if (key) {
|
||||
let lKey = key.toLowerCase();
|
||||
const lKey = key.toLowerCase();
|
||||
return this.handlers[lKey] || null;
|
||||
}
|
||||
return null;
|
||||
@@ -65,7 +65,7 @@ export class DocumentActionsService {
|
||||
*/
|
||||
setHandler(key: string, handler: ContentActionHandler): boolean {
|
||||
if (key) {
|
||||
let lKey = key.toLowerCase();
|
||||
const lKey = key.toLowerCase();
|
||||
this.handlers[lKey] = handler;
|
||||
return true;
|
||||
}
|
||||
@@ -125,10 +125,10 @@ export class DocumentActionsService {
|
||||
if (this.contentService.hasAllowableOperations(node.entry, permission)) {
|
||||
handlerObservable = this.documentListService.deleteNode(node.entry.id);
|
||||
handlerObservable.subscribe(() => {
|
||||
let message = this.translation.instant('CORE.DELETE_NODE.SINGULAR', { name: node.entry.name });
|
||||
const message = this.translation.instant('CORE.DELETE_NODE.SINGULAR', { name: node.entry.name });
|
||||
this.success.next(message);
|
||||
}, () => {
|
||||
let message = this.translation.instant('CORE.DELETE_NODE.ERROR_SINGULAR', { name: node.entry.name });
|
||||
const message = this.translation.instant('CORE.DELETE_NODE.ERROR_SINGULAR', { name: node.entry.name });
|
||||
this.error.next(message);
|
||||
});
|
||||
return handlerObservable;
|
||||
|
Reference in New Issue
Block a user