Changed parameters of sort method of Table

This commit is contained in:
Rijn 2017-01-16 01:27:02 -06:00
parent e49f796318
commit da020a63ee
2 changed files with 10 additions and 2 deletions

View file

@ -16,7 +16,15 @@
},
{
title: '年龄',
key: 'age'
key: 'age',
sortable: true,
sortMethod: function (a, b, type) {
if (type === 'asc') {
return a < b ? 1 : -1;
} else if (type === 'desc') {
return a > b ? 1 : -1;
}
}
},
{
title: '地址',