AllenFang / react-bootstrap-table

A Bootstrap table built with React.js
https://allenfang.github.io/react-bootstrap-table/
MIT License
2.23k stars 782 forks source link

How we can pass array on object with key and values in edit a drop down field. #1685

Open ManrajParmarSipl opened 6 years ago

ManrajParmarSipl commented 6 years ago

I am creating an project management with employee relationship. Need to show employee name but need to update employee id on add and edit.

<TableHeaderColumn dataField='employeename' dataSort dataFormat={ employeenameFormatter } editable={ { type: 'select', options: { values: [{"A":1},{"B":2}] }, validator: employeenameValidator } }>Employee Name

AllenFang commented 6 years ago

HI @ManrajParmarSipl we can't modify one of property of object,

BTW, can you describe the shape of your raw data object? thanks