Single place for translate pipe

This commit is contained in:
Denys Vuika
2016-09-17 19:56:55 +01:00
parent 22c91182af
commit 2c830d9693
30 changed files with 53 additions and 102 deletions

View File

@@ -22,7 +22,6 @@ import {
MDL,
AlfrescoSettingsService,
AlfrescoTranslationService,
AlfrescoPipeTranslate,
AlfrescoAuthenticationService
} from 'ng2-alfresco-core';
@@ -34,8 +33,7 @@ declare var document: any;
selector: 'alfresco-app',
templateUrl: 'app/app.component.html',
styleUrls: ['app/app.component.css'],
directives: [SearchBarComponent, ROUTER_DIRECTIVES, MDL],
pipes: [AlfrescoPipeTranslate]
directives: [SearchBarComponent, ROUTER_DIRECTIVES, MDL]
})
export class AppComponent {
translate: AlfrescoTranslationService;

View File

@@ -29,8 +29,7 @@ import {
import {
MDL,
AlfrescoContentService,
CONTEXT_MENU_DIRECTIVES,
AlfrescoPipeTranslate
CONTEXT_MENU_DIRECTIVES
} from 'ng2-alfresco-core';
import { PaginationComponent } from 'ng2-alfresco-datatable';
import { ALFRESCO_ULPOAD_COMPONENTS } from 'ng2-alfresco-upload';
@@ -52,8 +51,7 @@ declare let __moduleName: string;
CONTEXT_MENU_DIRECTIVES,
PaginationComponent
],
providers: [DOCUMENT_LIST_PROVIDERS, FormService],
pipes: [AlfrescoPipeTranslate]
providers: [DOCUMENT_LIST_PROVIDERS, FormService]
})
export class FilesComponent implements OnInit {
currentPath: string = '/Sites/swsdp/documentLibrary';

View File

@@ -16,9 +16,10 @@
*/
import { bootstrap } from '@angular/platform-browser-dynamic';
import { PLATFORM_PIPES } from '@angular/core';
import { HTTP_PROVIDERS } from '@angular/http';
import { ALFRESCO_SEARCH_PROVIDERS } from 'ng2-alfresco-search';
import { ALFRESCO_CORE_PROVIDERS } from 'ng2-alfresco-core';
import { ALFRESCO_CORE_PROVIDERS, AlfrescoPipeTranslate } from 'ng2-alfresco-core';
import { ATIVITI_FORM_PROVIDERS } from 'ng2-activiti-form';
import { UploadService } from 'ng2-alfresco-upload';
import { AppComponent } from './app.component';
@@ -28,6 +29,7 @@ bootstrap(AppComponent, [
appRouterProviders,
HTTP_PROVIDERS,
ALFRESCO_CORE_PROVIDERS,
{ provide: PLATFORM_PIPES, useValue: AlfrescoPipeTranslate, multi: true },
ALFRESCO_SEARCH_PROVIDERS,
UploadService,
ATIVITI_FORM_PROVIDERS