Hi,
I am making a standard treelist component based on kendo treelist, and im having some problem which i dont know how to fix it.
2. I want to allow user can add kendo treelist column and use ng-template KendoTreelistCell as `Usage code` below but it keep throw this error:
Uncaught (in promise): NullInjectorError: R3InjectorError(PMarketingModule)[OptionChangesService -> OptionChangesService -> OptionChangesService -> OptionChangesService]:
NullInjectorError: No provider for OptionChangesService!
NullInjectorError: R3InjectorError(PMarketingModule)[OptionChangesService -> OptionChangesService -> OptionChangesService -> OptionChangesService]:
NullInjectorError: No provider for OptionChangesService!
https://stackblitz.com/edit/angular-keazja?file=src%2Fapp%2Fapp.component.ts
My component treelist:
Usage:
Regards,
Hnaul
Hi Hnaul,
The mentioned implementation isn't valid for the TreeList component as the TreeListCoolumnComponent needs to be defined inside the TreeList component:
https://stackblitz.com/edit/angular-keazja-hat4er?file=src%2Fapp%2Fapp.component.ts,src%2Fapp%2Ftreelist.component.ts
Now I do understand that content projection might be useful, but our components are complex and in certain scenarios might not be achievable as the OptionChangesService is private.
You could possibly check the Grid with a similar approach, but I cannot promise that everything would work for a specific scenario.
https://stackblitz.com/edit/angular-lq8s9q?file=src%2Fapp%2Fapp.component.ts,src%2Fapp%2Ftest%2Ftest.component.ts,src%2Fapp%2Ftest%2Ftest.component.html
Regards,
Yanmario
Progress Telerik