tnx-shared 5.3.68 → 5.3.69

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.
@@ -18116,16 +18116,16 @@
18116
18116
  mdWidth: this.mdWidthWorkflow || 12,
18117
18117
  enableCaching: false,
18118
18118
  hiddenCheck: function (rootModel) { return !rootModel || rootModel.createTaskInstead; },
18119
- onChanged: function (evt) { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_d) {
18120
- switch (_d.label) {
18119
+ onChanged: function (evt) { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_e) {
18120
+ switch (_e.label) {
18121
18121
  case 0: return [4 /*yield*/, this.handleChangeWorkflowCode(evt)];
18122
- case 1: return [2 /*return*/, _d.sent()];
18122
+ case 1: return [2 /*return*/, _e.sent()];
18123
18123
  }
18124
18124
  }); }); },
18125
- onAdjustedValue: function (evt) { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_d) {
18126
- switch (_d.label) {
18125
+ onAdjustedValue: function (evt) { return __awaiter(_this, void 0, void 0, function () { return __generator(this, function (_e) {
18126
+ switch (_e.label) {
18127
18127
  case 0: return [4 /*yield*/, this.handleChangeWorkflowCode(evt)];
18128
- case 1: return [2 /*return*/, _d.sent()];
18128
+ case 1: return [2 /*return*/, _e.sent()];
18129
18129
  }
18130
18130
  }); }); }
18131
18131
  }));
@@ -18141,7 +18141,7 @@
18141
18141
  };
