PDA

View Full Version : [INFOREQ]GroupingGrid error



Sesshomurai
30 May 2010, 1:43 PM
Using a GroupingGrid, I have a custom renderer for one of the columns.



function renderOutputFile(value,metadata,record,row,col,store) {
var pos = record.data.mime.indexOf("/");

var mime = record.data.mime.substring(pos+1);
if(record.data.mime.indexOf("video")==0) {
return "<a href=\"javascript:showVideo('jsp/get-media.jsp?name="+record.data.filename+"&object="+record.data.data+"&repository="+record.data.repository+"&type="+record.data.mime+"','"+record.data.mime+"','"+record.data.filename+"')\">"+record.data.filename+"</a>"
} else
return String.format('<a href="jsp/get-media.jsp?name={4}&object={0}&repository={1}&type={2}&inline=true" target="_new">{4}</a>',record.data.data,record.data.repository,record.data.mime,mime,record.data.filename);
}


Attempting to Group by this field using the grid, causes this error on the first click:



sorters[0] is undefined
[Break on this error] this.singleSort(sorters[0].field, sorters[0].direction);
ext-all-debug.js (line 22112)


Click the group by field menu a second time causes the grid to go into group view by that field. However, the fields are not grouped. The same value appears in separate groups.

Other columns, will, at times produce the same error without a custom renderer. The grid has the filters plugin and the panlerow expander plugin.

evant
30 May 2010, 8:05 PM
Please follow the guidelines when posting to the bug forum.

http://www.extjs.com/forum/showthread.php?71015-Posting-to-the-Bug-Forum