-
9 Jan 2013 8:24 AM #1
Problem when grouping by a column with a ComboBox editor and render
Problem when grouping by a column with a ComboBox editor and render
Hi,
I'm trying to add grouping feature to my grids but when I try to group by a column that has a ComboBox editor and a renderer to display the displayField's value of the selected record in ComboBox, the group doesn't show the displayed/rendered value: it shows the raw value of the column.
I tried to use the groupHeaderTpl: '{columnName}: {name}' and groupHeaderTpl: '{columnName}: {renderedGroupValue}' but neither worked. I get the result "Company: 1" while I expect to see the result "Company: ABC".
Hope that there is an easy fix that I can apply to solve this very basic problem.
Thanks in advance
Ipek
-
11 Jan 2013 1:13 AM #2
Today I started to use ext-4.2.0.265-beta.zip. But the problem still persists

-
11 Jan 2013 5:29 AM #3
Since no one gave a suggestion on how to fix the problem we studied the code in order to fix it by ourselves.
Here is a fix that we have applied to set the rendered value of a column that is being grouped, to the renderedGroupValue in setupRowData function of Grouping.js
Code:setupRowData: function(record, idx, rowValues) { ................. ................. if (rowValues.isFirstRow) { groupInfo.groupField = groupField; groupInfo.name = groupName; groupInfo.renderedGroupValue = groupName; if (header.renderer && header.renderer.call) { groupInfo.renderedGroupValue = header.renderer.call(header, groupName, null, record, idx, me.view.headerCt.getHeaderIndex(header), store, me.view); }


Reply With Quote