forked from extern/egroupware
Put selected columns into nextmatch value so columns are saved in favourites
This commit is contained in:
parent
b5f45f1e71
commit
afd2364979
@ -1101,7 +1101,7 @@ var et2_nextmatch = /** @class */ (function (_super) {
|
|||||||
jQuery.merge(colDisplay, custom_fields);
|
jQuery.merge(colDisplay, custom_fields);
|
||||||
// Update query value, so data source can use visible columns to exclude expensive sub-queries
|
// Update query value, so data source can use visible columns to exclude expensive sub-queries
|
||||||
var oldCols = this.activeFilters.selectcols ? this.activeFilters.selectcols : [];
|
var oldCols = this.activeFilters.selectcols ? this.activeFilters.selectcols : [];
|
||||||
this.activeFilters.selectcols = this.sortedColumnsList ? this.sortedColumnsList : colDisplay;
|
this.activeFilters.selectcols = this.sortedColumnsList.length > 0 ? this.sortedColumnsList : colDisplay;
|
||||||
// We don't need to re-query if they've removed a column
|
// We don't need to re-query if they've removed a column
|
||||||
var changed = [];
|
var changed = [];
|
||||||
ColLoop: for (var i = 0; i < colDisplay.length; i++) {
|
ColLoop: for (var i = 0; i < colDisplay.length; i++) {
|
||||||
@ -2016,6 +2016,10 @@ var et2_nextmatch = /** @class */ (function (_super) {
|
|||||||
"selected": idsArr
|
"selected": idsArr
|
||||||
};
|
};
|
||||||
jQuery.extend(value, this.activeFilters, this.value);
|
jQuery.extend(value, this.activeFilters, this.value);
|
||||||
|
if (typeof value.selectcols == "undefined" || value.selectcols.length === 0) {
|
||||||
|
this._updateUserPreferences();
|
||||||
|
value.selectcols = this.activeFilters.selectcols;
|
||||||
|
}
|
||||||
return value;
|
return value;
|
||||||
};
|
};
|
||||||
et2_nextmatch.prototype.resetDirty = function () { };
|
et2_nextmatch.prototype.resetDirty = function () { };
|
||||||
|
@ -1526,7 +1526,7 @@ export class et2_nextmatch extends et2_DOMWidget implements et2_IResizeable, et2
|
|||||||
// Update query value, so data source can use visible columns to exclude expensive sub-queries
|
// Update query value, so data source can use visible columns to exclude expensive sub-queries
|
||||||
const oldCols = this.activeFilters.selectcols ? this.activeFilters.selectcols : [];
|
const oldCols = this.activeFilters.selectcols ? this.activeFilters.selectcols : [];
|
||||||
|
|
||||||
this.activeFilters.selectcols = this.sortedColumnsList ? this.sortedColumnsList : colDisplay;
|
this.activeFilters.selectcols = this.sortedColumnsList.length > 0 ? this.sortedColumnsList : colDisplay;
|
||||||
|
|
||||||
// We don't need to re-query if they've removed a column
|
// We don't need to re-query if they've removed a column
|
||||||
const changed = [];
|
const changed = [];
|
||||||
@ -2714,6 +2714,12 @@ export class et2_nextmatch extends et2_DOMWidget implements et2_IResizeable, et2
|
|||||||
"selected": idsArr
|
"selected": idsArr
|
||||||
};
|
};
|
||||||
jQuery.extend(value, this.activeFilters, this.value);
|
jQuery.extend(value, this.activeFilters, this.value);
|
||||||
|
|
||||||
|
if(typeof value.selectcols == "undefined" || value.selectcols.length === 0)
|
||||||
|
{
|
||||||
|
this._updateUserPreferences();
|
||||||
|
value.selectcols = this.activeFilters.selectcols;
|
||||||
|
}
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
resetDirty( )
|
resetDirty( )
|
||||||
|
Loading…
Reference in New Issue
Block a user