This question relates to the question that has been asked here, but has not been answered.
I am using Angular 4.2 to run a POC with Kendo UI For Angular. Same as the author of the above question, i need to change the date format in the model, for which i have created a custom attribute directive "formatDate" which uses ControlValueAccessor. And i have used
multi: true
option as well in the directive. The current code looks like this;
<kendo-datepicker [(ngModel)] = "myModel" formatDate></kendo-datepicker>
When i run this, i get the same error as;
ERROR Error:More than one custom value accessor matches form control with unspecified name attribute
I tested "formatDate" directive with a simple HTML5 date input before and it worked fine.I reckon that kendo datepicker might also be using ControlValueAccessor as well, and hence i am getting this error.
Seems the error is popping up from angular/forms/directives/shared.ts. And there's a comment on the top of the function "selectValueAccessor" mentioning a particular issue in github (github.com/angular/angular/issues/3011). And it pointed out to another issue (github.com/angular/angular/issues/3009) which talks about implementing formatters/parsers for angular. There's a new npm library introduced by someone a few days ago, but i am not sure if i want to go through all that hassle to do something trivial.
Has anyone experienced this issue and came up with any solution on how to support multiple control value accessors?.