Merge pull request #98 from prssanna/sort-fix
fix: 🐛 set content of empty cell to empty string for sorting
This commit is contained in:
commit
c263ab410e
@ -280,8 +280,11 @@ export default class DataManager {
|
|||||||
this.rowViewOrder.sort((a, b) => {
|
this.rowViewOrder.sort((a, b) => {
|
||||||
const aIndex = a;
|
const aIndex = a;
|
||||||
const bIndex = b;
|
const bIndex = b;
|
||||||
const aContent = this.getCell(colIndex, a).content;
|
|
||||||
const bContent = this.getCell(colIndex, b).content;
|
let aContent = this.getCell(colIndex, a).content;
|
||||||
|
let bContent = this.getCell(colIndex, b).content;
|
||||||
|
aContent = aContent == null ? '' : aContent;
|
||||||
|
bContent = bContent == null ? '' : bContent;
|
||||||
|
|
||||||
if (sortOrder === 'none') {
|
if (sortOrder === 'none') {
|
||||||
return aIndex - bIndex;
|
return aIndex - bIndex;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user