tnx-shared 5.3.318 → 5.3.319

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.
@@ -16216,7 +16216,7 @@ class DataFormBase extends ComponentBaseWithButton {
16216
16216
  valueBefore: valueBefore,
16217
16217
  valueAfter: valueAfter,
16218
16218
  enumLogType: (control instanceof EditorControlSchema || control instanceof TextAreaControlSchema)
16219
- ? EnumLogType.Table
16219
+ ? EnumLogType.Html
16220
16220
  : EnumLogType.Normal
16221
16221
  }));
16222
16222
  }
@@ -24108,6 +24108,42 @@ class ListBase extends ComponentBaseWithButton {
24108
24108
  return __awaiter(this, void 0, void 0, function* () {
24109
24109
  });
24110
24110
  }
24111
+ _exportAllDataWithTemplateCode(templateCode, isViewOnline = false) {
24112
+ var _a;
24113
+ return __awaiter(this, void 0, void 0, function* () {
24114
+ const lstRawData = (_a = (yield this.setting.baseService.getDataCustomRoute(this.plusUrl, this.currentGridInfo.filters, this.currentGridInfo.fields, this.currentGridInfo.sorts, -1, 1)).data) !== null && _a !== void 0 ? _a : [];
24115
+ const lstVisibleField = this.setting.cols
24116
+ .filter(item => item.visible && item.dataType !== 'trangThaiV5')
24117
+ .map(item => item.field);
24118
+ yield this.beforeExportAllData(lstRawData, lstVisibleField);
24119
+ yield this._crudService.getRefDataInDatasource(lstRawData, this.setting.fieldNeedGetRef);
24120
+ const lstData = lstRawData.map(rowData => this.modifyRowDataForExport(rowData));
24121
+ const data = {
24122
+ lstData: lstData
24123
+ };
24124
+ const sheet = new ExportItem({
24125
+ type: ExportItemType.ExcelSheet,
24126
+ templateCode,
24127
+ data: this.stringifyData(data),
24128
+ name: 'Sheet1'
24129
+ });
24130
+ const file = new ExportItem({
24131
+ type: ExportItemType.ExcelFile,
24132
+ name: this.setting.title ? this.setting.title : `Danh sách ${this.setting.objectName.toLocaleLowerCase()}`
24133
+ });
24134
+ file.children = [sheet];
24135
+ yield this.modifyDataForExportAll(data);
24136
+ const _templateInstanceService = this._injector.get(TemplateInstanceService);
24137
+ return _templateInstanceService.exportNormal(file);
24138
+ });
24139
+ }
24140
+ modifyDataForExportAll(data) {
24141
+ return __awaiter(this, void 0, void 0, function* () {
24142
+ });
24143
+ }
24144
+ modifyRowDataForExport(rowData) {
24145
+ return rowData;
24146
+ }
24111
24147
  }
24112
24148
  ListBase.decorators = [
24113
24149
  { type: Directive }