react-redux-grid icon indicating copy to clipboard operation
react-redux-grid copied to clipboard

Column order not maintained for columns with custom renderers not mapped to a real dataIndex

Open LaurieSReynolds opened this issue 7 years ago • 1 comments

Version: 5.4.2 Browser: Chrome OS: macOS Sierra 10.12.16

Columns not mapped to a real dataIndex are appearing out of order. In the example below, the menu column should be the last column displayed, but instead it is the first column. If the column dataIndex does map the data, the column order is maintained.

QUESTION: Is there some other way to specify the column order besides the order in the array?

columns: [
{
      name: "Name",
     dateIndex: "name"
},
{
    name: "email",
   dataIndex: "email"
},
{
     name: "Menu",
     dataIndex: "menu" <----- no menu in the data
     renderer: {
        // show a menu icon
    }
}
]
data [
{
     name: Jane,
     email: [email protected],
    id: 1
},
{
     name: Rahul,
    email: [email protected],
    id: 2
}
]

LaurieSReynolds avatar Oct 02 '17 02:10 LaurieSReynolds

Right now the only way to configure the order of columns is to pass them in the order you'd like them displayed. However, that the menu column is being displayed first is a bug -- we should fix this!

bencripps avatar Oct 03 '17 14:10 bencripps