2

根据某些条件,我想在我的 javascript 函数中动态启用或禁用 Name 列的链接。下面是我的网格代码:

jQuery("#paygrid").jqGrid({
url: url+'Payment/paymentList',
datatype: "xml",
colNames:["Name","Receiced Amount","Total Amount","Status","Mode","Id"],
colModel:[
    {name:"serviceProviderName",index:"serviceProviderName", width:180, align:"center",xmlmap:"serviceProviderName",formatter: 'showlink',
                               formatoptions: { baseLinkUrl: 'paymentdetail.html', idName: 'paymentId'}
                           },
    {name:"recievedAmount",index:"recievedAmount", width:140, align:"center",xmlmap:"recievedAmount",search: false},
    {name:"totalAmount",index:"totalAmount", width:140, align:"center",xmlmap:"totalAmount",search: false},
    {name:"status",index:"status", width:70, align:"center",xmlmap:"status"},
    {name:"paymentType",index:"paymentType", width:100, align:"center",xmlmap:"paymentType",search: false},
    {name:"paymentId"  ,index:"paymentId", width:200, key: true, hidden:"true", align:"center",xmlmap:"paymentId"}

],
height:250,
rowNum:100,
loadonce: true,
viewrecords: true,
gridview:true,
xmlReader: {
        root: "paymentList",
        row: "payment",
        repeatitems: false
},
toolbar: [true,"top"],
});

在此先感谢您的帮助。

4

0 回答 0