@seniorsistemas/angular-components 16.10.3 → 16.10.5

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.
@@ -4203,11 +4203,11 @@
4203
4203
  .then(function (metadata) { return _this.setModifiedDate(metadata); });
4204
4204
  };
4205
4205
  FileUploadComponent.prototype.setModifiedDate = function (metadata) {
4206
- var hour = moment$4(metadata.modified).hour();
4207
- var minutes = moment$4(metadata.modified).minutes();
4208
- var day = moment$4(metadata.modified).date();
4209
- var month = moment$4(metadata.modified).month();
4210
- var fullYear = moment$4(metadata.modified).year();
4206
+ var hour = moment$4(metadata.modified).format("HH");
4207
+ var minutes = moment$4(metadata.modified).format("mm");
4208
+ var day = moment$4(metadata.modified).format("DD");
4209
+ var month = moment$4(metadata.modified).format("MM");
4210
+ var fullYear = moment$4(metadata.modified).format("YYYY");
4211
4211
  this.modifiedDate = this.translate.instant("platform.angular_components.date_modified_custom_blob", { hour: hour, minutes: minutes, day: day, month: month, fullYear: fullYear });
4212
4212
  };
4213
4213
  var FileUploadComponent_1;
@@ -7937,7 +7937,8 @@
7937
7937
  _this.parentControl.markAsPristine();
7938
7938
  }))
7939
7939
  .subscribe(function (response) {
7940
- var _a = __read(response, 2), customFieldsResponse = _a[0], localeOptions = _a[1];
7940
+ var _a;
7941
+ var _b = __read(response, 2), customFieldsResponse = _b[0], localeOptions = _b[1];
7941
7942
  var defaults = {};
7942
7943
  defaults[CustomFieldType.String] = {};
7943
7944
  defaults[CustomFieldType.Boolean] = { defaultValue: false };
@@ -7954,12 +7955,13 @@
7954
7955
  defaults[CustomFieldType.Any] = {};
7955
7956
  if (!customFieldsResponse || !customFieldsResponse.entity_)
7956
7957
  return;
7957
- var _b = customFieldsResponse.entity_, active = _b.active, fields = _b.fields;
7958
+ var _c = customFieldsResponse.entity_, active = _c.active, fields = _c.fields;
7958
7959
  if (!active)
7959
7960
  return;
7960
7961
  fields
7961
7962
  .filter(function (field) { return field.customizable && field.customization && field.customization.active; })
7962
7963
  .forEach(function (field) {
7964
+ var _a;
7963
7965
  var formField = _this.getFormField(field, localeOptions);
7964
7966
  var fieldType = field.type;
7965
7967
  if (field.type === CustomFieldType.Blob && _this.value && _this.value[formField.name])
@@ -7978,7 +7980,7 @@
7978
7980
  validators.push(forms.Validators.pattern(validationRegex));
7979
7981
  if (fieldType === CustomFieldType.Integer && !formField.mask)
7980
7982
  validators.push(forms.Validators.pattern(/^\-?\d*$/));
7981
- if (formField.required()) {
7983
+ if ((_a = formField.required) === null || _a === void 0 ? void 0 : _a.call(formField)) {
7982
7984
  validators.push(forms.Validators.required);
7983
7985
  }
7984
7986
  var control = new forms.FormControl({ value: defaults[fieldType].defaultValue, disabled: _this.formGroup.disabled }, validators);
@@ -7988,6 +7990,7 @@
7988
7990
  _this.createFieldCustomization(fields);
7989
7991
  _this.formGroup.patchValue(_this.parseValuesForFields(_this.value));
7990
7992
  _this.ready = true;
7993
+ (_a = _this.ready$) === null || _a === void 0 ? void 0 : _a.next(true);
7991
7994
  });
7992
7995
  };
7993
7996
  CustomFieldsComponent.prototype.ngOnDestroy = function () {
@@ -8388,6 +8391,9 @@
8388
8391
  __decorate([
8389
8392
  core.Input()
8390
8393
  ], CustomFieldsComponent.prototype, "showFileUploadDate", void 0);
8394
+ __decorate([
8395
+ core.Input()
8396
+ ], CustomFieldsComponent.prototype, "ready$", void 0);
8391
8397
  CustomFieldsComponent = CustomFieldsComponent_1 = __decorate([
8392
8398
  core.Component({
8393
8399
  selector: "s-custom-fields",