@sumaris-net/ngx-components 1.23.19 → 1.23.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/sumaris-net.ngx-components.umd.js +5 -3
- package/bundles/sumaris-net.ngx-components.umd.js.map +1 -1
- package/bundles/sumaris-net.ngx-components.umd.min.js +1 -1
- package/bundles/sumaris-net.ngx-components.umd.min.js.map +1 -1
- package/esm2015/src/app/core/form/entity-editor-modal.class.js +3 -2
- package/esm2015/src/app/core/table/table.class.js +2 -2
- package/esm2015/src/app/shared/services/memory-entity-service.class.js +3 -2
- package/fesm2015/sumaris-net.ngx-components.js +5 -3
- package/fesm2015/sumaris-net.ngx-components.js.map +1 -1
- package/package.json +1 -1
|
@@ -21237,7 +21237,8 @@
|
|
|
21237
21237
|
};
|
|
21238
21238
|
InMemoryEntitiesService.prototype.sort = function (data, sortBy, sortDirection) {
|
|
21239
21239
|
// Replace sortBy, using the replacement map
|
|
21240
|
-
sortBy = sortBy
|
|
21240
|
+
sortBy = sortBy || 'id';
|
|
21241
|
+
sortBy = this._sortByReplacement[sortBy] || sortBy;
|
|
21241
21242
|
// Execute the sort
|
|
21242
21243
|
return EntityUtils.sort(data, sortBy, sortDirection);
|
|
21243
21244
|
};
|
|
@@ -27369,7 +27370,7 @@
|
|
|
27369
27370
|
// Delete the row :
|
|
27370
27371
|
// - if newly created row (id = -1),
|
|
27371
27372
|
// - or if invalid and not editing (= not cancellable)
|
|
27372
|
-
if (row.id === -1 || (!row.editing && row.invalid)) {
|
|
27373
|
+
if (row.id === -1 || (!row.editing && row.invalid /*do not use !valid because if row is disabled, it will be always !valid */)) {
|
|
27373
27374
|
if (_this.debug)
|
|
27374
27375
|
console.debug("[table] Delete row #" + row.id);
|
|
27375
27376
|
row.delete();
|
|
@@ -30158,7 +30159,8 @@
|
|
|
30158
30159
|
.then(function () { return _this.load(); });
|
|
30159
30160
|
}
|
|
30160
30161
|
else {
|
|
30161
|
-
|
|
30162
|
+
// Use a timeout to avoid error 'NG0100: ExpressionChangedAfterItHasBeenCheckedError'
|
|
30163
|
+
setTimeout(function () { return _this.load(); });
|
|
30162
30164
|
}
|
|
30163
30165
|
};
|
|
30164
30166
|
AppEntityEditorModal.prototype.ngOnDestroy = function () {
|