Reputation: 73
I have a strange problem with my sopt search options in my jqgrid. I have specified the sopt fields I want but strangely it displays all the options on some fields and for some it displays the ones I've specified. Here is my code
grid3 = $('#BillInformation').jqGrid({
url: 'CaseInfo/DisplayBillInfoGrid/' + '?caseID=' + caseID,
datatype: 'json',
mtype: 'post',
colNames: ['CaseID', 'Case Status', 'Billing Type', 'Date of Service', 'CPT Code', 'Units', 'Invoice #', 'PackageID',
'Billing Date', 'Payment Date', 'Provider Due', 'Provider Charge', 'Medrisk Charge', 'Amount Billed', 'Less Savings',
'Amount Collected', 'Adjusted', 'Refunded', 'Provider Charge Date'],
colModel: [
{ name: 'CaseID', index: 'CaseID', width: 70, align: 'left', formatter: genericcursor,
searchOptions: { sopt: ['eq', 'ne'] }
}, // DISPLAYS ALL THE SOPTS
{ name: 'CaseStatus', index: 'CaseStatus', width: 75, align: 'left',
searchOptions: { sopt: ['cn', 'nc', 'eq', 'ne'] }
}, // DISPLAYS ALL THE SOPTS
...
{ name: 'Date of Service', index: 'Date_of_Service', width: 100, align: 'left', formatter: dosbutton,
searchoptions: { sopt: ['eq', 'ne', 'lt', 'le', 'gt', 'ge'] }
}, // DISPLAYS THE SOPTS I'VE SPECIFIED
...
});
grid3.jqGrid('navGrid', '#pager', { edit: false, add: false, del: false, refresh: false },
{}, {}, {}, { multipleSearch: true, overlay: false });
I'm really stumped as to why this is happening and any help would be appreciated. Thanks
Upvotes: 0
Views: 1126
Reputation: 222017
There are searchoptions option, but no searchOptions
which you use in the 'CaseID'
and 'CaseStatus'
. You should just write the name in correct case.
Upvotes: 1