@sumaris-net/ngx-components 2.4.3 → 2.4.5-rc1
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/doc/changelog.md +3 -0
- package/esm2020/src/app/core/services/platform.service.mjs +12 -3
- package/esm2020/src/app/core/table/entities-async-table-datasource.class.mjs +2 -2
- package/fesm2015/sumaris-net.ngx-components.mjs +12 -3
- package/fesm2015/sumaris-net.ngx-components.mjs.map +1 -1
- package/fesm2020/sumaris-net.ngx-components.mjs +12 -3
- package/fesm2020/sumaris-net.ngx-components.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -18511,8 +18511,17 @@ class PlatformService extends StartableService {
|
|
|
18511
18511
|
}
|
|
18512
18512
|
});
|
|
18513
18513
|
this.settings.onChange.subscribe(data => {
|
|
18514
|
-
if (data
|
|
18515
|
-
|
|
18514
|
+
if (data) {
|
|
18515
|
+
if (data.locale) {
|
|
18516
|
+
if (data.locale !== this.translate.currentLang) {
|
|
18517
|
+
this.translate.use(data.locale);
|
|
18518
|
+
}
|
|
18519
|
+
}
|
|
18520
|
+
else {
|
|
18521
|
+
// Applying default, when settings has no locale property (hotfix - ludovic.pecquot@e-is.pro - 14/11/2021 - since v1.20.42)
|
|
18522
|
+
console.warn('[platform] No locale found in settings: applying defaultLocale: ', this.environment.defaultLocale);
|
|
18523
|
+
this.translate.use(this.environment.defaultLocale);
|
|
18524
|
+
}
|
|
18516
18525
|
}
|
|
18517
18526
|
});
|
|
18518
18527
|
// Use account's settings, (like locale), when account inheritance enabled
|
|
@@ -29234,7 +29243,7 @@ class EntitiesAsyncTableDataSource extends AsyncTableDataSource {
|
|
|
29234
29243
|
return this.getRows().filter(row => row.editing);
|
|
29235
29244
|
}
|
|
29236
29245
|
getSingleEditingRow() {
|
|
29237
|
-
const rows = this.
|
|
29246
|
+
const rows = this.getEditingRows();
|
|
29238
29247
|
return rows.length === 1 ? rows[0] : undefined;
|
|
29239
29248
|
}
|
|
29240
29249
|
hasSomeEditingRow() {
|