mirror of
https://github.com/primefaces/primevue.git
synced 2025-05-09 17:02:38 +00:00
Fixed #216 - sortfield is ignored
This commit is contained in:
parent
12a4d2a930
commit
cbddaf266e
1 changed files with 2 additions and 2 deletions
|
@ -86,7 +86,7 @@ export default {
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getColumnHeaderClass(column) {
|
getColumnHeaderClass(column) {
|
||||||
const sorted = this.sortMode === 'single' ? (this.sortField === (column.field || column.sortField)) : this.getMultiSortMetaIndex(column) > -1;
|
const sorted = this.sortMode === 'single' ? (this.sortField === column.field || this.sortField === column.sortField) : this.getMultiSortMetaIndex(column) > -1;
|
||||||
|
|
||||||
return [column.headerClass,
|
return [column.headerClass,
|
||||||
{'p-sortable-column': column.sortable},
|
{'p-sortable-column': column.sortable},
|
||||||
|
@ -99,7 +99,7 @@ export default {
|
||||||
let sortOrder = null;
|
let sortOrder = null;
|
||||||
|
|
||||||
if (this.sortMode === 'single') {
|
if (this.sortMode === 'single') {
|
||||||
sorted = this.sortField === (column.field || column.sortField);
|
sorted = (this.sortField === column.field || this.sortField === column.sortField);
|
||||||
sortOrder = sorted ? this.sortOrder: 0;
|
sortOrder = sorted ? this.sortOrder: 0;
|
||||||
}
|
}
|
||||||
else if (this.sortMode === 'multiple') {
|
else if (this.sortMode === 'multiple') {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue