PDA

View Full Version : Drag grid detail to Dataview



tomalex0
5 Aug 2009, 6:45 AM
I like to obtain a feature so that i can drag grid rows to a dataview store (which is in a Panel).I only want to get the id assigned for each row in the dataview when dropped in to the dataview store

I like to move in a way that the dropped row must not be removed from the grid





this.grid = new Ext.grid.EditorGridPanel({
id: 'userDomainGrid',
ddGroup : 'gridDDGroup',
store: this.store,
enableDragDrop : true,
columns: this.columnModel,
enableColLock: false,
plugins:chkColumn,
stripeRows : true,
loadMask:true,
viewConfig: {
forceFit: true
},

selModel: new Ext.grid.RowSelectionModel({
singleSelect: true
})});
How could i make the dataview store as a container which accepts drop data from grid.



this.folder=new Ext.DataView({
id:'folder',
itemSelector: 'div.thumb-wrap-folder',
style:'overflow:auto',
multiSelect: false,
singleSelect:true,
store: new Ext.data.JsonStore({
url:'details.php?task=getUserFolder',
autoLoad: true,
root: 'results',
storeId :'folderId',
fields:[
{name:'Id',mapping:'id'},
{name: 'name', mapping: 'name'},
{name: 'shortName', mapping: 'name', convert: this.shortName},
{name: 'path', mapping: 'image'},
{name: 'type', mapping: 'type'},
] })})thanks in advance