tslint arrow-parens rule (#4003)

This commit is contained in:
Eugenio Romano
2018-11-23 01:06:56 +00:00
committed by GitHub
parent 51bb6a420f
commit 34a30c0f14
194 changed files with 725 additions and 723 deletions

View File

@@ -59,7 +59,7 @@ export class AnalyticsReportListComponent implements OnInit {
reports: ReportParametersModel[] = [];
constructor(private analyticsService: AnalyticsService) {
this.report$ = new Observable<ReportParametersModel>(observer => this.reportObserver = observer)
this.report$ = new Observable<ReportParametersModel>((observer) => this.reportObserver = observer)
.pipe(share());
}
@@ -154,7 +154,7 @@ export class AnalyticsReportListComponent implements OnInit {
}
public selectReportByReportId(reportId) {
let reportFound = this.reports.find(report => report.id === reportId);
let reportFound = this.reports.find((report) => report.id === reportId);
if (reportFound) {
this.currentReport = reportFound;
this.reportClick.emit(reportFound);

View File

@@ -112,7 +112,7 @@ export class AnalyticsReportParametersComponent implements OnInit, OnChanges, On
ngOnInit() {
this.dropDownSub = this.onDropdownChanged.subscribe((field) => {
let paramDependOn: ReportParameterDetailsModel = this.reportParameters.definition.parameters.find(p => p.dependsOn === field.id);
let paramDependOn: ReportParameterDetailsModel = this.reportParameters.definition.parameters.find((p) => p.dependsOn === field.id);
if (paramDependOn) {
this.retrieveParameterOptions(this.reportParameters.definition.parameters, this.appId, this.reportId, field.value);
}
@@ -191,8 +191,8 @@ export class AnalyticsReportParametersComponent implements OnInit, OnChanges, On
}
});
this.reportForm = this.formBuilder.group(formBuilderGroup);
this.reportForm.valueChanges.subscribe(data => this.onValueChanged(data));
this.reportForm.statusChanges.subscribe(data => this.onStatusChanged(data));
this.reportForm.valueChanges.subscribe((data) => this.onValueChanged(data));
this.reportForm.statusChanges.subscribe((data) => this.onStatusChanged(data));
}
public getReportParams(reportId: string) {
@@ -368,7 +368,7 @@ export class AnalyticsReportParametersComponent implements OnInit, OnChanges, On
deleteReport(reportId: string) {
this.analyticsService.deleteReport(reportId).subscribe(() => {
this.deleteReportSuccess.emit(reportId);
}, error => this.logService.error(error));
}, (error) => this.logService.error(error));
}
ngAfterContentChecked() {

View File

@@ -53,7 +53,7 @@ export class AnalyticsService {
});
return reports;
}),
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}
@@ -65,9 +65,9 @@ export class AnalyticsService {
return from(this.apiService.getInstance().activiti.reportApi.getReportList())
.pipe(
map((response: any) => {
return response.find(report => report.name === reportName);
return response.find((report) => report.name === reportName);
}),
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}
@@ -85,7 +85,7 @@ export class AnalyticsService {
map((res: any) => {
return new ReportParametersModel(res);
}),
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}
@@ -103,7 +103,7 @@ export class AnalyticsService {
} else if (type === 'task' && reportId && processDefinitionId) {
return this.getTasksByProcessDefinitionId(reportId, processDefinitionId);
} else {
return new Observable(observer => {
return new Observable((observer) => {
observer.next(null);
observer.complete();
});
@@ -117,7 +117,7 @@ export class AnalyticsService {
paramOptions.push(new ParameterValueModel({ id: 'Active', name: 'Active' }));
paramOptions.push(new ParameterValueModel({ id: 'Complete', name: 'Complete' }));
return new Observable(observer => {
return new Observable((observer) => {
observer.next(paramOptions);
observer.complete();
});
@@ -132,7 +132,7 @@ export class AnalyticsService {
paramOptions.push(new ParameterValueModel({ id: 'byMonth', name: 'By month' }));
paramOptions.push(new ParameterValueModel({ id: 'byYear', name: 'By year' }));
return new Observable(observer => {
return new Observable((observer) => {
observer.next(paramOptions);
observer.complete();
});
@@ -145,7 +145,7 @@ export class AnalyticsService {
paramOptions.push(new ParameterValueModel({ id: 'totalTime', name: 'Total time spent in a process step' }));
paramOptions.push(new ParameterValueModel({ id: 'avgTime', name: 'Average time spent in a process step' }));
return new Observable(observer => {
return new Observable((observer) => {
observer.next(paramOptions);
observer.complete();
});
@@ -161,7 +161,7 @@ export class AnalyticsService {
});
return paramOptions;
}),
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}
@@ -176,7 +176,7 @@ export class AnalyticsService {
});
return paramOptions;
}),
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}
@@ -190,7 +190,7 @@ export class AnalyticsService {
});
return paramOptions;
}),
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}
@@ -217,7 +217,7 @@ export class AnalyticsService {
return elements;
}),
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}
@@ -225,7 +225,7 @@ export class AnalyticsService {
return from(this.apiService.getInstance().activiti.reportApi.createDefaultReports())
.pipe(
map(this.toJson),
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}
@@ -233,7 +233,7 @@ export class AnalyticsService {
return from(this.apiService.getInstance().activiti.reportApi.updateReport(reportId, name))
.pipe(
map(() => this.logService.info('upload')),
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}
@@ -244,7 +244,7 @@ export class AnalyticsService {
this.logService.info('export');
return res;
}),
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}
@@ -254,7 +254,7 @@ export class AnalyticsService {
map(() => {
this.logService.info('save');
}),
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}
@@ -264,7 +264,7 @@ export class AnalyticsService {
map(() => {
this.logService.info('delete');
}),
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}

View File

@@ -78,9 +78,9 @@ export class RaphaelMultilineTextDirective extends RaphaelBase implements OnInit
let letterWidth = textPaper.getBBox().width / text.length;
let removedLineBreaks = text.split('\n');
let actualRowLength = 0, formattedText = [];
removedLineBreaks.forEach(sentence => {
removedLineBreaks.forEach((sentence) => {
let words = sentence.split(' ');
words.forEach(word => {
words.forEach((word) => {
let length = word.length;
if (actualRowLength + (length * letterWidth) > elementWidth) {
formattedText.push('\n');

View File

@@ -30,14 +30,14 @@ export class DiagramsService {
getProcessDefinitionModel(processDefinitionId: string): Observable<any> {
return from(this.apiService.getInstance().activiti.modelJsonBpmnApi.getModelJSON(processDefinitionId))
.pipe(
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}
getRunningProcessDefinitionModel(processInstanceId: string): Observable<any> {
return from(this.apiService.getInstance().activiti.modelJsonBpmnApi.getModelJSONForProcessDefinition(processInstanceId))
.pipe(
catchError(err => this.handleError(err))
catchError((err) => this.handleError(err))
);
}