我正在尝试将 jqgrid 集成到我的应用程序中,但出现寻呼机未找到错误。
这里是进口。
<link rel="stylesheet" type="text/css" href="/Scripts/themes/steel/grid.css" title="steel" media="screen" />
<link href="/Scripts/themes/jqModal.css" rel="stylesheet" type="text/css" />
<script src="/Scripts/Lib/jquery-1.4.2.js" type="text/javascript" language="javascript"></script>
<script src="/Scripts/Lib/jquery.blockUI.js" type="text/javascript"></script>
<script src="/Scripts/Lib/jquery.bgiframe.js" type="text/javascript" language="javascript"></script>
<script src="/Scripts/Lib/js/grid.locale-en.js" type="text/javascript"></script>
<script src="/Scripts/Lib/jquery.jqGrid.js" type="text/javascript"></script>
<script src="/Scripts/Lib/jquery.jqGrid.min.js" type="text/javascript"></script>
<script src="/Scripts/Lib/js/jqModal.js" type="text/javascript"></script>
<script src="/Scripts/Lib/js/jqDnR.js" type="text/javascript"></script>
这是我的 .htm 文件
<body>
<div id="report-tab">
<h2>Customers List</h2>
<table id="list" class="scroll" cellpadding="0" cellspacing="0" width="100%">
</table>
<div id="pager"></div>
</div>
</body>
这是我的 report.js 文件代码
var ReportTab = function () {
return {
Init: function () {
// jQuery(document).ready(function () {
var test = $('#list');
var Pager1 = $('#pager');
test.jqGrid({
Url: "/Home/GridData",
datatype: 'json',
mtype: 'GET',
colNames: ['Id', 'Votes', 'Title'],
colModel: [
{ name: 'Id', index: 'Id', width: 40, align: 'left' },
{ name: 'Votes', index: 'Votes', width: 40, align: 'left' },
{ name: 'Title', index: 'Title', width: 200, align: 'left'}],
pager : $('#pager'),
rowNum: 10,
rowList: [5, 10, 20, 50],
sortname: 'Id',
sortorder: "desc",
viewrecords: true,
imgpath: '/scripts/themes/steel/images',
caption: 'My first grid'
}).navGrid(pager, { edit: false, add: false, del: false, refresh: true, search: false });
// });
}
}
} ();
帮助解决问题
提前致谢。