Note that there are some explanatory texts on larger screens.

plurals
  1. POjqGrid Search raises error: TypeError: Cannot read property 'searchrules' of undfined
    primarykey
    data
    text
    <p>When I switched the jqGrid to use the advanced search - it seems to work fine, except it pops up with the above error "TypeError: Cannot read property 'searchrules' of undfined" in Chrome when you hit the find button. Weirdly in Firefox the error is: "TypeError: g is undefined".</p> <p>If I just click ok to the error, the page posts back to my MVC controller just fine. I just want the error to go - any ideas? Here is the grid code:</p> <pre><code>jQuery("#list").jqGrid({ url: '/Audit/GridData/', datatype: 'json', mtype: 'GET', colNames: ['Id', 'Date', 'Username', 'ObjectName', 'Event', 'Module'], colModel: [ { name: 'Id', index: 'Id', width: 100, align: 'left', searchrules: { required: true }, search: true }, { name: 'Date', index: 'DateStamp', width: 100, align: 'left', searchrules: { required: true }, search: true }, { name: 'Username', index: 'Username', width: 200, align: 'left', searchrules: { required: true }, search: true }, { name: 'ObjectName', index: 'ObjectType', width: 200, align: 'left', searchrules: { required: true }, search: true }, { name: 'Event', index: 'Event', width: 120, align: 'left', searchrules: { required: true }, search: true }, { name: 'Module', index: 'Module', width: 120, align: 'left', searchrules: { required: true }, search: true}], pager: '#pager', rowNum: 10, postData: { filters: '{"groupOp":"AND","rules":[{"field":"invdate","op":"gt","data":"2007-09-06"},{"field":"invdate","op":"lt","data":"2007-10-04"},{"field":"name","op":"bw","data":"test"}]}' }, pgbuttons: true, rowList: [5, 10, 20, 50], sortname: 'Id', sortorder: "desc", viewrecords: true, imgpath: 'http://ajax.aspnetcdn.com/ajax/jquery.ui/1.8.16/themes/redmond/images/', caption: 'Audits' }).navGrid('#pager', { search: true, edit: false, add: false, del: false, searchtext: "Search" }, {}, {}, {}, { multipleSearch: true, sopt: ['eq', 'bw', 'cn', 'gt', 'lt'] }); </code></pre> <p>Thanks</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload