-
29 Apr 2011 1:18 PM #1
[OPEN-EXTJSIV-1812]beforeselect event on grid panel does not fire.
[OPEN-EXTJSIV-1812]beforeselect event on grid panel does not fire.
The beforeselect event on the grid panel does not fire.
-
24 May 2011 4:55 AM #2
-
25 May 2011 4:58 AM #3Ext JS Premium Member
- Join Date
- Apr 2008
- Location
- Groningen - Netherlands
- Posts
- 1,017
- Vote Rating
- 23
Is there a workaround for this? A missing beforeselect event is blocking my migration to ExtJs 4.
Terence
-
26 May 2011 3:31 AM #4
This workaround prevented only a visual select.PHP Code:Ext.override(Ext.selection.RowModel,
{
// Allow the GridView to update the UI by
// adding/removing a CSS class from the row.
onSelectChange: function(record, isSelected, suppressEvent) {
var me = this,
views = me.views,
viewsLn = views.length,
store = me.store,
rowIdx = store.indexOf(record),
i = 0,
allowSelect = true;
for (; i < viewsLn; i++) {
if (isSelected) {
allowSelect = me.fireEvent('beforeselect', me, record, rowIdx) !== false;
if (allowSelect) {
views[i].onRowSelect(rowIdx, suppressEvent);
if (!suppressEvent) {
me.fireEvent('select', me, record, rowIdx);
}
}
} else {
views[i].onRowDeselect(rowIdx, suppressEvent);
if (!suppressEvent) {
me.fireEvent('deselect', me, record, rowIdx);
}
}
}
}
});
-
26 May 2011 4:44 AM #5Ext JS Premium Member
- Join Date
- Apr 2008
- Location
- Groningen - Netherlands
- Posts
- 1,017
- Vote Rating
- 23
I need a full working beforeselect. I also wonder why this event in no longer part of the RowSelectionModel. It's in the grid view.
beforeselect, select and after select must be implemented somehow. A row select changes the information state in an application. I use beforeselect for validation if any record on the screen is in edit mode. Then you get a pop up etcera....
I am really amazed that this isn't a blocking issue for other programmers. This migration to ExtJs 4 is getting me on my nerves....
-
26 May 2011 6:41 AM #6
-
5 Jun 2011 1:13 PM #7Sencha - Community Support Team
- Join Date
- Jan 2009
- Location
- Palo Alto, California
- Posts
- 1,941
- Vote Rating
- 6
This is on top of the priority list for 4.0.2
Ext JS Senior Software Architect
Personal Blog: http://edspencer.net
Twitter: http://twitter.com/edspencer
Github: http://github.com/edspencer
-
5 Jun 2011 10:05 PM #8
The fix has been merged in to 4.0.2. There is also a beforedeselect event that can be used to prevent the selection from leaving a row. These events apply to grid and dataview as well.
Don Griffin
Ext JS Development Team Lead
Check the docs. Learn how to (properly) report a framework issue and a Sencha Cmd issue
"Use the source, Luke!"
-
5 Oct 2012 4:49 AM #9
It appears this is still not fixed in 4.1.2 ...
You found a bug! We've classified it as
a bug in our system.
We encourage you to continue the discussion and to find an acceptable workaround while we work on a permanent fix.
Similar Threads
-
[FIXED] DataView.beforeselect event is never actually fired
By jep in forum Sencha Touch 1.x: BugsReplies: 7Last Post: 20 Sep 2011, 8:09 AM -
[OPEN-EXTJSIV-589] CellEditing does not fire beforeedit, afteredit and validateedit
By christophe.geiser in forum Ext:BugsReplies: 1Last Post: 15 Apr 2011, 1:26 AM -
[OPEN-EXTJSIV-919] CheckHeader does not fire change event
By wiz61 in forum Ext:BugsReplies: 4Last Post: 11 Apr 2011, 7:34 PM -
[OPEN-EXTJSIV-196] change and keypress events do not fire for ComboBox
By sidamos77 in forum Ext:BugsReplies: 0Last Post: 21 Mar 2011, 5:56 AM


Reply With Quote