alfresco-ng2-components: Custom stencil seems broken in 3.8

Type of issue: (check with “[x]”)

  • New feature request
  • [X ] Bug
  • Support request
  • Documentation

Current behaviour: Custom stencil that works with 3.6 and 3.7 does not load with 3.8

Expected behavior: Custom stencil should load in the form of a search button.

Steps to reproduce the issue: Upgrade to 3.8, create a new process.

Component name and version: process-services/lib/form/form.component.ts - 3.8

  constructor(
 ...
    private formRenderingService: FormRenderingService
  ) {
      formRenderingService.setComponentTypeResolver('crm_search_primary', () => SearchConstituentButtonComponent, true);
   }

Our code matches the examples: from demo-shell and from the yo generator. Once upgrading to 3.8 we get an error message in the form instead of the search button: Unknown type: crm_search_primary

UPDATE: I commented out the providers block in process-services/lib/form/form.component.ts and the problem goes away.

@Component({
    selector: 'adf-form',
    templateUrl: './form.component.html',
    encapsulation: ViewEncapsulation.None,
    providers: [
        { provide: FormRenderingService, useClass: ProcessFormRenderingService }
    ]
})

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Comments: 19 (12 by maintainers)

Most upvoted comments

It seems to be a bug with multiple instances of ProcessFormRenderingService in memory. Investigating a way to fix it.