我有一个像这样的网格
jQuery("#champDetail").jqGrid({
data: {},
height: 300,
width: 800,
colNames: ['ID', 'Combination No', 'Qty', 'SMT Program', 'SMT Machine',
'Product Date', 'Tracking No'],
colModel: [{ name: 'ID', width: 50 },
{ name: 'CombinationNo', width: 120, sortable: false },
{ name: 'QTY', width: 80, sortable: false, editable: true,
editrules: { custom: true, custom_func: QTYCheck} },
{ name: 'SMTProg', width: 120, sortable: false, editable: true },
{ name: 'SMTMach', width: 120, sortable: false, editable: true },
{ name: 'ProductDate', width: 120, sortable: false, editable: true },
{ name: 'TrackingNo', width: 100, sortable: false, editable: true }
],……………..
onCellSelect: function(rowid, colid) {
debugger;
if (colid == 3) {
var cm = jQuery("#champDetail").getRowData(rowid)
var temp = cm["QTY"]
$("#temp").keydown(function() {
alert("")
});
}
},……………………………..
选择单元格时,我想将 keydown 事件绑定到单元格,
但我无法触发事件。
这里有什么问题?