@fluxhub/fluxhub-lib 10.0.75 → 10.0.76

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.
@@ -8672,32 +8672,23 @@
8672
8672
  FHCurrencyFieldComponent.prototype.chg = function () {
8673
8673
  var _this = this;
8674
8674
  setTimeout(function () {
8675
- console.log(_this.formattedAmount.split(".").join("").split(",").join(""), parseFloat(_this.formattedAmount.split(".").join("").split(",").join("")));
8676
8675
  if (_this.decimal == 0)
8677
8676
  _this.value = parseFloat(_this.formattedAmount.split(".").join("").split(",").join(""));
8678
8677
  else
8679
8678
  _this.value = parseFloat(_this.formattedAmount.split(".").join("").split(",").join("."));
8680
- console.log('VALUE: ', _this.value);
8681
- /*
8682
- if (typeof this.value == "string") {
8683
- if (this.decimal == 0)
8684
- this.value = parseFloat(
8685
- this.value.split(".").join("").split(",").join("")
8686
- );
8687
- else
8688
- this.value = parseFloat(
8689
- this.value.split(".").join("").split(",").join(".")
8690
- );
8691
- }*/
8692
- //if(isNaN(this.value)){console.log('this.value ',this.value);this.value=0;}
8679
+ if (typeof _this.value == "string") {
8680
+ if (_this.decimal == 0)
8681
+ _this.value = parseFloat(_this.value.split(".").join("").split(",").join(""));
8682
+ else
8683
+ _this.value = parseFloat(_this.value.split(".").join("").split(",").join("."));
8684
+ }
8685
+ console.log("this.value ", _this.value);
8693
8686
  _this.onChange(_this.value);
8694
8687
  }, 0);
8695
8688
  };
8696
8689
  FHCurrencyFieldComponent.prototype.writeValue = function (value) {
8697
8690
  if (value == null)
8698
8691
  value = 0;
8699
- if (isNaN(value))
8700
- value = 0;
8701
8692
  if (value !== this.innerValue) {
8702
8693
  if (typeof value == "string") {
8703
8694
  if (this.decimal == 0)
@@ -8705,15 +8696,11 @@
8705
8696
  else
8706
8697
  value = parseFloat(value.split(".").join("").split(",").join("."));
8707
8698
  }
8708
- if (isNaN(value)) {
8709
- console.log('writeValue ', this.value);
8710
- this.value = 0;
8711
- }
8712
8699
  this.innerValue = value;
8713
8700
  this.value = value;
8714
- console.log('transform ini 1 ', this.value);
8701
+ // console.log('writeValue ini ',this.value);
8715
8702
  this.formattedAmount = this.transform(this.value, this.decimal);
8716
- console.log('transform fin 2 ', this.formattedAmount);
8703
+ // console.log('writeValue fin ',this.value);
8717
8704
  }
8718
8705
  // this.onChange(this.value);
8719
8706
  };
@@ -8734,11 +8721,8 @@
8734
8721
  // else
8735
8722
  // this.value = parseFloat(this.formattedAmount.split('.').join('').split(',').join('.'));
8736
8723
  // this.writeValue(this.value);
8737
- console.log('transform ini 2 ', _this.value);
8738
- if (_this.decimal != 0)
8739
- _this.formattedAmount = _this.transform(_this.value, _this.decimal);
8724
+ _this.formattedAmount = _this.transform(_this.value, _this.decimal);
8740
8725
  }, 0);
8741
- console.log('transform fin 2 ', this.formattedAmount);
8742
8726
  // Remove or comment this line if you dont want
8743
8727
  // to show the formatted amount in the textbox.
8744
8728
  // element.target.value = this.formattedAmount;
@@ -8749,9 +8733,6 @@
8749
8733
  };
8750
8734
  FHCurrencyFieldComponent.prototype.transform = function (value, fractionSize) {
8751
8735
  if (fractionSize === void 0) { fractionSize = 2; }
8752
- console.log('transform ', value);
8753
- if (fractionSize == 0)
8754
- return value + '';
8755
8736
  var _a = __read((value || "").toString().split("."), 2), integer = _a[0], _b = _a[1], fraction = _b === void 0 ? "" : _b;
8756
8737
  fraction =
8757
8738
  fractionSize > 0