I have a kendo grid with in cell editing. I extended the validator to add a new validation rule and message. This is working correctly.
However, I can't seem to change the default error template for the validation message. Here is the code used to extend the validator:
(function ($, kendo) {
$.extend(true, kendo.ui.validator, {
rules: {
uniqueTagName: function (input) {
...
},
messages: {
uniqueTagName: resources.Message_TagAlreadyExists
},
errorTemplate: "<
span
>#=message# TEST</
span
>"
});
})(jQuery, kendo);
I can see from the console that when I look at kendo.ui.validator, the errorTemplate is changed to "<span>#=message# TEST</span>". However, when the (Name) element is validated, I get the default error template.
Through $("#Name").kendoValidator().data("kendoValidator"), i get this template:
<span class="k-widget k-tooltip k-tooltip-validation"><span class="k-icon k-warning"> </span> #=message#</span>
However,both validators have the extended rule and validation message.
I also tried to create a <span data-for="Name" class="k-invalid-msg"> as I have found somewhere in the documentation, but this seems to have no effect.