Reputation: 49
I'm using jqGrid 4.13.0 and it seems to cause an error when using IE8. The error is localized in the jquery.fmatter
module.
The YesObject
and NoObject
use Object.create
which is not IE8 compatible. Any idea for a workaround ? Many thanks.
var fmatter = $.fmatter,
getOptionByName = function (colModel, name) {
...
},
parseCheckboxOptions = function (options) {
...
},
YesObject = Object.create(null, {
1: { value: 1 },
x: { value: 1 },
"true": { value: 1 },
yes: { value: 1 },
on: { value: 1 }
}),
NoObject = Object.create(null, {
0: { value: 1 },
"false": { value: 1 },
no: { value: 1 },
off: { value: 1 }
});
Upvotes: 1
Views: 52
Reputation: 222017
Thank you very much for the bug report! I have technical problems to test free jqGrid on IE8, but I don't want to drop support it till it will be really required.
The reason of the strange usage of Object.create
was the test, which shows how one can better test the existence of element in array. On my tests with all modern web browsers the way with Object.create
was better and I've chosen it initially.
I committed the bug fix to GitHub. Please get the latest source from the repository.
Upvotes: 1