templatecolumn列:
{
xtype: \'templatecolumn\',
tpl: [
\'<a style="color:blue;cursor:pointer" onClick="window.open(\\'/TestClass.ashx?method=GetRecordRemark&Id={Id}\\')">查看备注</a>\' //此处可以传递record对象里的属性,暂时没找到直接传递record对象的方法
],
text: \'查看备注\'
}
actioncolumn:
{
xtype: \'actioncolumn\',
dataIndex: \'WordPath\',
menuText: \'下载\',
text: \'下载word\',
items: [
{
handler: function(view, rowIndex, colIndex, item, e, record, row) {
//alert(\'download word:\'+record.data.WordPath);
window.open("/DataService/"+record.data.WordPath); //可传递record对象,操作稍显复杂.
},
text: \'下载\',
altText: \'下载\',
icon: \'imgs/kan.png\'
}
]
}
renderer:
{
xtype: \'gridcolumn\',
renderer: function(value, metaData, record, rowIndex, colIndex, store, view) {
return \'<a style="cursor:pointer;color:blue" >\'+value+record.data.Id+\'</a>\';
},
dataIndex: \'ParentName\',
text: \'操作\'
},
版权声明:本文为博主原创文章,未经博主允许不得转载。