[#407] support for row reordering in grid
This commit is contained in:
@@ -77,12 +77,12 @@ var createExplorer = function(dataset, state) {
|
|||||||
state: {
|
state: {
|
||||||
gridOptions: {
|
gridOptions: {
|
||||||
editable: true,
|
editable: true,
|
||||||
// Enable support for row add
|
// Enable support for row add
|
||||||
enabledAddRow: true,
|
enabledAddRow: true,
|
||||||
// Enable support for row delete
|
// Enable support for row delete
|
||||||
enabledDelRow: true,
|
enabledDelRow: true,
|
||||||
// Enable support for row Reoder
|
// Enable support for row Reoder
|
||||||
enableReOrderRow:true,
|
enableReOrderRow:true,
|
||||||
autoEdit: false,
|
autoEdit: false,
|
||||||
enableCellNavigation: true
|
enableCellNavigation: true
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -155,15 +155,15 @@ my.SlickGrid = Backbone.View.extend({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
//Add row delete support, check if enabledDelRow is set to true , by
|
//Add row delete support, check if enableReOrderRow is set to true , by
|
||||||
//default it is set to false
|
//default it is set to false
|
||||||
// state: {
|
// state: {
|
||||||
// gridOptions: {
|
// gridOptions: {
|
||||||
// enabledDelRow: true,
|
// enableReOrderRow: true,
|
||||||
// },
|
// },
|
||||||
if(this.state.get("gridOptions")
|
if(this.state.get("gridOptions")
|
||||||
&& this.state.get("gridOptions").enabledDelRow != undefined
|
&& this.state.get("gridOptions").enableReOrderRow != undefined
|
||||||
&& this.state.get("gridOptions").enabledDelRow == true ){
|
&& this.state.get("gridOptions").enableReOrderRow == true ){
|
||||||
columns.push({
|
columns.push({
|
||||||
id: "#",
|
id: "#",
|
||||||
name: "",
|
name: "",
|
||||||
@@ -174,15 +174,15 @@ my.SlickGrid = Backbone.View.extend({
|
|||||||
cssClass: "recline-cell-reorder"
|
cssClass: "recline-cell-reorder"
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
//Add row delete support, check if enableReOrderRow is set to true , by
|
//Add row delete support, check if enabledDelRow is set to true , by
|
||||||
//default it is set to false
|
//default it is set to false
|
||||||
// state: {
|
// state: {
|
||||||
// gridOptions: {
|
// gridOptions: {
|
||||||
// enableReOrderRow: true,
|
// enabledDelRow: true,
|
||||||
// },
|
// },
|
||||||
if(this.state.get("gridOptions")
|
if(this.state.get("gridOptions")
|
||||||
&& this.state.get("gridOptions").enableReOrderRow != undefined
|
&& this.state.get("gridOptions").enabledDelRow != undefined
|
||||||
&& this.state.get("gridOptions").enableReOrderRow == true ){
|
&& this.state.get("gridOptions").enabledDelRow == true ){
|
||||||
columns.push({
|
columns.push({
|
||||||
id: 'del',
|
id: 'del',
|
||||||
name: '',
|
name: '',
|
||||||
|
|||||||
Reference in New Issue
Block a user