mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-1968] [IE11] The login page is not loading and import fix (#2679)
* fix viewer script export insights and diagram remove requires svg fix new data adapter path dist working with diagrams commented out change use of minimatch fix unused import remove unused component fix test new import moment es6 and throw rxjs fix import analytics test fix imports rxjs new pacakging * fix after rebase * fix test upload services * exclude temporarily button event test * restore commented demo shell files * fix process spy
This commit is contained in:
@@ -32,7 +32,7 @@ import {
|
||||
|
||||
import { FormRenderingService } from './../../services/form-rendering.service';
|
||||
import { WidgetVisibilityService } from './../../services/widget-visibility.service';
|
||||
import { FormFieldModel } from './../widgets/core/index';
|
||||
import { FormFieldModel } from './../widgets/core/form-field.model';
|
||||
import { WidgetComponent } from './../widgets/widget.component';
|
||||
|
||||
declare var adf: any;
|
||||
|
@@ -18,9 +18,9 @@
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { By } from '@angular/platform-browser';
|
||||
import { TranslationService } from '../../index';
|
||||
import { DataTableModule } from '../../datatable';
|
||||
import { DataColumnModule } from '../../data-column';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { DataTableModule } from '../../datatable/datatable.module';
|
||||
import { DataColumnModule } from '../../data-column/data-column.module';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { EcmModelService } from '../services/ecm-model.service';
|
||||
import { FormService } from '../services/form.service';
|
||||
import { FormListComponent } from './form-list.component';
|
||||
|
@@ -16,8 +16,8 @@
|
||||
*/
|
||||
|
||||
import { SimpleChange } from '@angular/core';
|
||||
import { LogService } from '../../services';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { LogService } from '../../services/log.service';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { fakeForm } from '../../mock';
|
||||
import { FormService } from './../services/form.service';
|
||||
import { NodeService } from './../services/node.service';
|
||||
|
@@ -23,7 +23,7 @@ import { FormService } from './../services/form.service';
|
||||
import { NodeService } from './../services/node.service';
|
||||
import { ContentLinkModel } from './widgets/core/content-link.model';
|
||||
import { FormFieldModel, FormModel, FormOutcomeEvent, FormOutcomeModel, FormValues, FormFieldValidator } from './widgets/core/index';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { WidgetVisibilityService } from './../services/widget-visibility.service';
|
||||
|
||||
@Component({
|
||||
|
@@ -16,8 +16,8 @@
|
||||
*/
|
||||
|
||||
import { CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
|
||||
import { DebugElement, SimpleChange } from '@angular/core';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { SimpleChange } from '@angular/core';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
|
||||
import { async, ComponentFixture, fakeAsync, TestBed, tick } from '@angular/core/testing';
|
||||
import { By } from '@angular/platform-browser';
|
||||
@@ -36,13 +36,9 @@ const SELECT_OPEN_ANIMATION = 200;
|
||||
const SELECT_CLOSE_ANIMATION = 500;
|
||||
|
||||
describe('FormComponent UI and visibiltiy', () => {
|
||||
let debugElement: DebugElement;
|
||||
let element: HTMLElement;
|
||||
let component: FormComponent;
|
||||
let service: FormService;
|
||||
let fixture: ComponentFixture<FormComponent>;
|
||||
let formDefinitionSpy: jasmine.Spy;
|
||||
let taskSpy: jasmine.Spy;
|
||||
|
||||
function openSelect() {
|
||||
let trigger: HTMLElement;
|
||||
@@ -63,8 +59,6 @@ describe('FormComponent UI and visibiltiy', () => {
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(FormComponent);
|
||||
component = fixture.componentInstance;
|
||||
element = fixture.nativeElement;
|
||||
debugElement = fixture.debugElement;
|
||||
service = fixture.debugElement.injector.get(FormService);
|
||||
});
|
||||
|
||||
@@ -75,8 +69,8 @@ describe('FormComponent UI and visibiltiy', () => {
|
||||
describe('form definition', () => {
|
||||
|
||||
it('should display two text fields form definition', () => {
|
||||
taskSpy = spyOn(service, 'getTask').and.returnValue(Observable.of({}));
|
||||
formDefinitionSpy = spyOn(service, 'getTaskForm').and.returnValue(Observable.of(formDefinitionTwoTextFields));
|
||||
spyOn(service, 'getTask').and.returnValue(Observable.of({}));
|
||||
spyOn(service, 'getTaskForm').and.returnValue(Observable.of(formDefinitionTwoTextFields));
|
||||
|
||||
let change = new SimpleChange(null, 1, true);
|
||||
component.ngOnChanges({ 'taskId': change });
|
||||
@@ -92,8 +86,8 @@ describe('FormComponent UI and visibiltiy', () => {
|
||||
});
|
||||
|
||||
it('should display dropdown field', fakeAsync(() => {
|
||||
taskSpy = spyOn(service, 'getTask').and.returnValue(Observable.of({}));
|
||||
formDefinitionSpy = spyOn(service, 'getTaskForm').and.returnValue(Observable.of(formDefinitionDropdownField));
|
||||
spyOn(service, 'getTask').and.returnValue(Observable.of({}));
|
||||
spyOn(service, 'getTaskForm').and.returnValue(Observable.of(formDefinitionDropdownField));
|
||||
|
||||
let change = new SimpleChange(null, 1, true);
|
||||
component.ngOnChanges({ 'taskId': change });
|
||||
@@ -123,8 +117,8 @@ describe('FormComponent UI and visibiltiy', () => {
|
||||
describe('Visibility conditions', () => {
|
||||
|
||||
it('should hide the field based on the next one', () => {
|
||||
taskSpy = spyOn(service, 'getTask').and.returnValue(Observable.of({}));
|
||||
formDefinitionSpy = spyOn(service, 'getTaskForm').and.returnValue(Observable.of(formDefVisibilitiFieldDependsOnNextOne));
|
||||
spyOn(service, 'getTask').and.returnValue(Observable.of({}));
|
||||
spyOn(service, 'getTaskForm').and.returnValue(Observable.of(formDefVisibilitiFieldDependsOnNextOne));
|
||||
|
||||
let change = new SimpleChange(null, 1, true);
|
||||
component.ngOnChanges({ 'taskId': change });
|
||||
@@ -139,8 +133,8 @@ describe('FormComponent UI and visibiltiy', () => {
|
||||
});
|
||||
|
||||
it('should hide the field based on the previous one', () => {
|
||||
taskSpy = spyOn(service, 'getTask').and.returnValue(Observable.of({}));
|
||||
formDefinitionSpy = spyOn(service, 'getTaskForm').and.returnValue(Observable.of(formDefVisibilitiFieldDependsOnPreviousOne));
|
||||
spyOn(service, 'getTask').and.returnValue(Observable.of({}));
|
||||
spyOn(service, 'getTaskForm').and.returnValue(Observable.of(formDefVisibilitiFieldDependsOnPreviousOne));
|
||||
|
||||
let change = new SimpleChange(null, 1, true);
|
||||
component.ngOnChanges({ 'taskId': change });
|
||||
@@ -155,8 +149,8 @@ describe('FormComponent UI and visibiltiy', () => {
|
||||
});
|
||||
|
||||
it('should show the hidden field when the visibility condition change to true', () => {
|
||||
taskSpy = spyOn(service, 'getTask').and.returnValue(Observable.of({}));
|
||||
formDefinitionSpy = spyOn(service, 'getTaskForm').and.returnValue(Observable.of(formDefVisibilitiFieldDependsOnNextOne));
|
||||
spyOn(service, 'getTask').and.returnValue(Observable.of({}));
|
||||
spyOn(service, 'getTaskForm').and.returnValue(Observable.of(formDefVisibilitiFieldDependsOnNextOne));
|
||||
|
||||
let change = new SimpleChange(null, 1, true);
|
||||
component.ngOnChanges({ 'taskId': change });
|
||||
@@ -181,8 +175,8 @@ describe('FormComponent UI and visibiltiy', () => {
|
||||
|
||||
describe('Readonly Form', () => {
|
||||
it('should display two text fields readonly', () => {
|
||||
taskSpy = spyOn(service, 'getTask').and.returnValue(Observable.of({}));
|
||||
formDefinitionSpy = spyOn(service, 'getTaskForm').and.returnValue(Observable.of(formReadonlyTwoTextFields));
|
||||
spyOn(service, 'getTask').and.returnValue(Observable.of({}));
|
||||
spyOn(service, 'getTaskForm').and.returnValue(Observable.of(formReadonlyTwoTextFields));
|
||||
|
||||
let change = new SimpleChange(null, 1, true);
|
||||
component.ngOnChanges({ 'taskId': change });
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
import { CUSTOM_ELEMENTS_SCHEMA, SimpleChange } from '@angular/core';
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { EntryComponentMockModule } from '../../mock/form/entry-module.mock';
|
||||
import { startFormDateWidgetMock, startFormDropdownDefinitionMock, startFormTextDefinitionMock, startMockForm, startMockFormWithTab } from '../../mock';
|
||||
import { startFormAmountWidgetMock, startFormNumberWidgetMock, startFormRadioButtonWidgetMock } from '../../mock';
|
||||
@@ -37,7 +37,6 @@ describe('ActivitiStartForm', () => {
|
||||
|
||||
let formService: FormService;
|
||||
let component: StartFormComponent;
|
||||
let element: HTMLElement;
|
||||
let fixture: ComponentFixture<StartFormComponent>;
|
||||
let getStartFormSpy: jasmine.Spy;
|
||||
|
||||
@@ -72,7 +71,6 @@ describe('ActivitiStartForm', () => {
|
||||
fixture = TestBed.createComponent(StartFormComponent);
|
||||
component = fixture.componentInstance;
|
||||
formService = fixture.debugElement.injector.get(FormService);
|
||||
element = fixture.nativeElement;
|
||||
|
||||
getStartFormSpy = spyOn(formService, 'getStartFormDefinition').and.returnValue(Observable.of({
|
||||
processDefinitionName: 'my:process'
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { LogService } from '../../services';
|
||||
import { LogService } from '../../services/log.service';
|
||||
import { Component, ElementRef, EventEmitter, Input, OnChanges, OnInit, Output, SimpleChanges, ViewChild, ViewEncapsulation } from '@angular/core';
|
||||
import { FormService } from './../services/form.service';
|
||||
import { WidgetVisibilityService } from './../services/widget-visibility.service';
|
||||
|
@@ -16,7 +16,7 @@
|
||||
*/
|
||||
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { ActivitiContentService } from '../../../services/activiti-alfresco.service';
|
||||
import { MaterialModule } from '../../../../material.module';
|
||||
import { ExternalContent } from '../core/external-content';
|
||||
@@ -33,7 +33,6 @@ describe('AttachWidgetComponent', () => {
|
||||
|
||||
let widget: AttachWidgetComponent;
|
||||
let fixture: ComponentFixture<AttachWidgetComponent>;
|
||||
let element: HTMLElement;
|
||||
let contentService: ActivitiContentService;
|
||||
|
||||
beforeEach(async(() => {
|
||||
@@ -57,7 +56,6 @@ describe('AttachWidgetComponent', () => {
|
||||
fixture = TestBed.createComponent(AttachWidgetComponent);
|
||||
contentService = TestBed.get(ActivitiContentService);
|
||||
|
||||
element = fixture.nativeElement;
|
||||
widget = fixture.componentInstance;
|
||||
});
|
||||
|
||||
|
@@ -37,7 +37,6 @@ describe('ContainerWidgetComponent', () => {
|
||||
let widget: ContainerWidgetComponent;
|
||||
let fixture: ComponentFixture<ContainerWidgetComponent>;
|
||||
let element: HTMLElement;
|
||||
let contentService: ActivitiContentService;
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
@@ -55,7 +54,6 @@ describe('ContainerWidgetComponent', () => {
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(ContainerWidgetComponent);
|
||||
contentService = TestBed.get(ActivitiContentService);
|
||||
|
||||
element = fixture.nativeElement;
|
||||
widget = fixture.componentInstance;
|
||||
|
@@ -15,12 +15,12 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { DebugElement, SimpleChange } from '@angular/core';
|
||||
import { SimpleChange } from '@angular/core';
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { MaterialModule } from '../../../../material.module';
|
||||
import { By } from '@angular/platform-browser';
|
||||
import { TranslationService, ContentService } from '../../../../services';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
|
||||
import { EcmModelService } from '../../../services/ecm-model.service';
|
||||
import { FormService } from '../../../services/form.service';
|
||||
@@ -34,10 +34,8 @@ describe('ContentWidgetComponent', () => {
|
||||
|
||||
let component: ContentWidgetComponent;
|
||||
let fixture: ComponentFixture<ContentWidgetComponent>;
|
||||
let debug: DebugElement;
|
||||
let element: HTMLElement;
|
||||
|
||||
let serviceForm: FormService;
|
||||
let processContentService: ProcessContentService;
|
||||
let serviceContent: ContentService;
|
||||
|
||||
@@ -80,7 +78,6 @@ describe('ContentWidgetComponent', () => {
|
||||
]
|
||||
}).compileComponents();
|
||||
|
||||
serviceForm = TestBed.get(FormService);
|
||||
serviceContent = TestBed.get(ContentService);
|
||||
processContentService = TestBed.get(ProcessContentService);
|
||||
|
||||
@@ -94,7 +91,6 @@ describe('ContentWidgetComponent', () => {
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(ContentWidgetComponent);
|
||||
component = fixture.componentInstance;
|
||||
debug = fixture.debugElement;
|
||||
element = fixture.nativeElement;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
@@ -15,9 +15,10 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { ContentService, LogService } from '../../../../services';
|
||||
import { ContentService } from '../../../../services/content.service';
|
||||
import { LogService } from '../../../../services/log.service';
|
||||
import { Component, EventEmitter, Input, OnChanges, Output, SimpleChanges, ViewEncapsulation } from '@angular/core';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { ProcessContentService } from '../../../services/process-content.service';
|
||||
import { ContentLinkModel } from '../core/content-link.model';
|
||||
import { FormService } from './../../../services/form.service';
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
/* tslint:disable:component-selector */
|
||||
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment-es6';
|
||||
import { FormFieldTypes } from './form-field-types';
|
||||
import { FormFieldModel } from './form-field.model';
|
||||
|
||||
|
@@ -16,7 +16,7 @@
|
||||
*/
|
||||
|
||||
/* tslint:disable:component-selector */
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment-es6';
|
||||
import { WidgetVisibilityModel } from '../../../models/widget-visibility.model';
|
||||
import { ContainerColumnModel } from './container-column.model';
|
||||
import { ErrorMessageModel } from './error-message.model';
|
||||
|
@@ -16,7 +16,7 @@
|
||||
*/
|
||||
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment-es6';
|
||||
import { ActivitiContentService } from '../../../services/activiti-alfresco.service';
|
||||
import { MaterialModule } from '../../../../material.module';
|
||||
import { ErrorWidgetComponent } from '../error/error.component';
|
||||
@@ -30,7 +30,6 @@ describe('DateWidgetComponent', () => {
|
||||
|
||||
let widget: DateWidgetComponent;
|
||||
let fixture: ComponentFixture<DateWidgetComponent>;
|
||||
let nativeElement: any;
|
||||
let element: HTMLElement;
|
||||
|
||||
beforeEach(async(() => {
|
||||
@@ -51,12 +50,6 @@ describe('DateWidgetComponent', () => {
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
nativeElement = {
|
||||
querySelector: function () {
|
||||
return null;
|
||||
}
|
||||
};
|
||||
|
||||
fixture = TestBed.createComponent(DateWidgetComponent);
|
||||
|
||||
element = fixture.nativeElement;
|
||||
|
@@ -17,11 +17,12 @@
|
||||
|
||||
/* tslint:disable:component-selector */
|
||||
|
||||
import { UserPreferencesService } from '../../../../services';
|
||||
import { MOMENT_DATE_FORMATS, MomentDateAdapter } from '../../../../utils';
|
||||
import { UserPreferencesService } from '../../../../services/user-preferences.service';
|
||||
import { MomentDateAdapter } from '../../../../utils/momentDateAdapter';
|
||||
import { MOMENT_DATE_FORMATS } from '../../../../utils/moment-date-formats.model';
|
||||
import { Component, OnInit, ViewEncapsulation } from '@angular/core';
|
||||
import { DateAdapter, MAT_DATE_FORMATS } from '@angular/material';
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment-es6';
|
||||
import { Moment } from 'moment';
|
||||
import { FormService } from './../../../services/form.service';
|
||||
import { baseHost, WidgetComponent } from './../widget.component';
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { By } from '@angular/platform-browser';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { EcmModelService } from '../../../services/ecm-model.service';
|
||||
import { FormService } from '../../../services/form.service';
|
||||
import { WidgetVisibilityService } from '../../../services/widget-visibility.service';
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
/* tslint:disable:component-selector */
|
||||
|
||||
import { LogService } from '../../../../services';
|
||||
import { LogService } from '../../../../services/log.service';
|
||||
import { Component, OnInit, ViewEncapsulation } from '@angular/core';
|
||||
import { FormService } from '../../../services/form.service';
|
||||
import { WidgetVisibilityService } from '../../../services/widget-visibility.service';
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
/* tslint:disable:component-selector */
|
||||
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment-es6';
|
||||
import { CellValidator } from './cell-validator.model';
|
||||
import { DynamicRowValidationSummary } from './dynamic-row-validation-summary.model';
|
||||
import { DynamicTableColumn } from './dynamic-table-column.model';
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
/* tslint:disable:component-selector */
|
||||
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment-es6';
|
||||
import { ValidateDynamicTableRowEvent } from '../../../events/validate-dynamic-table-row.event';
|
||||
import { FormService } from './../../../services/form.service';
|
||||
import { FormFieldModel } from './../core/form-field.model';
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
/* tslint:disable:component-selector */
|
||||
|
||||
import { LogService } from '../../../../services';
|
||||
import { LogService } from '../../../../services/log.service';
|
||||
import { ChangeDetectorRef, Component, ElementRef, OnInit, ViewEncapsulation } from '@angular/core';
|
||||
import { WidgetVisibilityService } from '../../../services/widget-visibility.service';
|
||||
import { FormService } from './../../../services/form.service';
|
||||
|
@@ -15,9 +15,8 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { DebugElement } from '@angular/core';
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment-es6';
|
||||
import { MaterialModule } from '../../../../../../material.module';
|
||||
import { FormFieldModel, FormModel } from '../../../index';
|
||||
import { DynamicTableColumn } from './../../dynamic-table-column.model';
|
||||
@@ -27,8 +26,6 @@ import { DynamicTableModel } from './../../dynamic-table.widget.model';
|
||||
import { DateEditorComponent } from './date.editor';
|
||||
|
||||
describe('DateEditorComponent', () => {
|
||||
let debugElement: DebugElement;
|
||||
let element: HTMLElement;
|
||||
let component: DateEditorComponent;
|
||||
let fixture: ComponentFixture<DateEditorComponent>;
|
||||
let row: DynamicTableRow;
|
||||
@@ -49,8 +46,6 @@ describe('DateEditorComponent', () => {
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(DateEditorComponent);
|
||||
component = fixture.componentInstance;
|
||||
element = fixture.nativeElement;
|
||||
debugElement = fixture.debugElement;
|
||||
|
||||
row = <DynamicTableRow> { value: { date: '1879-03-14T00:00:00.000Z' } };
|
||||
column = <DynamicTableColumn> { id: 'date', type: 'Date' };
|
||||
|
@@ -17,11 +17,12 @@
|
||||
|
||||
/* tslint:disable:component-selector */
|
||||
|
||||
import { UserPreferencesService } from '../../../../../../services';
|
||||
import { MOMENT_DATE_FORMATS, MomentDateAdapter } from '../../../../../../utils';
|
||||
import { UserPreferencesService } from '../../../../../../services/user-preferences.service';
|
||||
import { MomentDateAdapter } from '../../../../../../utils/momentDateAdapter';
|
||||
import { MOMENT_DATE_FORMATS } from '../../../../../../utils/moment-date-formats.model';
|
||||
import { Component, Input, OnInit } from '@angular/core';
|
||||
import { DateAdapter, MAT_DATE_FORMATS } from '@angular/material';
|
||||
import * as moment from 'moment';
|
||||
import moment from 'moment-es6';
|
||||
import { Moment } from 'moment';
|
||||
import { DynamicTableColumn } from './../../dynamic-table-column.model';
|
||||
import { DynamicTableRow } from './../../dynamic-table-row.model';
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { By } from '@angular/platform-browser';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { EcmModelService } from '../../../../../services/ecm-model.service';
|
||||
import { MaterialModule } from '../../../../../../material.module';
|
||||
import { FormService } from './../../../../../services/form.service';
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
/* tslint:disable:component-selector */
|
||||
|
||||
import { LogService } from '../../../../../../services';
|
||||
import { LogService } from '../../../../../../services/log.service';
|
||||
import { Component, Input, OnInit } from '@angular/core';
|
||||
import { FormService } from './../../../../../services/form.service';
|
||||
import { DynamicTableColumnOption } from './../../dynamic-table-column-option.model';
|
||||
|
@@ -16,7 +16,7 @@
|
||||
*/
|
||||
|
||||
import { ElementRef } from '@angular/core';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { FormService } from '../../../services/form.service';
|
||||
import { FormFieldModel } from '../core/form-field.model';
|
||||
import { FormModel } from '../core/form.model';
|
||||
|
@@ -18,7 +18,7 @@
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { By } from '@angular/platform-browser';
|
||||
import { UserProcessModel } from '../../../../models';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { ActivitiContentService } from '../../../services/activiti-alfresco.service';
|
||||
import { FormService } from '../../../services/form.service';
|
||||
import { MaterialModule } from '../../../../material.module';
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
/* tslint:disable:component-selector */
|
||||
|
||||
import { PeopleProcessService } from '../../../../services';
|
||||
import { PeopleProcessService } from '../../../../services/people-process.service';
|
||||
import { UserProcessModel } from '../../../../models';
|
||||
import { ENTER, ESCAPE } from '@angular/cdk/keycodes';
|
||||
import { Component, ElementRef, OnInit, ViewChild, ViewEncapsulation } from '@angular/core';
|
||||
|
@@ -16,7 +16,7 @@
|
||||
*/
|
||||
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
|
||||
import { EcmModelService } from '../../../services/ecm-model.service';
|
||||
import { FormService } from '../../../services/form.service';
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
/* tslint:disable:component-selector */
|
||||
|
||||
import { LogService } from '../../../../services';
|
||||
import { LogService } from '../../../../services/log.service';
|
||||
import { Component, OnInit, ViewEncapsulation } from '@angular/core';
|
||||
import { FormService } from '../../../services/form.service';
|
||||
import { WidgetVisibilityService } from '../../../services/widget-visibility.service';
|
||||
|
@@ -16,7 +16,7 @@
|
||||
*/
|
||||
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
|
||||
import { By } from '@angular/platform-browser';
|
||||
import { EcmModelService } from '../../../services/ecm-model.service';
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
/* tslint:disable:component-selector */
|
||||
|
||||
import { LogService } from '../../../../services';
|
||||
import { LogService } from '../../../../services/log.service';
|
||||
import { ENTER, ESCAPE } from '@angular/cdk/keycodes';
|
||||
import { Component, OnInit, ViewEncapsulation } from '@angular/core';
|
||||
import { WidgetVisibilityService } from '../../../services/widget-visibility.service';
|
||||
|
@@ -18,7 +18,7 @@
|
||||
import { DebugElement } from '@angular/core';
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
import { By } from '@angular/platform-browser';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
|
||||
import { EcmModelService } from '../../../services/ecm-model.service';
|
||||
import { FormService } from '../../../services/form.service';
|
||||
|
@@ -17,13 +17,15 @@
|
||||
|
||||
/* tslint:disable:component-selector */
|
||||
|
||||
import { LogService, ThumbnailService } from '../../../../services';
|
||||
import { LogService } from '../../../../services/log.service';
|
||||
import { ThumbnailService } from '../../../../services/thumbnail.service';
|
||||
import { Component, ElementRef, OnInit, ViewChild, ViewEncapsulation } from '@angular/core';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { FormService } from '../../../services/form.service';
|
||||
import { ProcessContentService } from '../../../services/process-content.service';
|
||||
import { ContentLinkModel } from '../core/content-link.model';
|
||||
import { baseHost, WidgetComponent } from './../widget.component';
|
||||
import 'rxjs/add/operator/mergeMap';
|
||||
|
||||
@Component({
|
||||
selector: 'upload-widget',
|
||||
@@ -73,7 +75,7 @@ export class UploadWidgetComponent extends WidgetComponent implements OnInit {
|
||||
}
|
||||
|
||||
if (files && files.length > 0) {
|
||||
Observable.from(files).flatMap(file => this.uploadRawContent(file)).subscribe((res) => {
|
||||
Observable.from(files).mergeMap(file => this.uploadRawContent(file)).subscribe((res) => {
|
||||
filesSaved.push(res);
|
||||
},
|
||||
(error) => {
|
||||
|
@@ -28,7 +28,6 @@ describe('WidgetComponent', () => {
|
||||
let widget: WidgetComponent;
|
||||
let fixture: ComponentFixture<WidgetComponent>;
|
||||
let element: HTMLElement;
|
||||
let formService: FormService;
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
@@ -44,7 +43,6 @@ describe('WidgetComponent', () => {
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(WidgetComponent);
|
||||
formService = TestBed.get(FormService);
|
||||
|
||||
element = fixture.nativeElement;
|
||||
widget = fixture.componentInstance;
|
||||
|
@@ -20,9 +20,9 @@ import { FormsModule, ReactiveFormsModule } from '@angular/forms';
|
||||
import { NgModule } from '@angular/core';
|
||||
import { HttpModule } from '@angular/http';
|
||||
import { TranslateModule } from '@ngx-translate/core';
|
||||
import { DataTableModule } from '../datatable';
|
||||
import { DataColumnModule } from '../data-column';
|
||||
import { PipeModule } from '../pipes';
|
||||
import { DataTableModule } from '../datatable/datatable.module';
|
||||
import { DataColumnModule } from '../data-column/data-column.module';
|
||||
import { PipeModule } from '../pipes/pipe.module';
|
||||
|
||||
import { MaterialModule } from '../material.module';
|
||||
|
||||
|
@@ -21,7 +21,6 @@ export * from './components/widgets/content/content.widget';
|
||||
export * from './components/start-form.component';
|
||||
export * from './components/widgets/index';
|
||||
export * from './components/widgets/dynamic-table/dynamic-table-row.model';
|
||||
export { FORM_FIELD_VALIDATORS } from './components/widgets/core/form-field-validator';
|
||||
|
||||
export * from './services/form.service';
|
||||
export * from './services/ecm-model.service';
|
||||
@@ -30,5 +29,3 @@ export * from './services/form-rendering.service';
|
||||
export * from './services/process-content.service';
|
||||
|
||||
export * from './events/index';
|
||||
|
||||
export * from './form.module';
|
||||
|
@@ -15,12 +15,14 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { AlfrescoApiService, LogService } from '../../services';
|
||||
import { AlfrescoApiService } from '../../services/alfresco-api.service';
|
||||
import { LogService } from '../../services/log.service';
|
||||
import { Injectable } from '@angular/core';
|
||||
import { AlfrescoApi } from 'alfresco-js-api';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { ExternalContent } from '../components/widgets/core/external-content';
|
||||
import { ExternalContentLink } from '../components/widgets/core/external-content-link';
|
||||
import 'rxjs/add/observable/throw';
|
||||
|
||||
@Injectable()
|
||||
export class ActivitiContentService {
|
||||
|
@@ -16,7 +16,7 @@
|
||||
*/
|
||||
|
||||
import { TestBed } from '@angular/core/testing';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { FormModel } from './../components/widgets/core/form.model';
|
||||
import { EcmModelService } from './ecm-model.service';
|
||||
|
||||
|
@@ -15,10 +15,12 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { AlfrescoApiService, LogService } from '../../services';
|
||||
import { LogService } from '../../services/log.service';
|
||||
import { AlfrescoApiService } from '../../services/alfresco-api.service';
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { FormModel } from '../components/widgets/core/form.model';
|
||||
import 'rxjs/add/observable/fromPromise';
|
||||
|
||||
@Injectable()
|
||||
export class EcmModelService {
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { DynamicComponentMapper, DynamicComponentResolveFunction, DynamicComponentResolver } from '../../services';
|
||||
import { DynamicComponentMapper, DynamicComponentResolveFunction, DynamicComponentResolver } from '../../services/dynamic-component-mapper.service';
|
||||
import { Injectable, Type } from '@angular/core';
|
||||
|
||||
import {
|
||||
|
@@ -17,7 +17,7 @@
|
||||
|
||||
import { async, TestBed } from '@angular/core/testing';
|
||||
import { Response, ResponseOptions } from '@angular/http';
|
||||
import { AlfrescoApiService, LogService } from '../../index';
|
||||
import { AlfrescoApiService } from '../../services/alfresco-api.service';
|
||||
import { FormDefinitionModel } from '../models/form-definition.model';
|
||||
import { formModelTabs } from '../../mock';
|
||||
import { EcmModelService } from './ecm-model.service';
|
||||
@@ -54,7 +54,6 @@ describe('Form service', () => {
|
||||
|
||||
let service: FormService;
|
||||
let apiService: AlfrescoApiService;
|
||||
let logService: LogService;
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
@@ -69,7 +68,6 @@ describe('Form service', () => {
|
||||
beforeEach(() => {
|
||||
service = TestBed.get(FormService);
|
||||
apiService = TestBed.get(AlfrescoApiService);
|
||||
logService = TestBed.get(LogService);
|
||||
});
|
||||
|
||||
beforeEach(() => {
|
||||
|
@@ -15,10 +15,12 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { AlfrescoApiService, LogService } from '../../services';
|
||||
import { AlfrescoApiService } from '../../services/alfresco-api.service';
|
||||
import { LogService } from '../../services/log.service';
|
||||
import { UserProcessModel } from '../../models';
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Observable, Subject } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { Subject } from 'rxjs/Subject';
|
||||
import { FormDefinitionModel } from '../models/form-definition.model';
|
||||
import { ContentLinkModel } from './../components/widgets/core/content-link.model';
|
||||
import { GroupModel } from './../components/widgets/core/group.model';
|
||||
@@ -28,6 +30,10 @@ import {
|
||||
ValidateDynamicTableRowEvent, ValidateFormEvent, ValidateFormFieldEvent
|
||||
} from './../events/index';
|
||||
import { EcmModelService } from './ecm-model.service';
|
||||
import 'rxjs/add/observable/fromPromise';
|
||||
import 'rxjs/add/operator/defaultIfEmpty';
|
||||
import 'rxjs/add/operator/catch';
|
||||
import 'rxjs/add/observable/throw';
|
||||
|
||||
@Injectable()
|
||||
export class FormService {
|
||||
|
@@ -15,9 +15,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { AlfrescoApiService } from '../../services';
|
||||
import { AlfrescoApiService } from '../../services/alfresco-api.service';
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { NodeMetadata } from '../models/node-metadata.model';
|
||||
|
||||
@Injectable()
|
||||
|
@@ -16,7 +16,7 @@
|
||||
*/
|
||||
|
||||
import { TestBed } from '@angular/core/testing';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { ProcessContentService } from './process-content.service';
|
||||
|
||||
declare let jasmine: any;
|
||||
|
@@ -15,10 +15,14 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { AlfrescoApiService, LogService } from '../../services';
|
||||
import { AlfrescoApiService } from '../../services/alfresco-api.service';
|
||||
import { LogService } from '../../services/log.service';
|
||||
import { Injectable } from '@angular/core';
|
||||
import { RelatedContentRepresentation } from 'alfresco-js-api';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import 'rxjs/add/observable/fromPromise';
|
||||
import 'rxjs/add/operator/catch';
|
||||
import 'rxjs/add/observable/throw';
|
||||
|
||||
@Injectable()
|
||||
export class ProcessContentService {
|
||||
|
@@ -15,13 +15,15 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { AlfrescoApiService, LogService } from '../../services';
|
||||
import { AlfrescoApiService } from '../../services/alfresco-api.service';
|
||||
import { LogService } from '../../services/log.service';
|
||||
import { Injectable } from '@angular/core';
|
||||
import * as moment from 'moment';
|
||||
import { Observable } from 'rxjs/Rx';
|
||||
import moment from 'moment-es6';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { FormFieldModel, FormModel, TabModel } from '../components/widgets/core/index';
|
||||
import { TaskProcessVariableModel } from '../models/task-process-variable.model';
|
||||
import { WidgetVisibilityModel } from '../models/widget-visibility.model';
|
||||
import 'rxjs/add/observable/throw';
|
||||
|
||||
@Injectable()
|
||||
export class WidgetVisibilityService {
|
||||
|
Reference in New Issue
Block a user