mirror of
https://github.com/gosticks/react-bootstrap-table2.git
synced 2025-10-16 11:55:39 +00:00
20180827 release
This commit is contained in:
parent
26c184d966
commit
6905c4dfa8
@ -65,7 +65,7 @@ It's simple!! configure [`sortFunc`](./column-props.html#columnsortfunc-function
|
||||
text: 'Product ID',
|
||||
sort: true
|
||||
// Perform a reverse sorting here
|
||||
sortFunc: (a, b, order, dataField) => {
|
||||
sortFunc: (a, b, order, dataField, rowA, rowB) => {
|
||||
if (order === 'asc') {
|
||||
return b - a;
|
||||
}
|
||||
|
||||
@ -107,13 +107,13 @@ It's only used for [`column.formatter`](#columnformatter-function), you can defi
|
||||
Enable the column sort via a `true` value given.
|
||||
|
||||
## column.sortFunc - [Function]
|
||||
`column.sortFunc` only work when `column.sort` is enable. `sortFunc` allow you to define your sorting algorithm. This callback function accept four arguments:
|
||||
`column.sortFunc` only work when `column.sort` is enable. `sortFunc` allow you to define your sorting algorithm. This callback function accept six arguments:
|
||||
|
||||
```js
|
||||
{
|
||||
// omit...
|
||||
sort: true,
|
||||
sortFunc: (a, b, order, dataField) => {
|
||||
sortFunc: (a, b, order, dataField, rowA, rowB) => {
|
||||
if (order === 'asc') return a - b;
|
||||
else return b - a;
|
||||
}
|
||||
|
||||
23
website/blog/2018-08-27-version-bump.md
Normal file
23
website/blog/2018-08-27-version-bump.md
Normal file
@ -0,0 +1,23 @@
|
||||
---
|
||||
title: New Release (2018-08-27)
|
||||
author: Allen Fang
|
||||
authorURL: https://twitter.com/allenfang_tw
|
||||
---
|
||||
|
||||
## Changed Packages
|
||||
|
||||
This release bump following packages:
|
||||
|
||||
* `react-bootstrap-table-next@1.1.3`
|
||||
|
||||
## Changelog
|
||||
|
||||
### Bug fixes
|
||||
* Fixed `selectRow.onSelectAll` will return `undefined` value after search([#509](https://github.com/react-bootstrap-table/react-bootstrap-table2/issues/509))
|
||||
|
||||
### Features
|
||||
N/A
|
||||
|
||||
### Enhancements
|
||||
* Fixed some wrong code in storybooks
|
||||
* `column.sortFunc` now pass rowA and rowB([#508](https://github.com/react-bootstrap-table/react-bootstrap-table2/issues/508))
|
||||
Loading…
Reference in New Issue
Block a user