저는 그리드가 있고, 두 개의 열이 Name, Age
입니다. 이 표에는 여러 행이 있습니다 (예 : 20-30 레코드). 이제 행을 클릭하면 Person의 이름을 가져 와서 Label에 표시해야합니다.그리드에서 행 선택이 작동하지 않습니다.
나는 getRowClass: function(record, rowIndex, rowParams, store)
을 사용하면 선택한 행 값의 세부 정보를 얻을 수 있다고 생각했습니다. 그러나 이것은 작동하지 않습니다. 누군가 나를 도울 수 있습니까?
xtype: 'gridpanel',
height: 500,
width: 800,
title: 'Person Grid',
store: 'Person',
viewConfig: {
getRowClass: function(record, rowIndex, rowParams, store) {
console.log("Print the selected row data and set to label");
console.log(record);
console.log(rowIndex);
console.log(rowParams);
}
},
columns: [ .....