#1370 Remove use of AlfrescoSettingsService

This commit is contained in:
mauriziovitale84
2017-01-04 13:30:43 +00:00
parent 61b94488d8
commit 58af422d62
27 changed files with 62 additions and 62 deletions

View File

@@ -21,7 +21,7 @@ import { Router } from '@angular/router';
import { import {
AlfrescoTranslationService, AlfrescoTranslationService,
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoSettingsService, SettingsService,
StorageService StorageService
} from 'ng2-alfresco-core'; } from 'ng2-alfresco-core';
@@ -40,7 +40,7 @@ export class AppComponent {
constructor(public auth: AlfrescoAuthenticationService, constructor(public auth: AlfrescoAuthenticationService,
public router: Router, public router: Router,
public alfrescoSettingsService: AlfrescoSettingsService, public settingsService: SettingsService,
private translate: AlfrescoTranslationService, private translate: AlfrescoTranslationService,
private storage: StorageService) { private storage: StorageService) {
this.setEcmHost(); this.setEcmHost();
@@ -118,25 +118,25 @@ export class AppComponent {
private setEcmHost() { private setEcmHost() {
if (this.storage.hasItem(`ecmHost`)) { if (this.storage.hasItem(`ecmHost`)) {
this.alfrescoSettingsService.ecmHost = this.storage.getItem(`ecmHost`); this.settingsService.ecmHost = this.storage.getItem(`ecmHost`);
this.ecmHost = this.storage.getItem(`ecmHost`); this.ecmHost = this.storage.getItem(`ecmHost`);
} else { } else {
this.alfrescoSettingsService.ecmHost = this.ecmHost; this.settingsService.ecmHost = this.ecmHost;
} }
} }
private setBpmHost() { private setBpmHost() {
if (this.storage.hasItem(`bpmHost`)) { if (this.storage.hasItem(`bpmHost`)) {
this.alfrescoSettingsService.bpmHost = this.storage.getItem(`bpmHost`); this.settingsService.bpmHost = this.storage.getItem(`bpmHost`);
this.bpmHost = this.storage.getItem(`bpmHost`); this.bpmHost = this.storage.getItem(`bpmHost`);
} else { } else {
this.alfrescoSettingsService.bpmHost = this.bpmHost; this.settingsService.bpmHost = this.bpmHost;
} }
} }
private setProvider() { private setProvider() {
if (this.storage.hasItem(`providers`)) { if (this.storage.hasItem(`providers`)) {
this.alfrescoSettingsService.setProviders(this.storage.getItem(`providers`)); this.settingsService.setProviders(this.storage.getItem(`providers`));
} }
} }
} }

View File

@@ -16,7 +16,7 @@
*/ */
import { Component } from '@angular/core'; import { Component } from '@angular/core';
import { AlfrescoSettingsService, StorageService } from 'ng2-alfresco-core'; import { SettingsService, StorageService } from 'ng2-alfresco-core';
@Component({ @Component({
selector: 'alfresco-setting-demo', selector: 'alfresco-setting-demo',
@@ -28,23 +28,23 @@ export class SettingComponent {
ecmHost: string; ecmHost: string;
bpmHost: string; bpmHost: string;
constructor(public alfrescoSettingsService: AlfrescoSettingsService, constructor(public settingsService: SettingsService,
private storage: StorageService) { private storage: StorageService) {
this.ecmHost = this.alfrescoSettingsService.ecmHost; this.ecmHost = this.settingsService.ecmHost;
this.bpmHost = this.alfrescoSettingsService.bpmHost; this.bpmHost = this.settingsService.bpmHost;
} }
public onChangeECMHost(event: KeyboardEvent): void { public onChangeECMHost(event: KeyboardEvent): void {
console.log((<HTMLInputElement>event.target).value); console.log((<HTMLInputElement>event.target).value);
this.ecmHost = (<HTMLInputElement>event.target).value; this.ecmHost = (<HTMLInputElement>event.target).value;
this.alfrescoSettingsService.ecmHost = this.ecmHost; this.settingsService.ecmHost = this.ecmHost;
this.storage.setItem(`ecmHost`, this.ecmHost); this.storage.setItem(`ecmHost`, this.ecmHost);
} }
public onChangeBPMHost(event: KeyboardEvent): void { public onChangeBPMHost(event: KeyboardEvent): void {
console.log((<HTMLInputElement>event.target).value); console.log((<HTMLInputElement>event.target).value);
this.bpmHost = (<HTMLInputElement>event.target).value; this.bpmHost = (<HTMLInputElement>event.target).value;
this.alfrescoSettingsService.bpmHost = this.bpmHost; this.settingsService.bpmHost = this.bpmHost;
this.storage.setItem(`bpmHost`, this.bpmHost); this.storage.setItem(`bpmHost`, this.bpmHost);
} }

View File

@@ -18,7 +18,7 @@
import { NgModule, Component, OnInit } from '@angular/core'; import { NgModule, Component, OnInit } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser'; import { BrowserModule } from '@angular/platform-browser';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'; import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { CoreModule, AlfrescoSettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core'; import { CoreModule, SettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core';
import { AnalyticsModule } from 'ng2-activiti-analytics'; import { AnalyticsModule } from 'ng2-activiti-analytics';
@Component({ @Component({
@@ -61,7 +61,7 @@ export class AnalyticsDemoComponent implements OnInit {
ticket: string; ticket: string;
constructor(private authService: AlfrescoAuthenticationService, constructor(private authService: AlfrescoAuthenticationService,
private settingsService: AlfrescoSettingsService, private settingsService: SettingsService,
private storage: StorageService) { private storage: StorageService) {
settingsService.bpmHost = this.host; settingsService.bpmHost = this.host;
settingsService.setProviders('BPM'); settingsService.setProviders('BPM');

View File

@@ -19,7 +19,7 @@ import { NgModule, Component } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser'; import { BrowserModule } from '@angular/platform-browser';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'; import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { CoreModule, AlfrescoSettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core'; import { CoreModule, SettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core';
import { DiagramsModule } from 'ng2-activiti-diagrams'; import { DiagramsModule } from 'ng2-activiti-diagrams';
@Component({ @Component({
@@ -51,7 +51,7 @@ export class DiagramDemoComponent {
ticket: string; ticket: string;
constructor(private authService: AlfrescoAuthenticationService, constructor(private authService: AlfrescoAuthenticationService,
private settingsService: AlfrescoSettingsService, private settingsService: SettingsService,
private storage: StorageService) { private storage: StorageService) {
settingsService.bpmHost = this.host; settingsService.bpmHost = this.host;
settingsService.setProviders('BPM'); settingsService.setProviders('BPM');

View File

@@ -25,11 +25,11 @@ export class DiagramsService {
constructor(private authService: AuthService, constructor(private authService: AuthService,
private http: Http, private http: Http,
private alfrescoSettingsService: SettingsService) { private settingsService: SettingsService) {
} }
getProcessDefinitionModel(processDefinitionId: string): Observable<any> { getProcessDefinitionModel(processDefinitionId: string): Observable<any> {
let url = `${this.alfrescoSettingsService.getBPMApiBaseUrl()}/app/rest/process-definitions/${processDefinitionId}/model-json`; let url = `${this.settingsService.getBPMApiBaseUrl()}/app/rest/process-definitions/${processDefinitionId}/model-json`;
let options = this.getRequestOptions(); let options = this.getRequestOptions();
return this.http return this.http
.get(url, options) .get(url, options)

View File

@@ -18,7 +18,7 @@
import { NgModule, Component, OnInit } from '@angular/core'; import { NgModule, Component, OnInit } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser'; import { BrowserModule } from '@angular/platform-browser';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'; import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { CoreModule, AlfrescoSettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core'; import { CoreModule, SettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core';
import { ActivitiFormModule } from 'ng2-activiti-form'; import { ActivitiFormModule } from 'ng2-activiti-form';
@Component({ @Component({
@@ -50,7 +50,7 @@ export class FormDemoComponent implements OnInit {
ticket: string; ticket: string;
constructor(private authService: AlfrescoAuthenticationService, constructor(private authService: AlfrescoAuthenticationService,
private settingsService: AlfrescoSettingsService, private settingsService: SettingsService,
private storage: StorageService) { private storage: StorageService) {
settingsService.bpmHost = this.host; settingsService.bpmHost = this.host;
settingsService.setProviders('BPM'); settingsService.setProviders('BPM');

View File

@@ -28,7 +28,7 @@ import {
ActivitiStartProcessInstance, ActivitiStartProcessInstance,
ProcessInstance ProcessInstance
} from 'ng2-activiti-processlist'; } from 'ng2-activiti-processlist';
import { AlfrescoAuthenticationService, AlfrescoSettingsService, StorageService } from 'ng2-alfresco-core'; import { AlfrescoAuthenticationService, SettingsService, StorageService } from 'ng2-alfresco-core';
import { ObjectDataTableAdapter } from 'ng2-alfresco-datatable'; import { ObjectDataTableAdapter } from 'ng2-alfresco-datatable';
const currentProcessIdNew = '__NEW__'; const currentProcessIdNew = '__NEW__';
@@ -161,7 +161,7 @@ class MyDemoApp implements OnInit {
dataProcesses: ObjectDataTableAdapter; dataProcesses: ObjectDataTableAdapter;
constructor(private authService: AlfrescoAuthenticationService, constructor(private authService: AlfrescoAuthenticationService,
private settingsService: AlfrescoSettingsService, private settingsService: SettingsService,
private storage: StorageService) { private storage: StorageService) {
settingsService.bpmHost = this.host; settingsService.bpmHost = this.host;
settingsService.setProviders('BPM'); settingsService.setProviders('BPM');

View File

@@ -22,7 +22,7 @@ import {
AlfrescoTranslationService, AlfrescoTranslationService,
CoreModule, CoreModule,
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoSettingsService, SettingsService,
AlfrescoApiService } from 'ng2-alfresco-core'; AlfrescoApiService } from 'ng2-alfresco-core';
import { ActivitiProcessInstanceHeader } from './activiti-process-instance-header.component'; import { ActivitiProcessInstanceHeader } from './activiti-process-instance-header.component';
@@ -48,7 +48,7 @@ describe('ActivitiProcessInstanceHeader', () => {
ActivitiProcessComments ActivitiProcessComments
], ],
providers: [ providers: [
AlfrescoSettingsService, SettingsService,
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoApiService, AlfrescoApiService,
ActivitiProcessService, ActivitiProcessService,

View File

@@ -26,7 +26,7 @@ import {
ActivitiTaskList ActivitiTaskList
} from 'ng2-activiti-tasklist'; } from 'ng2-activiti-tasklist';
import { CoreModule } from 'ng2-alfresco-core'; import { CoreModule } from 'ng2-alfresco-core';
import { AlfrescoAuthenticationService, AlfrescoSettingsService, StorageService } from 'ng2-alfresco-core'; import { AlfrescoAuthenticationService, SettingsService, StorageService } from 'ng2-alfresco-core';
import { ObjectDataTableAdapter } from 'ng2-alfresco-datatable'; import { ObjectDataTableAdapter } from 'ng2-alfresco-datatable';
@Component({ @Component({
@@ -145,7 +145,7 @@ class MyDemoApp implements OnInit {
dataTasks: ObjectDataTableAdapter; dataTasks: ObjectDataTableAdapter;
constructor(private authService: AlfrescoAuthenticationService, constructor(private authService: AlfrescoAuthenticationService,
private settingsService: AlfrescoSettingsService, private settingsService: SettingsService,
private storage: StorageService) { private storage: StorageService) {
settingsService.bpmHost = this.host; settingsService.bpmHost = this.host;
settingsService.setProviders('BPM'); settingsService.setProviders('BPM');

View File

@@ -17,7 +17,7 @@
import { SettingsService } from './settings.service'; import { SettingsService } from './settings.service';
describe('AlfrescoSettingsService', () => { describe('SettingsService', () => {
let service: SettingsService; let service: SettingsService;

View File

@@ -19,7 +19,7 @@ import { NgModule, Component, OnInit, ViewChild } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser'; import { BrowserModule } from '@angular/platform-browser';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'; import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { DocumentListModule, DocumentList, DocumentActionsService } from 'ng2-alfresco-documentlist'; import { DocumentListModule, DocumentList, DocumentActionsService } from 'ng2-alfresco-documentlist';
import { CoreModule, StorageService, SettingsService, AuthService, AlfrescoTranslateService } from 'ng2-alfresco-core'; import { CoreModule, StorageService, SettingsService, AuthService, AlfrescoTranslationService } from 'ng2-alfresco-core';
@Component({ @Component({
selector: 'alfresco-app-demo', selector: 'alfresco-app-demo',
@@ -129,7 +129,7 @@ class DocumentListDemo implements OnInit {
constructor(private authService: AuthService, constructor(private authService: AuthService,
private settingsService: SettingsService, private settingsService: SettingsService,
private translateService: AlfrescoTranslateService, private translateService: AlfrescoTranslationService,
private documentActions: DocumentActionsService, private documentActions: DocumentActionsService,
private storage: StorageService) { private storage: StorageService) {

View File

@@ -20,7 +20,7 @@ import { NodePaging } from './../models/document-library.model';
import { PageNode } from './document-library.model.mock'; import { PageNode } from './document-library.model.mock';
import { DocumentListService } from './../services/document-list.service'; import { DocumentListService } from './../services/document-list.service';
import { import {
AlfrescoSettingsService, SettingsService,
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoContentService, AlfrescoContentService,
AlfrescoApiService AlfrescoApiService
@@ -33,7 +33,7 @@ export class DocumentListServiceMock extends DocumentListService {
getFolderRejectError: string = 'Error'; getFolderRejectError: string = 'Error';
constructor( constructor(
settings?: AlfrescoSettingsService, settings?: SettingsService,
authService?: AlfrescoAuthenticationService, authService?: AlfrescoAuthenticationService,
contentService?: AlfrescoContentService, contentService?: AlfrescoContentService,
apiService?: AlfrescoApiService apiService?: AlfrescoApiService

View File

@@ -19,7 +19,7 @@ import { NgModule, Component } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser'; import { BrowserModule } from '@angular/platform-browser';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'; import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { CoreModule, AlfrescoSettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core'; import { CoreModule, SettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core';
import { LoginModule } from 'ng2-alfresco-login'; import { LoginModule } from 'ng2-alfresco-login';
@Component({ @Component({
@@ -74,7 +74,7 @@ export class AppComponent {
public disableCsrf: boolean = false; public disableCsrf: boolean = false;
constructor(public auth: AlfrescoAuthenticationService, constructor(public auth: AlfrescoAuthenticationService,
private settingsService: AlfrescoSettingsService, private settingsService: SettingsService,
private storage: StorageService) { private storage: StorageService) {
settingsService.ecmHost = this.ecmHost; settingsService.ecmHost = this.ecmHost;

View File

@@ -19,7 +19,7 @@ import { ComponentFixture, TestBed, async } from '@angular/core/testing';
import { DebugElement } from '@angular/core'; import { DebugElement } from '@angular/core';
import { import {
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoSettingsService, SettingsService,
AlfrescoApiService, AlfrescoApiService,
CoreModule CoreModule
} from 'ng2-alfresco-core'; } from 'ng2-alfresco-core';
@@ -43,7 +43,7 @@ describe('AlfrescoLogin', () => {
], ],
declarations: [AlfrescoLoginComponent], declarations: [AlfrescoLoginComponent],
providers: [ providers: [
AlfrescoSettingsService, SettingsService,
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoApiService, AlfrescoApiService,
{provide: AlfrescoAuthenticationService, useClass: AuthenticationMock}, {provide: AlfrescoAuthenticationService, useClass: AuthenticationMock},

View File

@@ -20,7 +20,7 @@ import { FormGroup, FormBuilder, Validators } from '@angular/forms';
import { import {
AlfrescoTranslationService, AlfrescoTranslationService,
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoSettingsService SettingsService
} from 'ng2-alfresco-core'; } from 'ng2-alfresco-core';
import { FormSubmitEvent } from '../models/form-submit-event.model'; import { FormSubmitEvent } from '../models/form-submit-event.model';
@@ -80,7 +80,7 @@ export class AlfrescoLoginComponent implements OnInit {
*/ */
constructor(private _fb: FormBuilder, constructor(private _fb: FormBuilder,
public authService: AlfrescoAuthenticationService, public authService: AlfrescoAuthenticationService,
public settingsService: AlfrescoSettingsService, public settingsService: SettingsService,
private translate: AlfrescoTranslationService) { private translate: AlfrescoTranslationService) {
translate.addTranslationFolder('ng2-alfresco-login', 'node_modules/ng2-alfresco-login/src'); translate.addTranslationFolder('ng2-alfresco-login', 'node_modules/ng2-alfresco-login/src');

View File

@@ -23,7 +23,7 @@ import { CoreModule } from 'ng2-alfresco-core';
import { SearchModule } from 'ng2-alfresco-search'; import { SearchModule } from 'ng2-alfresco-search';
import { import {
AlfrescoSettingsService, SettingsService,
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoTranslationService AlfrescoTranslationService
} from 'ng2-alfresco-core'; } from 'ng2-alfresco-core';
@@ -58,7 +58,7 @@ class SearchDemo implements OnInit {
ticket: string; ticket: string;
constructor(private authService: AlfrescoAuthenticationService, constructor(private authService: AlfrescoAuthenticationService,
private settingsService: AlfrescoSettingsService, private settingsService: SettingsService,
translation: AlfrescoTranslationService) { translation: AlfrescoTranslationService) {
settingsService.ecmHost = this.ecmHost; settingsService.ecmHost = this.ecmHost;

View File

@@ -19,7 +19,7 @@ import { NgModule, Component, Input, OnInit } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser'; import { BrowserModule } from '@angular/platform-browser';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'; import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { CoreModule, AlfrescoSettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core'; import { CoreModule, SettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core';
import { TagModule } from 'ng2-alfresco-tag'; import { TagModule } from 'ng2-alfresco-tag';
@Component({ @Component({
@@ -60,7 +60,7 @@ class TagDemo implements OnInit {
ticket: string; ticket: string;
constructor(private authService: AlfrescoAuthenticationService, constructor(private authService: AlfrescoAuthenticationService,
private settingsService: AlfrescoSettingsService, private settingsService: SettingsService,
private storage: StorageService) { private storage: StorageService) {
settingsService.ecmHost = this.ecmHost; settingsService.ecmHost = this.ecmHost;

View File

@@ -18,7 +18,7 @@
import { ReflectiveInjector } from '@angular/core'; import { ReflectiveInjector } from '@angular/core';
import { import {
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoSettingsService, SettingsService,
AlfrescoApiService, AlfrescoApiService,
StorageService StorageService
} from 'ng2-alfresco-core'; } from 'ng2-alfresco-core';
@@ -32,7 +32,7 @@ describe('Tag service', () => {
beforeEach(() => { beforeEach(() => {
injector = ReflectiveInjector.resolveAndCreate([ injector = ReflectiveInjector.resolveAndCreate([
AlfrescoSettingsService, SettingsService,
AlfrescoApiService, AlfrescoApiService,
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
TagService, TagService,

View File

@@ -19,7 +19,7 @@ import { NgModule, Component, OnInit } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser'; import { BrowserModule } from '@angular/platform-browser';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'; import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { CoreModule, AlfrescoSettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core'; import { CoreModule, SettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core';
import { UploadModule } from 'ng2-alfresco-upload'; import { UploadModule } from 'ng2-alfresco-upload';
@Component({ @Component({
@@ -114,7 +114,7 @@ export class MyDemoApp implements OnInit {
ticket: string; ticket: string;
constructor(private authService: AlfrescoAuthenticationService, constructor(private authService: AlfrescoAuthenticationService,
private settingsService: AlfrescoSettingsService, private settingsService: SettingsService,
private storage: StorageService) { private storage: StorageService) {
settingsService.ecmHost = this.ecmHost; settingsService.ecmHost = this.ecmHost;
settingsService.setProviders('ECM'); settingsService.setProviders('ECM');

View File

@@ -21,7 +21,7 @@ import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { UserInfoComponentModule } from 'ng2-alfresco-userinfo'; import { UserInfoComponentModule } from 'ng2-alfresco-userinfo';
import { CoreModule } from 'ng2-alfresco-core'; import { CoreModule } from 'ng2-alfresco-core';
import { LoginModule } from 'ng2-alfresco-login'; import { LoginModule } from 'ng2-alfresco-login';
import { AlfrescoAuthenticationService, AlfrescoSettingsService } from 'ng2-alfresco-core'; import { AlfrescoAuthenticationService, SettingsService } from 'ng2-alfresco-core';
@Component({ @Component({
selector: 'alfresco-app-demo', selector: 'alfresco-app-demo',
@@ -93,7 +93,7 @@ class UserInfoDemo implements OnInit {
public disableCsrf: boolean = false; public disableCsrf: boolean = false;
constructor(private authService: AlfrescoAuthenticationService, constructor(private authService: AlfrescoAuthenticationService,
private settingsService: AlfrescoSettingsService) { private settingsService: SettingsService) {
settingsService.ecmHost = this.ecmHost; settingsService.ecmHost = this.ecmHost;
settingsService.bpmHost = this.bpmHost; settingsService.bpmHost = this.bpmHost;
} }

View File

@@ -18,7 +18,7 @@
import { NgModule, Component } from '@angular/core'; import { NgModule, Component } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser'; import { BrowserModule } from '@angular/platform-browser';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'; import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { CoreModule, AlfrescoSettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core'; import { CoreModule, SettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core';
import { ViewerModule } from 'ng2-alfresco-viewer'; import { ViewerModule } from 'ng2-alfresco-viewer';
@Component({ @Component({
@@ -55,7 +55,7 @@ class MyDemoApp {
ticket: string; ticket: string;
constructor(private authService: AlfrescoAuthenticationService, constructor(private authService: AlfrescoAuthenticationService,
private settingsService: AlfrescoSettingsService, private settingsService: SettingsService,
private storage: StorageService) { private storage: StorageService) {
settingsService.ecmHost = this.ecmHost; settingsService.ecmHost = this.ecmHost;
settingsService.setProviders('ECM'); settingsService.setProviders('ECM');

View File

@@ -20,7 +20,7 @@ import { ImgViewerComponent } from './imgViewer.component';
import { DebugElement } from '@angular/core'; import { DebugElement } from '@angular/core';
import { import {
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoSettingsService, SettingsService,
AlfrescoApiService, AlfrescoApiService,
CoreModule CoreModule
} from 'ng2-alfresco-core'; } from 'ng2-alfresco-core';
@@ -39,7 +39,7 @@ describe('Test ng2-alfresco-viewer Img viewer component ', () => {
], ],
declarations: [ImgViewerComponent], declarations: [ImgViewerComponent],
providers: [ providers: [
AlfrescoSettingsService, SettingsService,
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoApiService AlfrescoApiService
] ]

View File

@@ -20,7 +20,7 @@ import { MediaPlayerComponent } from './mediaPlayer.component';
import { DebugElement } from '@angular/core'; import { DebugElement } from '@angular/core';
import { import {
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoSettingsService, SettingsService,
AlfrescoApiService, AlfrescoApiService,
CoreModule CoreModule
} from 'ng2-alfresco-core'; } from 'ng2-alfresco-core';
@@ -39,7 +39,7 @@ describe('Test ng2-alfresco-viewer Media player component ', () => {
], ],
declarations: [MediaPlayerComponent], declarations: [MediaPlayerComponent],
providers: [ providers: [
AlfrescoSettingsService, SettingsService,
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoApiService AlfrescoApiService
] ]

View File

@@ -20,7 +20,7 @@ import { NotSupportedFormat } from './notSupportedFormat.component';
import { DebugElement } from '@angular/core'; import { DebugElement } from '@angular/core';
import { import {
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoSettingsService, SettingsService,
AlfrescoApiService, AlfrescoApiService,
CoreModule CoreModule
} from 'ng2-alfresco-core'; } from 'ng2-alfresco-core';
@@ -39,7 +39,7 @@ describe('Test ng2-alfresco-viewer Not Supported Format View component', () => {
], ],
declarations: [NotSupportedFormat], declarations: [NotSupportedFormat],
providers: [ providers: [
AlfrescoSettingsService, SettingsService,
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoApiService AlfrescoApiService
] ]

View File

@@ -22,7 +22,7 @@ import { EventMock } from '../assets/event.mock';
import { DebugElement } from '@angular/core'; import { DebugElement } from '@angular/core';
import { import {
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoSettingsService, SettingsService,
AlfrescoApiService, AlfrescoApiService,
CoreModule CoreModule
} from 'ng2-alfresco-core'; } from 'ng2-alfresco-core';
@@ -41,7 +41,7 @@ describe('Test ng2-alfresco-viewer PdfViewer component', () => {
], ],
declarations: [PdfViewerComponent], declarations: [PdfViewerComponent],
providers: [ providers: [
AlfrescoSettingsService, SettingsService,
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoApiService, AlfrescoApiService,
RenderingQueueServices RenderingQueueServices

View File

@@ -26,7 +26,7 @@ import { EventMock } from '../assets/event.mock';
import { DebugElement } from '@angular/core'; import { DebugElement } from '@angular/core';
import { import {
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoSettingsService, SettingsService,
AlfrescoApiService, AlfrescoApiService,
CoreModule CoreModule
} from 'ng2-alfresco-core'; } from 'ng2-alfresco-core';
@@ -53,7 +53,7 @@ describe('Test ng2-alfresco-viewer ViewerComponent', () => {
ImgViewerComponent ImgViewerComponent
], ],
providers: [ providers: [
AlfrescoSettingsService, SettingsService,
AlfrescoAuthenticationService, AlfrescoAuthenticationService,
AlfrescoApiService, AlfrescoApiService,
RenderingQueueServices RenderingQueueServices

View File

@@ -19,7 +19,7 @@ import { NgModule, Component, OnInit } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser'; import { BrowserModule } from '@angular/platform-browser';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'; import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
import { CoreModule, AlfrescoSettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core'; import { CoreModule, SettingsService, AlfrescoAuthenticationService, StorageService } from 'ng2-alfresco-core';
import { DataTableModule } from 'ng2-alfresco-datatable'; import { DataTableModule } from 'ng2-alfresco-datatable';
import { WebScriptModule } from 'ng2-alfresco-webscript'; import { WebScriptModule } from 'ng2-alfresco-webscript';
@@ -63,7 +63,7 @@ class WebscriptDemo implements OnInit {
ticket: string; ticket: string;
constructor(private authService: AlfrescoAuthenticationService, constructor(private authService: AlfrescoAuthenticationService,
private settingsService: AlfrescoSettingsService, private settingsService: SettingsService,
private storage: StorageService) { private storage: StorageService) {
settingsService.ecmHost = this.ecmHost; settingsService.ecmHost = this.ecmHost;