[ADF-1873] Remove all deprecated code from ADF (#4145)

* remove deprecated code part 1

* remove deprecation step 2

* fix spellcheck

* fix

* fix lint

* fix not used import

* remove deprecation

* fix test first part after remove deprecation

* fix test

* fix sidebar demo shell
This commit is contained in:
Eugenio Romano
2019-01-15 15:36:01 +00:00
committed by GitHub
parent 24a7c939e6
commit 7d061b2c11
109 changed files with 351 additions and 1106 deletions

View File

@@ -21,9 +21,8 @@ import { ReportParametersModel } from '../../diagram/models/report/reportParamet
import { AnalyticsService } from '../services/analytics.service';
import { share } from 'rxjs/operators';
// @deprecated 2.3.0 analytics-report-list tag removed
@Component({
selector: 'adf-analytics-report-list, analytics-report-list',
selector: 'adf-analytics-report-list',
templateUrl: './analytics-report-list.component.html',
styleUrls: ['./analytics-report-list.component.scss'],
encapsulation: ViewEncapsulation.None

View File

@@ -38,9 +38,8 @@ import { ReportParametersModel } from '../../diagram/models/report/reportParamet
import { ReportQuery } from '../../diagram/models/report/reportQuery.model';
import { AnalyticsService } from '../services/analytics.service';
// @deprecated 2.3.0 analytics-report-parameters tag removed
@Component({
selector: 'adf-analytics-report-parameters, analytics-report-parameters',
selector: 'adf-analytics-report-parameters',
templateUrl: './analytics-report-parameters.component.html',
styleUrls: ['./analytics-report-parameters.component.scss'],
encapsulation: ViewEncapsulation.None

View File

@@ -1,12 +1,12 @@
<div class="adf-analytics-container">
<analytics-report-parameters [appId]="appId" [reportId]="reportId"
<adf-analytics-report-parameters [appId]="appId" [reportId]="reportId"
[hideComponent]="hideParameters"
(formValueChanged)="reset()"
(success)="showReport($event)"
(saveReportSuccess)="onSaveReportSuccess($event)"
(deleteReportSuccess)="onDeleteReportSuccess()"
(edit)="onEditReport($event)">
</analytics-report-parameters>
</adf-analytics-report-parameters>
<adf-analytics-generator [reportId]="reportId"
[reportParamQuery]="reportParamQuery"

View File

@@ -17,7 +17,7 @@
/* tslint:disable:no-input-rename */
import { MOMENT_DATE_FORMATS, MomentDateAdapter, UserPreferencesService } from '@alfresco/adf-core';
import { MOMENT_DATE_FORMATS, MomentDateAdapter, UserPreferencesService, UserPreferenceValues } from '@alfresco/adf-core';
import { Component, EventEmitter, Input, OnInit, Output, ViewEncapsulation } from '@angular/core';
import { AbstractControl, FormControl, FormGroup, Validators } from '@angular/forms';
import { DateAdapter, MAT_DATE_FORMATS } from '@angular/material';
@@ -54,13 +54,14 @@ export class DateRangeWidgetComponent implements OnInit {
constructor(
private dateAdapter: DateAdapter<Moment>,
private preferences: UserPreferencesService) {
private userPreferencesService: UserPreferencesService) {
}
ngOnInit() {
this.preferences.locale$.subscribe( (locale) => {
this.userPreferencesService.select(UserPreferenceValues.Locale).subscribe((locale) => {
this.dateAdapter.setLocale(locale);
});
let momentDateAdapter = <MomentDateAdapter> this.dateAdapter;
momentDateAdapter.overrideDisplayFormat = this.SHOW_FORMAT;

View File

@@ -17,9 +17,8 @@
import { Component, ElementRef, EventEmitter, Input, OnInit, Output } from '@angular/core';
// @deprecated 2.3.0 diagram-alfresco-publish-task tag removed
@Component({
selector: 'adf-diagram-publish-task, diagram-alfresco-publish-task',
selector: 'adf-diagram-publish-task',
templateUrl: './diagram-alfresco-publish-task.component.html'
})
export class DiagramAlfrescoPublishTaskComponent implements OnInit {

View File

@@ -17,9 +17,8 @@
import { Component, ElementRef, EventEmitter, Input, OnInit, Output } from '@angular/core';
// @deprecated 2.3.0 diagram-sequence-flow tag removed
@Component({
selector: 'adf-diagram-sequence-flow, diagram-sequence-flow',
selector: 'adf-diagram-sequence-flow',
templateUrl: './diagram-sequence-flow.component.html'
})
export class DiagramSequenceFlowComponent implements OnInit {

View File

@@ -69,7 +69,7 @@ describe('Diagrams flows', () => {
fixture.detectChanges();
fixture.whenStable().then(() => {
expect(res).not.toBeNull();
let shape: any = element.querySelector('diagram-sequence-flow > raphael-flow-arrow');
let shape: any = element.querySelector('adf-diagram-sequence-flow > raphael-flow-arrow');
expect(shape).not.toBeNull();
let tooltip: any = element.querySelector('diagram-tooltip > div');
@@ -90,7 +90,7 @@ describe('Diagrams flows', () => {
fixture.detectChanges();
fixture.whenStable().then(() => {
expect(res).not.toBeNull();
let shape: any = element.querySelector('diagram-sequence-flow > raphael-flow-arrow');
let shape: any = element.querySelector('adf-diagram-sequence-flow > raphael-flow-arrow');
expect(shape).not.toBeNull();
let tooltip: any = element.querySelector('diagram-tooltip > div');

View File

@@ -57,7 +57,7 @@
<div *ngFor="let flow of diagram.flows">
<div [ngSwitch]="flow.type">
<div *ngSwitchCase="'sequenceFlow'">
<diagram-sequence-flow [flow]="flow"></diagram-sequence-flow>
<adf-diagram-sequence-flow [flow]="flow"></adf-diagram-sequence-flow>
</div>
</div>
</div>