-
19 Nov 2008 11:08 AM #391
Drag and Drop
Drag and Drop
Has anyone successfully implemented a live grid with drag and drop enabled?
I realize that removing a record from the grid would screw with the index, but what I'd actually want to do is copy a record from the livegrid to another store, so i wouldn't be removing anything from the livegrid.
Setting enableDragDrop to true seems to break the grid. Any suggestions?
-
19 Nov 2008 11:15 AM #392
Well, it should not. First off: Are you including the DragZone.js file that comes with the Ext.ux.Livegrid?
Secondly: Removing a record from the grid's store does not mess up the index. In fact, this was one of the major features I've worked on for the upcoming 0.3 release. Please see the "bulkRemove"-method from the Ext.ux.grid.livegrid.Store. If you experience any problems, please post a code-sample along with the error that gets thrown.
HTH
Thorsten
-
19 Nov 2008 11:22 AM #393
Hi. Thank you, but it doesn't work.
Looks like the event is not triggered when the livegrid is refreshed. I think the event should be triggered if I have rows selected and if I issue a refresh, it should either keep the rows selected (it's not happening, at least visually) or should trigger the event.
The code below is never executed when you issue a refresh:
Code:menuBrowserSelModel = new Ext.ux.grid.livegrid.RowSelectionModel(); menuBrowserSelModel.on('selectionchange', function(sm){ var removeButton = Ext.getCmp('menuBrowserRemoveButton'); console.log(sm); if (sm.getSelections().length == 0) { removeButton.disable(); } else { removeButton.enable(); } });
-
19 Nov 2008 11:44 AM #394
Thorsten,
Thanks for your quick response, you were absolutely right, I forgot to included the DragZone.js! D'oh!
It looks like this should work now... Thanks Again!
-
19 Nov 2008 11:48 AM #395
-
19 Nov 2008 11:49 AM #396
-
20 Nov 2008 4:58 AM #397
Is any working example for a EditorLiveGrid available out there?
-
20 Nov 2008 5:03 AM #398
-
20 Nov 2008 6:21 AM #399
-
20 Nov 2008 6:25 AM #400


Reply With Quote

