My example: http://dojo.telerik.com/oWABE/3
Here I have a data object containing "status" which is an integer! (it is 1,2 or 3)
In my Grid that masks to New, Pending and Closed
To show the strings (New, Pending and Closed) I have created a parse function in the shema -> for filtering to work on the parsed values one cannot use a template in the columns definition, but has to parse it in the datasource!
Status: { type:
"int"
,
parse:
function
(status) {
console.log(status,
"stat"
);
switch
(status){
case
1:
return
"New"
;
break
;
case
2:
return
"Pending"
;
break
;
case
3:
return
"Solved"
;
break
;
case
5:
return
"Closed"
;
break
;
}
}
},
There is a "console.log" when this parser gets called and what I notice is that AFTER! I filter for "New" the log reads:
n stat
undefined
"stat"
...when I first run the page the log reads (as expected):
1
"stat"
2
"stat"
3
"stat"
The Filter does not work (try filtering for "New" as an example)
Any help?