18142
18142
  DataFormBase.prototype.handleChangeWorkflowCode = function (evt) {
18143
18143
  return __awaiter(this, void 0, void 0, function () {
18144
- return __generator(this, function (_d) {
18144
+ return __generator(this, function (_e) {
18145
18145
  return [2 /*return*/];
18146
18146
  });
18147
18147
  });
@@ -18157,11 +18157,11 @@
18157
18157
  };
18158
18158
  DataFormBase.prototype._handleFormReady = function (formEvent) {
18159
18159
  return __awaiter(this, void 0, void 0, function () {
18160
- return __generator(this, function (_d) {
18161
- switch (_d.label) {
18160
+ return __generator(this, function (_e) {
18161
+ switch (_e.label) {
18162
18162
  case 0: return [4 /*yield*/, this.__handleFormReady(formEvent)];
18163
18163
  case 1:
18164
- _d.sent();
18164
+ _e.sent();
18165
18165
  return [2 /*return*/];
18166
18166
  }
18167
18167
  });
@@ -18169,8 +18169,8 @@
18169
18169
  };
18170
18170
  DataFormBase.prototype.__handleFormReady = function (formEvent) {
18171
18171
  return __awaiter(this, void 0, void 0, function () {
18172
- return __generator(this, function (_d) {
18173
- switch (_d.label) {
18172
+ return __generator(this, function (_e) {
18173
+ switch (_e.label) {
18174
18174
  case 0:
18175
18175
  if (!this.doNotCheckBaseService && !this.setting.baseService) {
18176
18176
  this._notifierService.showWarning(this.notConfigBaseServiceMessage);
@@ -18178,7 +18178,7 @@
18178
18178
  this.formControls = formEvent.formControls;
18179
18179
  return [4 /*yield*/, this.onFormInitialized(formEvent)];
18180
18180
  case 1:
18181
- _d.sent();
18181
+ _e.sent();
18182
18182
  this.onFormReady.emit({
18183
18183
  element: this,
18184
18184
  setting: this.setting,
@@ -18203,24 +18203,24 @@
18203
18203
  };
18204
18204
  DataFormBase.prototype.onBeforeGetDetail = function () {
18205
18205
  return __awaiter(this, void 0, void 0, function () {
18206
- return __generator(this, function (_d) {
18206
+ return __generator(this, function (_e) {
18207
18207
  return [2 /*return*/];
18208
18208
  });
18209
18209
  });
18210
18210
  };
18211
18211
  DataFormBase.prototype.getObjectDetail = function () {
18212
18212
  return __awaiter(this, void 0, void 0, function () {
18213
- return __generator(this, function (_d) {
18214
- switch (_d.label) {
18213
+ return __generator(this, function (_e) {
18214
+ switch (_e.label) {
18215
18215
  case 0: return [4 /*yield*/, this.setting.baseService.getDetailWithPermission(this.model.data.id, this.model.data.pid, this.getDetailPlusUrl)];
18216
- case 1: return [2 /*return*/, _d.sent()];
18216
+ case 1: return [2 /*return*/, _e.sent()];
18217
18217
  }
18218
18218
  });
18219
18219
  });
18220
18220
  };
18221
18221
  DataFormBase.prototype.getDetailCustom = function () {
18222
18222
  return __awaiter(this, void 0, void 0, function () {
18223
- return __generator(this, function (_d) {
18223
+ return __generator(this, function (_e) {
18224
18224
  return [2 /*return*/, null];
18225
18225
  });
18226
18226
  });
@@ -18228,33 +18228,33 @@
18228
18228
  DataFormBase.prototype.getDetail = function () {
18229
18229
  return __awaiter(this, void 0, void 0, function () {
18230
18230
  var resultCheck, response, event, event;
18231
- return __generator(this, function (_d) {
18232
- switch (_d.label) {
18231
+ return __generator(this, function (_e) {
18232
+ switch (_e.label) {
18233
18233
  case 0: return [4 /*yield*/, this.getDetailCustom()];
18234
18234
  case 1:
18235
- resultCheck = _d.sent();
18235
+ resultCheck = _e.sent();
18236
18236
  if (!(resultCheck == null)) return [3 /*break*/, 11];
18237
18237
  if (!!this._isFormAddNew()) return [3 /*break*/, 8];
18238
18238
  return [4 /*yield*/, this.onBeforeGetDetail()];
18239
18239
  case 2:
18240
- _d.sent();
18240
+ _e.sent();
18241
18241
  if (this.crudForm) {
18242
18242
  this.crudForm.setIsLoadedDataEdit(false);
18243
18243
  }
18244
18244
  return [4 /*yield*/, this.getObjectDetail()];
18245
18245
  case 3:
18246
- response = _d.sent();
18246
+ response = _e.sent();
18247
18247
  if (!response.data) return [3 /*break*/, 5];
18248
18248
  return [4 /*yield*/, this.modifyDetailData(response.data)];
18249
18249
  case 4:
18250
- _d.sent();
18251
- _d.label = 5;
18250
+ _e.sent();
18251
+ _e.label = 5;
18252
18252
  case 5: return [4 /*yield*/, this._processAfterGetData(response.data)];
18253
18253
  case 6:
18254
- _d.sent();
18254
+ _e.sent();
18255
18255
  return [4 /*yield*/, this.onAfterGetDetail()];
18256
18256
  case 7:
18257
- _d.sent();
18257
+ _e.sent();
18258
18258
  return [3 /*break*/, 10];
18259
18259
  case 8:
18260
18260
  if (!this.crudForm) return [3 /*break*/, 10];
@@ -18265,11 +18265,11 @@
18265
18265
  });
18266
18266
  return [4 /*yield*/, this.initDataAdd(event)];
18267
18267
  case 9:
18268
- _d.sent();
18268
+ _e.sent();
18269
18269
  this.initDefaultSettingFileControl(event);
18270
18270
  this.crudForm.initControlDefaultValueFromExternal();
18271
18271
  this.crudForm.fireModelChanged();
18272
- _d.label = 10;
18272
+ _e.label = 10;
18273
18273
  case 10: return [3 /*break*/, 17];
18274
18274
  case 11:
18275
18275
  if (!(resultCheck.success && resultCheck.data)) return [3 /*break*/, 15];
@@ -18281,13 +18281,13 @@
18281
18281
  }
18282
18282
  return [4 /*yield*/, this.modifyDetailData(resultCheck.data)];
18283
18283
  case 12:
18284
- _d.sent();
18284
+ _e.sent();
18285
18285
  return [4 /*yield*/, this._processAfterGetData(resultCheck.data)];
18286
18286
  case 13:
18287
- _d.sent();
18287
+ _e.sent();
18288
18288
  return [4 /*yield*/, this.onAfterGetDetail()];
18289
18289
  case 14:
18290
- _d.sent();
18290
+ _e.sent();
18291
18291
  return [3 /*break*/, 17];
18292
18292
  case 15:
18293
18293
  this.model.formState = exports.FormState.ADD;
@@ -18299,18 +18299,18 @@
18299
18299
  });
18300
18300
  return [4 /*yield*/, this.initDataAdd(event)];
18301
18301
  case 16:
18302
- _d.sent();
18302
+ _e.sent();
18303
18303
  this.initDefaultSettingFileControl(event);
18304
18304
  this.crudForm.initControlDefaultValueFromExternal();
18305
18305
  this.crudForm.fireModelChanged();
18306
- _d.label = 17;
18306
+ _e.label = 17;
18307
18307
  case 17: return [2 /*return*/];
18308
18308
  }
18309
18309
  });
18310
18310
  });
18311
18311
  };
18312
18312
  DataFormBase.prototype.initDataAdd = function (evt) {
18313
- return __awaiter(this, void 0, void 0, function () { return __generator(this, function (_d) {
18313
+ return __awaiter(this, void 0, void 0, function () { return __generator(this, function (_e) {
18314
18314
  return [2 /*return*/];
18315
18315
  }); });
18316
18316
  };
@@ -18326,8 +18326,8 @@
18326
18326
  return __awaiter(this, void 0, void 0, function () {
18327
18327
  var enableVersion;
18328
18328
  var _this = this;
18329
- return __generator(this, function (_d) {
18330
- switch (_d.label) {
18329
+ return __generator(this, function (_e) {
18330
+ switch (_e.label) {
18331
18331
  case 0:
18332
18332
  if (!data) {
18333
18333
  data = {};
@@ -18364,7 +18364,7 @@
18364
18364
  ) return [3 /*break*/, 2]; // setting để fix lỗi k load dc entity metadata cho cơ cấu tổ chức service
18365
18365
  return [4 /*yield*/, this._entityMetadataService.load(this.setting.baseService, this.context, true)];
18366
18366
  case 1:
18367
- _d.sent(); // force load để đọc từ csdl
18367
+ _e.sent(); // force load để đọc từ csdl
18368
18368
  enableVersion = this._entityMetadataService.getByCode('enableVersion');
18369
18369
  if (enableVersion == '1') {
18370
18370
  this.setting.filterCheckExistByVersion = [
@@ -18375,7 +18375,7 @@
18375
18375
  })
18376
18376
  ];
18377
18377
  }
18378
- _d.label = 2;
18378
+ _e.label = 2;
18379
18379
  case 2:
18380
18380
  this.disableBuildInField();
18381
18381
  return [2 /*return*/];
@@ -18384,7 +18384,7 @@
18384
18384
  });
18385
18385
  };
18386
18386
  DataFormBase.prototype.fixDateValue = function (control, parentModel, parentPath) {
18387
- var e_1, _d, e_2, _e, e_3, _f;
18387
+ var e_1, _e, e_2, _f, e_3, _g;
18388
18388
  var _parentPath = control.field;
18389
18389
  if (parentPath != null)
18390
18390
  _parentPath = parentPath + '.' + _parentPath;
@@ -18394,18 +18394,18 @@
18394
18394
  }
18395
18395
  var i = 0;
18396
18396
  try {
18397
- for (var _g = __values(parentModel[control.field]), _h = _g.next(); !_h.done; _h = _g.next()) {
18398
- var item = _h.value;
18397
+ for (var _h = __values(parentModel[control.field]), _j = _h.next(); !_j.done; _j = _h.next()) {
18398
+ var item = _j.value;
18399
18399
  try {
18400
- for (var _j = (e_2 = void 0, __values(control.rowTemplate)), _k = _j.next(); !_k.done; _k = _j.next()) {
18401
- var subControl = _k.value;
18400
+ for (var _k = (e_2 = void 0, __values(control.rowTemplate)), _l = _k.next(); !_l.done; _l = _k.next()) {
18401
+ var subControl = _l.value;
18402
18402
  this.fixDateValue(subControl, item, _parentPath + '[' + i + ']');
18403
18403
  }
18404
18404
  }
18405
18405
  catch (e_2_1) { e_2 = { error: e_2_1 }; }
18406
18406
  finally {
18407
18407
  try {
18408
- if (_k && !_k.done && (_e = _j.return)) _e.call(_j);
18408
+ if (_l && !_l.done && (_f = _k.return)) _f.call(_k);
18409
18409
  }
18410
18410
  finally { if (e_2) throw e_2.error; }
18411
18411
  }
@@ -18415,7 +18415,7 @@
18415
18415
  catch (e_1_1) { e_1 = { error: e_1_1 }; }
18416
18416
  finally {
18417
18417
  try {
18418
- if (_h && !_h.done && (_d = _g.return)) _d.call(_g);
18418
+ if (_j && !_j.done && (_e = _h.return)) _e.call(_h);
18419
18419
  }
18420
18420
  finally { if (e_1) throw e_1.error; }
18421
18421
  }
@@ -18425,15 +18425,15 @@
18425
18425
  parentModel[control.field] = {};
18426
18426
  }
18427
18427
  try {
18428
- for (var _l = __values(control.controls), _m = _l.next(); !_m.done; _m = _l.next()) {
18429
- var subControl = _m.value;
18428
+ for (var _m = __values(control.controls), _o = _m.next(); !_o.done; _o = _m.next()) {
18429
+ var subControl = _o.value;
18430
18430
  this.fixDateValue(subControl, parentModel[control.field], _parentPath);
18431
18431
  }
18432
18432
  }
18433
18433
  catch (e_3_1) { e_3 = { error: e_3_1 }; }
18434
18434
  finally {
18435
18435
  try {
18436
- if (_m && !_m.done && (_f = _l.return)) _f.call(_l);
18436
+ if (_o && !_o.done && (_g = _m.return)) _g.call(_m);
18437
18437
  }
18438
18438
  finally { if (e_3) throw e_3.error; }
18439
18439
  }
@@ -18467,11 +18467,11 @@
18467
18467
  }
18468
18468
  };
18469
18469
  DataFormBase.prototype._addRequiredValidator = function (schema) {
18470
- var e_4, _d;
18470
+ var e_4, _e;
18471
18471
  var exist = false;
18472
18472
  try {
18473
- for (var _e = __values(schema.validators), _f = _e.next(); !_f.done; _f = _e.next()) {
18474
- var validator = _f.value;
18473
+ for (var _f = __values(schema.validators), _g = _f.next(); !_g.done; _g = _f.next()) {
18474
+ var validator = _g.value;
18475
18475
  if (validator instanceof RequiredValidator) {
18476
18476
  exist = true;
18477
18477
  break;
@@ -18481,7 +18481,7 @@
18481
18481
  catch (e_4_1) { e_4 = { error: e_4_1 }; }
18482
18482
  finally {
18483
18483
  try {
18484
- if (_f && !_f.done && (_d = _e.return)) _d.call(_e);
18484
+ if (_g && !_g.done && (_e = _f.return)) _e.call(_f);
18485
18485
  }
18486
18486
  finally { if (e_4) throw e_4.error; }
18487
18487
  }
@@ -18491,11 +18491,11 @@
18491
18491
  schema.required = true;
18492
18492
  };
18493
18493
  DataFormBase.prototype._removeRequiredValidator = function (schema) {
18494
- var e_5, _d;
18494
+ var e_5, _e;
18495
18495
  var validators = [];
18496
18496
  try {
18497
- for (var _e = __values(schema.validators), _f = _e.next(); !_f.done; _f = _e.next()) {
18498
- var validator = _f.value;
18497
+ for (var _f = __values(schema.validators), _g = _f.next(); !_g.done; _g = _f.next()) {
18498
+ var validator = _g.value;
18499
18499
  if (validator instanceof RequiredValidator) {
18500
18500
  }
18501
18501
  else {
@@ -18506,7 +18506,7 @@
18506
18506
  catch (e_5_1) { e_5 = { error: e_5_1 }; }
18507
18507
  finally {
18508
18508
  try {
18509
- if (_f && !_f.done && (_d = _e.return)) _d.call(_e);
18509
+ if (_g && !_g.done && (_e = _f.return)) _e.call(_f);
18510
18510
  }
18511
18511
  finally { if (e_5) throw e_5.error; }
18512
18512
  }
@@ -18523,7 +18523,7 @@
18523
18523
  };
18524
18524
  DataFormBase.prototype.modifyDetailData = function (data) {
18525
18525
  return __awaiter(this, void 0, void 0, function () {
18526
- return __generator(this, function (_d) {
18526
+ return __generator(this, function (_e) {
18527
18527
  return [2 /*return*/];
18528
18528
  });
18529
18529
  });
@@ -18534,36 +18534,36 @@
18534
18534
  DataFormBase.prototype.save = function () {
18535
18535
  return __awaiter(this, void 0, void 0, function () {
18536
18536
  var validated;
18537
- return __generator(this, function (_d) {
18538
- switch (_d.label) {
18537
+ return __generator(this, function (_e) {
18538
+ switch (_e.label) {
18539
18539
  case 0: return [4 /*yield*/, this.validateFormBase()];
18540
18540
  case 1:
18541
- validated = _d.sent();
18541
+ validated = _e.sent();
18542
18542
  if (!validated) return [3 /*break*/, 9];
18543
18543
  return [4 /*yield*/, this.onBeforeSave()];
18544
18544
  case 2:
18545
- _d.sent();
18545
+ _e.sent();
18546
18546
  this.triggerSaveFileUpload();
18547
18547
  if (!this.autoSave) return [3 /*break*/, 7];
18548
18548
  if (!(this._isFormEdit() || this._isFormView())) return [3 /*break*/, 4];
18549
18549
  return [4 /*yield*/, this.onUpdate()];
18550
18550
  case 3:
18551
- _d.sent();
18551
+ _e.sent();
18552
18552
  return [3 /*break*/, 6];
18553
18553
  case 4:
18554
18554
  if (!this._isFormAddNew()) return [3 /*break*/, 6];
18555
18555
  return [4 /*yield*/, this.onInsert()];
18556
18556
  case 5:
18557
- _d.sent();
18557
+ _e.sent();
18558
18558
  return [3 /*break*/, 6];
18559
18559
  case 6: return [3 /*break*/, 8];
18560
18560
  case 7:
18561
18561
  this.handleManualSave();
18562
- _d.label = 8;
18562
+ _e.label = 8;
18563
18563
  case 8: return [3 /*break*/, 10];
18564
18564
  case 9:
18565
18565
  this.model.submitting = false;
18566
- _d.label = 10;
18566
+ _e.label = 10;
18567
18567
  case 10: return [2 /*return*/];
18568
18568
  }
18569
18569
  });
@@ -18576,17 +18576,17 @@
18576
18576
  };
18577
18577
  DataFormBase.prototype._getResultValidate = function () {
18578
18578
  return __awaiter(this, void 0, void 0, function () {
18579
- return __generator(this, function (_d) {
18580
- switch (_d.label) {
18579
+ return __generator(this, function (_e) {
18580
+ switch (_e.label) {
18581
18581
  case 0: return [4 /*yield*/, this.validateFormBase()];
18582
- case 1: return [2 /*return*/, _d.sent()];
18582
+ case 1: return [2 /*return*/, _e.sent()];
18583
18583
  }
18584
18584
  });
18585
18585
  });
18586
18586
  };
18587
18587
  DataFormBase.prototype.validateForm = function (resultValidateBase) {
18588
18588
  return __awaiter(this, void 0, void 0, function () {
18589
- return __generator(this, function (_d) {
18589
+ return __generator(this, function (_e) {
18590
18590
  return [2 /*return*/, true];
18591
18591
  });
18592
18592
  });
@@ -18594,18 +18594,18 @@
18594
18594
  DataFormBase.prototype.validateFormBase = function () {
18595
18595
  return __awaiter(this, void 0, void 0, function () {
18596
18596
  var resultValidateBase, resultValidate;
18597
- return __generator(this, function (_d) {
18598
- switch (_d.label) {
18597
+ return __generator(this, function (_e) {
18598
+ switch (_e.label) {
18599
18599
  case 0:
18600
18600
  resultValidateBase = true;
18601
18601
  if (!this.crudForm) return [3 /*break*/, 2];
18602
18602
  return [4 /*yield*/, this.crudForm.validateForm(this.setValidateForm)];
18603
18603
  case 1:
18604
- resultValidateBase = _d.sent();
18605
- _d.label = 2;
18604
+ resultValidateBase = _e.sent();
18605
+ _e.label = 2;
18606
18606
  case 2: return [4 /*yield*/, this.validateForm(resultValidateBase)];
18607
18607
  case 3:
18608
- resultValidate = _d.sent();
18608
+ resultValidate = _e.sent();
18609
18609
  // Bỏ check valid form công việc. nếu như form công việc không valid thì không tự động tạo công việc
18610
18610
  // if (this.dynamicControl[FieldDefineIsTaskFormControl]
18611
18611
  // && this.dynamicControl[FieldDefineIsTaskFormControl]._component
@@ -18634,7 +18634,7 @@
18634
18634
  };
18635
18635
  DataFormBase.prototype.onAfterGetDetail = function () {
18636
18636
  return __awaiter(this, void 0, void 0, function () {
18637
- return __generator(this, function (_d) {
18637
+ return __generator(this, function (_e) {
18638
18638
  return [2 /*return*/];
18639
18639
  });
18640
18640
  });
@@ -18642,8 +18642,8 @@
18642
18642
  DataFormBase.prototype.onInsert = function () {
18643
18643
  return __awaiter(this, void 0, void 0, function () {
18644
18644
  var taskForm, resultValidateFormTask, confirmed;
18645
- return __generator(this, function (_d) {
18646
- switch (_d.label) {
18645
+ return __generator(this, function (_e) {
18646
+ switch (_e.label) {
18647
18647
  case 0:
18648
18648
  this.setDefaultValue(this.model.data);
18649
18649
  if (!(this.dynamicControl[FieldDefineIsTaskFormControl]
@@ -18651,11 +18651,11 @@
18651
18651
  taskForm = this.dynamicControl[FieldDefineIsTaskFormControl]._component;
18652
18652
  return [4 /*yield*/, taskForm._getResultValidate()];
18653
18653
  case 1:
18654
- resultValidateFormTask = _d.sent();
18654
+ resultValidateFormTask = _e.sent();
18655
18655
  if (resultValidateFormTask) {
18656
18656
  this.model.data.itemCongViec = taskForm.model.data;
18657
18657
  }
18658
- _d.label = 2;
18658
+ _e.label = 2;
18659
18659
  case 2:
18660
18660
  if (this.model.data.createTaskInstead) {
18661
18661
  // reset field _WorkflowCode để backend không chạy quy trình bản ghi
@@ -18663,12 +18663,12 @@
18663
18663
  }
18664
18664
  return [4 /*yield*/, this.createConfirmIfRequire()];
18665
18665
  case 3:
18666
- confirmed = _d.sent();
18666
+ confirmed = _e.sent();
18667
18667
  if (!confirmed)
18668
18668
  return [2 /*return*/];
18669
18669
  return [4 /*yield*/, this._insert()];
18670
18670
  case 4:
18671
- _d.sent();
18671
+ _e.sent();
18672
18672
  return [2 /*return*/];
18673
18673
  }
18674
18674
  });
@@ -18695,11 +18695,11 @@
18695
18695
  DataFormBase.prototype._insert = function () {
18696
18696
  return __awaiter(this, void 0, void 0, function () {
18697
18697
  var _this = this;
18698
- return __generator(this, function (_d) {
18698
+ return __generator(this, function (_e) {
18699
18699
  this.getPromiseActionInsert()
18700
18700
  .then(function (response) { return __awaiter(_this, void 0, void 0, function () {
18701
- return __generator(this, function (_d) {
18702
- switch (_d.label) {
18701
+ return __generator(this, function (_e) {
18702
+ switch (_e.label) {
18703
18703
  case 0:
18704
18704
  this.model.submitting = false;
18705
18705
  this.showMessageAfterInsert(response.success, response);
@@ -18707,7 +18707,7 @@
18707
18707
  this.model.data.id = response.data;
18708
18708
  return [4 /*yield*/, this.onAfterSave(response)];
18709
18709
  case 1:
18710
- _d.sent();
18710
+ _e.sent();
18711
18711
  this.onSaved.emit({
18712
18712
  id: this.model.data.id,
18713
18713
  insert: true
@@ -18715,7 +18715,7 @@
18715
18715
  return [3 /*break*/, 3];
18716
18716
  case 2:
18717
18717
  this.handleInsertError();
18718
- _d.label = 3;
18718
+ _e.label = 3;
18719
18719
  case 3: return [2 /*return*/];
18720
18720
  }
18721
18721
  });
@@ -18739,19 +18739,19 @@
18739
18739
  DataFormBase.prototype.onUpdate = function () {
18740
18740
  return __awaiter(this, void 0, void 0, function () {
18741
18741
  var _this = this;
18742
- return __generator(this, function (_d) {
18742
+ return __generator(this, function (_e) {
18743
18743
  this.setDefaultValue(this.model.data);
18744
18744
  this.getPromiseActionUpdate()
18745
18745
  .then(function (response) { return __awaiter(_this, void 0, void 0, function () {
18746
- return __generator(this, function (_d) {
18747
- switch (_d.label) {
18746
+ return __generator(this, function (_e) {
18747
+ switch (_e.label) {
18748
18748
  case 0:
18749
18749
  this.model.submitting = false;
18750
18750
  this.showMessageAfterUpdate(response.success, response);
18751
18751
  if (!response.success) return [3 /*break*/, 2];
18752
18752
  return [4 /*yield*/, this.onAfterSave(response)];
18753
18753
  case 1:
18754
- _d.sent();
18754
+ _e.sent();
18755
18755
  this.onSaved.emit({
18756
18756
  id: this.model.data.id,
18757
18757
  insert: false
@@ -18759,7 +18759,7 @@
18759
18759
  return [3 /*break*/, 3];
18760
18760
  case 2:
18761
18761
  this.handleUpdateError();
18762
- _d.label = 3;
18762
+ _e.label = 3;
18763
18763
  case 3: return [2 /*return*/];
18764
18764
  }
18765
18765
  });
@@ -18781,16 +18781,16 @@
18781
18781
  return this.setting.baseService.put(this.model.data.id.toString(), this.model.data);
18782
18782
  };
18783
18783
  DataFormBase.prototype.setDefaultValue = function (model) {
18784
- var _a;
18785
- var _b, _c;
18784
+ var _a, _b;
18785
+ var _c, _d;
18786
18786
  if (model.isBuildIn === null || model.isBuildIn === undefined) {
18787
18787
  model.isBuildIn = false;
18788
18788
  }
18789
18789
  if (model.isBuildInAll === null || model.isBuildInAll === undefined) {
18790
18790
  model.isBuildInAll = false;
18791
18791
  }
18792
- if (this.parentSetting.enableReorderRow) {
18793
- (_a = (_b = this.model.data)[_c = this.parentSetting.columnSetting.sortField]) !== null && _a !== void 0 ? _a : (_b[_c] = this.parentModel.total + 1);
18792
+ if ((_a = this.parentSetting) === null || _a === void 0 ? void 0 : _a.enableReorderRow) {
18793
+ (_b = (_c = this.model.data)[_d = this.parentSetting.columnSetting.sortField]) !== null && _b !== void 0 ? _b : (_c[_d] = this.parentModel.total + 1);
18794
18794
  }
18795
18795
  };
18796
18796
  DataFormBase.prototype.showMessageAfterInsert = function (isSuccess, error) {
@@ -18828,7 +18828,7 @@
18828
18828
  };
18829
18829
  DataFormBase.prototype.onFormInitialized = function (data) {
18830
18830
  return __awaiter(this, void 0, void 0, function () {
18831
- return __generator(this, function (_d) {
18831
+ return __generator(this, function (_e) {
18832
18832
  return [2 /*return*/];
18833
18833
  });
18834
18834
  });