tnx-shared 5.3.194 → 5.3.196
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/tnx-shared.umd.js +19 -3
- package/bundles/tnx-shared.umd.js.map +1 -1
- package/bundles/tnx-shared.umd.min.js +1 -1
- package/bundles/tnx-shared.umd.min.js.map +1 -1
- package/classes/base/list-component-base.d.ts +1 -0
- package/classes/base/list-component-base.d.ts.map +1 -1
- package/esm2015/classes/base/list-component-base.js +20 -4
- package/esm2015/models/export-item.js +1 -1
- package/fesm2015/tnx-shared.js +19 -3
- package/fesm2015/tnx-shared.js.map +1 -1
- package/models/export-item.d.ts +3 -0
- package/models/export-item.d.ts.map +1 -1
- package/package.json +2 -2
- package/tnx-shared.metadata.json +1 -1
|
@@ -21774,6 +21774,7 @@
|
|
|
21774
21774
|
_this.FileUploadMode = exports.FileUploadMode;
|
|
21775
21775
|
_this.Operator = exports.Operator;
|
|
21776
21776
|
_this.showSaveReorder = false;
|
|
21777
|
+
_this.settingDefault = new CrudListSetting();
|
|
21777
21778
|
_this._unSubscribeAll = new rxjs.Subject();
|
|
21778
21779
|
_this.handleSelectRow = function (evt, data) {
|
|
21779
21780
|
if (_this.setting.hasCustomHandleClickRow) {
|
|
@@ -22091,6 +22092,7 @@
|
|
|
22091
22092
|
ListComponentBase.prototype.ngOnInit = function () {
|
|
22092
22093
|
var e_1, _g;
|
|
22093
22094
|
var _this = this;
|
|
22095
|
+
this.settingDefault = Object.assign({}, this.setting);
|
|
22094
22096
|
this.subscribe(ComCtxConstants.COMMON.ENTITY_METADATA_RELOADED, function (service) {
|
|
22095
22097
|
_this.entityMetadataService = service;
|
|
22096
22098
|
});
|
|
@@ -22305,18 +22307,28 @@
|
|
|
22305
22307
|
}
|
|
22306
22308
|
temp.push(element);
|
|
22307
22309
|
var config = this_1.setting.columnSetting.details.find(function (p) { return p.columnCode == element.field; });
|
|
22310
|
+
var col = this_1.setting.cols.find(function (p) { return p.field == element.field; });
|
|
22308
22311
|
if (config && config.visible !== undefined && config.visible !== null) {
|
|
22309
22312
|
element.visible = config.visible;
|
|
22310
22313
|
}
|
|
22314
|
+
else if (col) {
|
|
22315
|
+
// element.visible = col.visible;
|
|
22316
|
+
}
|
|
22311
22317
|
if (element.label) {
|
|
22312
22318
|
element.label = this_1._translateService.instant(element.label);
|
|
22313
22319
|
}
|
|
22314
22320
|
if (config && config.textAlign !== undefined && config.textAlign !== null) {
|
|
22315
22321
|
element.textAlign = config.textAlign;
|
|
22316
22322
|
}
|
|
22323
|
+
else if (col) {
|
|
22324
|
+
// element.textAlign = col.textAlign;
|
|
22325
|
+
}
|
|
22317
22326
|
if (config && config.width !== undefined && config.width !== null) {
|
|
22318
22327
|
element.width = config.width;
|
|
22319
22328
|
}
|
|
22329
|
+
else if (col) {
|
|
22330
|
+
// element.width = col.width;
|
|
22331
|
+
}
|
|
22320
22332
|
if (element.dataType == null || element.dataType == undefined || element.dataType == '') {
|
|
22321
22333
|
element.dataType = exports.DataType.string;
|
|
22322
22334
|
}
|
|
@@ -22441,12 +22453,13 @@
|
|
|
22441
22453
|
var e_5, _g;
|
|
22442
22454
|
this.setting.groupColumn = colGroup;
|
|
22443
22455
|
var dataSetting = localStorage.getItem(ComCtxConstants.LOCALSTORAGE_KEY.COLUMN_SETTING);
|
|
22444
|
-
|
|
22456
|
+
var jsonData = this.tryParseJson(dataSetting);
|
|
22457
|
+
if (dataSetting && jsonData.valid && jsonData.value.length > 0) {
|
|
22445
22458
|
var pathName = location.pathname;
|
|
22446
22459
|
if (this.setting.settingKey) {
|
|
22447
22460
|
pathName += '/' + this.setting.settingKey;
|
|
22448
22461
|
}
|
|
22449
|
-
var settings =
|
|
22462
|
+
var settings = jsonData.value;
|
|
22450
22463
|
try {
|
|
22451
22464
|
for (var settings_1 = __values(settings), settings_1_1 = settings_1.next(); !settings_1_1.done; settings_1_1 = settings_1.next()) {
|
|
22452
22465
|
var element = settings_1_1.value;
|
|
@@ -22526,6 +22539,7 @@
|
|
|
22526
22539
|
if (index > -1)
|
|
22527
22540
|
columnSetting.splice(index, 1);
|
|
22528
22541
|
}
|
|
22542
|
+
// this.setting.columnSetting.details = [];
|
|
22529
22543
|
localStorage.setItem(ComCtxConstants.LOCALSTORAGE_KEY.COLUMN_SETTING, JSON.stringify(columnSetting));
|
|
22530
22544
|
};
|
|
22531
22545
|
ListComponentBase.prototype.getColorSetting = function () {
|
|
@@ -23429,8 +23443,10 @@
|
|
|
23429
23443
|
this._showSettings = false;
|
|
23430
23444
|
};
|
|
23431
23445
|
ListComponentBase.prototype.onDeleteSettings = function () {
|
|
23446
|
+
var _a, _b;
|
|
23432
23447
|
this._showSettings = false;
|
|
23433
|
-
this.setting.columnSetting = new ColumnSetting();
|
|
23448
|
+
// this.setting.columnSetting = new ColumnSetting();
|
|
23449
|
+
this.setting.columnSetting = (_b = (_a = this.settingDefault) === null || _a === void 0 ? void 0 : _a.columnSetting) !== null && _b !== void 0 ? _b : new ColumnSetting();
|
|
23434
23450
|
this.deleteColumnSetting();
|
|
23435
23451
|
this.extendColumns(this.setting.cols);
|
|
23436
23452
|
this.formatColumns(this.setting.cols);
|