Apr 25, 2012, 10:44 AM
Gridpanel Row reordering not working
Dear Sir,
Gridpanel Row reordering is not working for first 2 rows. it is working from second row.
I can drop the row after second row only.
Thanks
Rupesh
Gridpanel Row reordering is not working for first 2 rows. it is working from second row.
I can drop the row after second row only.
<script type="text/javascript">
var notifyDrop12 = function (ddSource, e, data) {
var index = ddSource.grid.getView().findRowIndex(e.target),
store = ddSource.grid.getStore();
store.remove(ddSource.dragData.selections);
index = index > store.getCount() ? store.getCount() : index;
store.insert(index, ddSource.dragData.selections);
return true;
};
</script>
<ext:Panel runat="server" ID="pnlCircuitSets" Hidden="true">
<Items>
<ext:GridPanel runat="server" ID="grdSets" AutoExpandColumn="Title4" AutoHeight="true" Title="Circuit Sets Details" EnableDragDrop="true" DDGroup="ddGroupCC">
<SelectionModel>
<ext:RowSelectionModel ID="RowSelectionModel1CC" runat="server" SingleSelect="true">
</ext:RowSelectionModel>
</SelectionModel>
</ext:GridPanel>
</Items>
</ext:Panel>
<ext:DropTarget ID="DropTarget1CC"
runat="server"
Target="={#{grdSets}.view.scroller.dom}"
Group="ddGroupCC">
<NotifyDrop Fn="notifyDrop12" />
</ext:DropTarget>
Where I am going wrong?Thanks
Rupesh