mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-5106] fix stencil registration (#5694)
* customize services on the module level * improved service registration
This commit is contained in:
@@ -16,13 +16,16 @@
|
||||
*/
|
||||
|
||||
import { Component, OnDestroy, OnInit } from '@angular/core';
|
||||
import { FormFieldModel, NotificationService, CoreAutomationService, FormModel } from '@alfresco/adf-core';
|
||||
import { FormCloudService } from '@alfresco/adf-process-services-cloud';
|
||||
import { FormFieldModel, NotificationService, CoreAutomationService, FormModel, FormRenderingService } from '@alfresco/adf-core';
|
||||
import { FormCloudService, CloudFormRenderingService } from '@alfresco/adf-process-services-cloud';
|
||||
import { Subscription } from 'rxjs';
|
||||
|
||||
@Component({
|
||||
templateUrl: 'cloud-form-demo.component.html',
|
||||
styleUrls: ['cloud-form-demo.component.scss']
|
||||
styleUrls: ['cloud-form-demo.component.scss'],
|
||||
providers: [
|
||||
{ provide: FormRenderingService, useClass: CloudFormRenderingService }
|
||||
]
|
||||
})
|
||||
export class FormCloudDemoComponent implements OnInit, OnDestroy {
|
||||
|
||||
|
@@ -16,7 +16,8 @@
|
||||
*/
|
||||
|
||||
import { Component, Inject, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';
|
||||
import { FormModel, FormFieldModel, FormService, FormOutcomeEvent, NotificationService, CoreAutomationService } from '@alfresco/adf-core';
|
||||
import { FormModel, FormFieldModel, FormService, FormOutcomeEvent, NotificationService, CoreAutomationService, FormRenderingService } from '@alfresco/adf-core';
|
||||
import { ProcessFormRenderingService } from '@alfresco/adf-process-services';
|
||||
import { InMemoryFormService } from '../../services/in-memory-form.service';
|
||||
import { Subject } from 'rxjs';
|
||||
import { takeUntil } from 'rxjs/operators';
|
||||
@@ -26,7 +27,8 @@ import { takeUntil } from 'rxjs/operators';
|
||||
templateUrl: 'form.component.html',
|
||||
styleUrls: ['form.component.scss'],
|
||||
providers: [
|
||||
{ provide: FormService, useClass: InMemoryFormService }
|
||||
{ provide: FormService, useClass: InMemoryFormService },
|
||||
{ provide: FormRenderingService, useClass: ProcessFormRenderingService }
|
||||
],
|
||||
encapsulation: ViewEncapsulation.None
|
||||
})
|
||||
|
Reference in New Issue
Block a user