mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-31 17:38:48 +00:00
fix "ng lint" command (#5012)
* update to latest js-api * fix the "ng lint" command * fix linting issues * fix lint issues * lint fixes * code fixes * fix html * fix html * update tests * test fixes * update tests * fix tests and api * fix code
This commit is contained in:
committed by
Eugenio Romano
parent
140c64b79f
commit
edc0945f39
@@ -74,12 +74,12 @@ export class ChecklistComponent implements OnChanges {
|
||||
ngOnChanges(changes: SimpleChanges) {
|
||||
const taskId = changes['taskId'];
|
||||
if (taskId && taskId.currentValue) {
|
||||
this.getTaskChecklist(taskId.currentValue);
|
||||
this.getTaskChecklist();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
public getTaskChecklist(taskId: string) {
|
||||
getTaskChecklist() {
|
||||
this.checklist = [];
|
||||
if (this.taskId) {
|
||||
this.activitiTaskList.getTaskChecklist(this.taskId).subscribe(
|
||||
|
@@ -48,12 +48,8 @@ describe('TaskAuditDirective', () => {
|
||||
download: boolean = false;
|
||||
fileName: string;
|
||||
format: string;
|
||||
constructor() {
|
||||
|
||||
}
|
||||
|
||||
onAuditClick(event: any) {
|
||||
}
|
||||
onAuditClick() {}
|
||||
}
|
||||
|
||||
let fixture: ComponentFixture<BasicButtonComponent>;
|
||||
|
@@ -18,7 +18,7 @@
|
||||
/* tslint:disable:no-input-rename */
|
||||
|
||||
import { ContentService } from '@alfresco/adf-core';
|
||||
import { Directive, EventEmitter, Input, OnChanges, Output, SimpleChanges } from '@angular/core';
|
||||
import { Directive, EventEmitter, Input, OnChanges, Output } from '@angular/core';
|
||||
import { TaskListService } from './../services/tasklist.service';
|
||||
|
||||
const JSON_FORMAT: string = 'json';
|
||||
@@ -68,7 +68,7 @@ export class TaskAuditDirective implements OnChanges {
|
||||
private taskListService: TaskListService) {
|
||||
}
|
||||
|
||||
ngOnChanges(changes: SimpleChanges): void {
|
||||
ngOnChanges(): void {
|
||||
if (!this.isValidType()) {
|
||||
this.setDefaultFormatType();
|
||||
}
|
||||
|
@@ -151,7 +151,7 @@ describe('TaskDetailsComponent', () => {
|
||||
expect(fixture.debugElement.query(By.css('adf-form'))).not.toBeNull();
|
||||
}));
|
||||
|
||||
it('should display a form in readonly when the task has an associated form and readOnlyForm is true', async((done) => {
|
||||
it('should display a form in readonly when the task has an associated form and readOnlyForm is true', async(() => {
|
||||
component.readOnlyForm = true;
|
||||
component.taskId = '123';
|
||||
fixture.detectChanges();
|
||||
|
@@ -52,7 +52,7 @@ describe('TaskFiltersComponent', () => {
|
||||
filter: { state: 'open', assignment: 'fake-assignee' }
|
||||
}));
|
||||
|
||||
const fakeGlobalFilterPromise = new Promise(function (resolve, reject) {
|
||||
const fakeGlobalFilterPromise = new Promise(function (resolve) {
|
||||
resolve(fakeGlobalFilter);
|
||||
});
|
||||
|
||||
@@ -60,7 +60,7 @@ describe('TaskFiltersComponent', () => {
|
||||
message: 'invalid data'
|
||||
};
|
||||
|
||||
const fakeGlobalEmptyFilterPromise = new Promise(function (resolve, reject) {
|
||||
const fakeGlobalEmptyFilterPromise = new Promise(function (resolve) {
|
||||
resolve(fakeGlobalEmptyFilter);
|
||||
});
|
||||
|
||||
@@ -126,7 +126,7 @@ describe('TaskFiltersComponent', () => {
|
||||
|
||||
it('should return the filter task list, filtered By Name', (done) => {
|
||||
|
||||
const fakeDeployedApplicationsPromise = new Promise(function (resolve, reject) {
|
||||
const fakeDeployedApplicationsPromise = new Promise(function (resolve) {
|
||||
resolve({});
|
||||
});
|
||||
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { Component, EventEmitter, Input, OnChanges, OnInit, Output, SimpleChanges } from '@angular/core';
|
||||
import { Component, EventEmitter, Input, OnChanges, OnInit, Output } from '@angular/core';
|
||||
import {
|
||||
BpmUserService,
|
||||
CardViewDateItemModel,
|
||||
@@ -75,7 +75,7 @@ export class TaskHeaderComponent implements OnChanges, OnInit {
|
||||
this.loadCurrentBpmUserId();
|
||||
}
|
||||
|
||||
ngOnChanges(changes: SimpleChanges) {
|
||||
ngOnChanges() {
|
||||
this.refreshData();
|
||||
}
|
||||
|
||||
|
@@ -249,13 +249,13 @@ export class TaskListComponent extends DataTableSchema implements OnChanges, Aft
|
||||
reload(): void {
|
||||
if (!this.hasCustomDataSource) {
|
||||
this.requestNode = this.createRequestNode();
|
||||
this.load(this.requestNode);
|
||||
this.load();
|
||||
} else {
|
||||
this.isLoading = false;
|
||||
}
|
||||
}
|
||||
|
||||
private load(requestNode: TaskQueryRequestRepresentationModel) {
|
||||
private load() {
|
||||
this.isLoading = true;
|
||||
this.loadTasksByState().subscribe(
|
||||
(tasks) => {
|
||||
|
Reference in New Issue
Block a user