jsgrid
jsgrid copied to clipboard
Date Filter cannot read property 'val' of undefined
Hi,
I'm trying to add a filterTemplate, that allows me to select a date. This is what I have so far:
{ name: "IEPDate", type: "text", title: "IEP Date", css: "smallfont", width:50,
itemTemplate: function (value) {
return moment(value).add(1, 'days').format("MM/DD/YYYY");
},
filterTemplate: function(){
return $("<input class='form-control form-control-sm' type='date' value='2018-04-17'>");
}
My browser gives me the error:
jsgrid.min.js:7 Uncaught TypeError: Cannot read property 'val' of undefined
at c.filterValue (jsgrid.min.js:7)
at d.<anonymous> (jsgrid.min.js:7)
at c.<anonymous> (jsgrid.min.js:7)
at Function.each (jquery.min.js:2)
at d._eachField (jsgrid.min.js:7)
at d.getFilter (jsgrid.min.js:7)
at d.loadData (jsgrid.min.js:7)
at d.search (jsgrid.min.js:7)
at jsgrid.min.js:8
at HTMLInputElement.<anonymous> (jsgrid.min.js:8)
Any help appreciated, thank you!
Currently experiencing the same issue. @tabalinas any thoughts here?
@andrewgoodnz Did you ever find a fix for this?
did you find the solution, guys?