|
|
@@ -326,6 +326,8 @@
|
|
|
|
|
|
customSearch: $.noop,
|
|
|
|
|
|
+ customSort: $.noop,
|
|
|
+
|
|
|
rowStyle: function (row, index) {
|
|
|
return {};
|
|
|
},
|
|
|
@@ -850,6 +852,11 @@
|
|
|
order = this.options.sortOrder === 'desc' ? -1 : 1,
|
|
|
index = $.inArray(this.options.sortName, this.header.fields);
|
|
|
|
|
|
+ if (this.options.customSort !== $.noop) {
|
|
|
+ this.options.customSort.apply(this, [this.options.sortName, this.options.sortOrder]);
|
|
|
+ return;
|
|
|
+ }
|
|
|
+
|
|
|
if (index !== -1) {
|
|
|
this.data.sort(function (a, b) {
|
|
|
if (that.header.sortNames[index]) {
|
|
|
@@ -2802,7 +2809,8 @@
|
|
|
sprintf: sprintf,
|
|
|
getFieldIndex: getFieldIndex,
|
|
|
compareObjects: compareObjects,
|
|
|
- calculateObjectValue: calculateObjectValue
|
|
|
+ calculateObjectValue: calculateObjectValue,
|
|
|
+ getItemField: getItemField
|
|
|
};
|
|
|
|
|
|
// BOOTSTRAP TABLE INIT
|