I was testing my jqgrid and when I was attempting to add details through jqgrid's modal window I came across the following error in my firebug console.
Access to property denied" code: "1010
checkValues("2010-04-20", 5, table#list.ui-jqgrid-btable)grid.common.js (line 441)
postIt()grid.formedit.js (line 794)
anonymous(Object originalEvent=Event click type=click)grid.formedit.js (line 463)
anonymous(Object originalEvent=Event click type=click)jquery-1....2.min.js (line 19)
anonymous()jquery-1....2.min.js (line 19)
Where do I start in solving this issue?
Below is my jqgrid code
<div class="grid">
<!-- the grid definition in html is a table tag with class 'scroll' -->
<table id="list" class="scroll" cellpadding="0" cellspacing="0"></table>
<!-- pager definition. class scroll tels that we want to use the same theme as grid -->
<div id="pager" class="scroll" style="text-align:center;"></div>
</div>
<script type="text/javascript">
$(document).ready(function(){
$("#list").jqGrid({
width: 800,
height: 240,
autowidth: false,
rownumbers: true,
rownumWidth: 40,
url:'<?php echo $this->baseUrl() ?>/expensedetails/list',
datatype: 'json',
mtype: 'POST',
colNames:['ID','TYPEID','Description','Amount','Date'],
colModel :[
{name:'id', index:'id',
width:10,
hidden:true
},
{name:'expense_details_linktype', index:'expense_details_linktype',
width:10,
hidden:true
},
{name:'expense_details_desc', index:'expense_details_desc',
sortable:true,
editable:true,
edittype:"select",
editoptions:{value:"<?php echo $values?>"},
editrules:{required:true},
searchoptions:{sopt:['eq','ne','bw','bn','in','ni','ew','en','cn','nc']}
},
{name:'expense_details_amount', index:'expense_details_amount',
width:30,
sortable:true,
editable:true,
editoptions:{size:10},
editrules:{number:true,required:true}
},
{name:'expense_details_date', index:'expense_details_date',
width:40,
sortable:true,
editable:true,
editrules:{date:true,required:true},
searchoptions:{sopt:['eq','ne','lt','le','gt','ge']},
editoptions: {
size: 10, maxlengh: 10,
dataInit: function(el) {
$(el).datepicker({dateFormat: 'yy-mm-dd'})
},
defaultValue: function(){
var currentTime = new Date();
var month = parseInt(currentTime.getMonth() + 1);
month = month <= 9 ? "0"+month : month;
var day = currentTime.getDate();
day = day <= 9 ? "0"+day : day;
var year = currentTime.getFullYear();
return year+"-"+month + "-"+day;
}
}
}
],
pager: $('#pager'),
rowNum:10,
rowList:[10,20,30],
sortname: 'expense_details_date',
sortorder: "desc",
viewrecords: true,
viewsortcols: [true,'horizontal',true],
gridview: false,
hidegrid: false,
editurl:"<?php echo $this->baseUrl() ?>/expensedetails/edit",
caption: 'Enter or Adjust Your Expenses',
forceFit : true
});
$("#list").jqGrid('navGrid','#pager',
{add:true,addtext:'Add',edit:true,edittext:'Edit',del:true,deltext:'Delete',view:true,viewtext:'View',search:true,searchtext:'Search',refresh:true,refreshtext:'Refresh'},
{url:'<?php echo $this->baseUrl() ?>/expensedetails/edit',closeAfterEdit:'true'},
{url:'<?php echo $this->baseUrl() ?>/expensedetails/add',closeAfterAdd:'true'},
{url:'<?php echo $this->baseUrl() ?>/expensedetails/delete',closeAfterAdd:'true'}
);
$("#list").jqGrid('searchGrid', {multipleSearch:true} );
});
</script>