@@ -167,7 +167,6 @@ class BootstrapTable extends React.Component {
167
167
sortName = { this . props . options . sortName }
168
168
sortOrder = { this . props . options . sortOrder }
169
169
onSort = { this . handleSort . bind ( this ) }
170
- onRowClick = { this . handleRowClick . bind ( this ) }
171
170
onSelectAllRow = { this . handleSelectAllRow . bind ( this ) }
172
171
bordered = { this . props . bordered } >
173
172
{ this . props . children }
@@ -227,8 +226,8 @@ class BootstrapTable extends React.Component {
227
226
}
228
227
229
228
handleRowClick ( row ) {
230
- if ( this . props . selectRow . onRowClick ) {
231
- this . props . selectRow . onRowClick ( row ) ;
229
+ if ( this . props . options . onRowClick ) {
230
+ this . props . options . onRowClick ( row ) ;
232
231
}
233
232
}
234
233
@@ -512,7 +511,6 @@ BootstrapTable.propTypes = {
512
511
mode : React . PropTypes . string ,
513
512
bgColor : React . PropTypes . string ,
514
513
selected : React . PropTypes . array ,
515
- onRowClick : React . PropTypes . func ,
516
514
onSelect : React . PropTypes . func ,
517
515
onSelectAll : React . PropTypes . func ,
518
516
clickToSelect : React . PropTypes . bool ,
@@ -535,6 +533,7 @@ BootstrapTable.propTypes = {
535
533
afterTableComplete : React . PropTypes . func ,
536
534
afterDeleteRow : React . PropTypes . func ,
537
535
afterInsertRow : React . PropTypes . func ,
536
+ onRowClick : React . PropTypes . func ,
538
537
page : React . PropTypes . number ,
539
538
sizePerPageList : React . PropTypes . array ,
540
539
sizePerPage : React . PropTypes . number ,
@@ -558,7 +557,6 @@ BootstrapTable.defaultProps = {
558
557
mode : Const . ROW_SELECT_NONE ,
559
558
bgColor : Const . ROW_SELECT_BG_COLOR ,
560
559
selected : [ ] ,
561
- onRowClick : undefined ,
562
560
onSelect : undefined ,
563
561
onSelectAll : undefined ,
564
562
clickToSelect : false ,
@@ -582,6 +580,7 @@ BootstrapTable.defaultProps = {
582
580
afterTableComplete : undefined ,
583
581
afterDeleteRow : undefined ,
584
582
afterInsertRow : undefined ,
583
+ onRowClick : undefined ,
585
584
page : 1 ,
586
585
sizePerPageList : Const . SIZE_PER_PAGE_LIST ,
587
586
sizePerPage : Const . SIZE_PER_PAGE_LIST [ 0 ] ,
0 commit comments