Setting the default filter operator via script
Setting the default filter operator via script
In extJS, a column filter defaulted to a "contains" operation. In Kendo, it defaults to "equals". I've looked at the Kendo documentation but can't see how to set the default operation to "contains". Can anyone offer me a start?
V8.8
MySQL, AWS EC2, S3
PDFtk Toolkit
MySQL, AWS EC2, S3
PDFtk Toolkit
Re: Setting the default filter operator via script
I have not used it, but support suggested the following: (of course, change the "AttributeName" to the appropriate one") and put in the initialization script.
for (var i = 0; i < config.columns.length; ++ i)
{
if (config.columns.field == "AttributeNameCorrespondingToColumnWithFilter")
config.columns.filterable.cell = { operator: "contains" };
}
for (var i = 0; i < config.columns.length; ++ i)
{
if (config.columns.field == "AttributeNameCorrespondingToColumnWithFilter")
config.columns.filterable.cell = { operator: "contains" };
}
Re: Setting the default filter operator via script
Hory cow! I just realized that you can set the default filter operation right in the query config. It was hiding in plain sight.
AwareIM is awesome!
AwareIM is awesome!
V8.8
MySQL, AWS EC2, S3
PDFtk Toolkit
MySQL, AWS EC2, S3
PDFtk Toolkit