kwikid-forms 0.0.7 → 0.0.8

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.
@@ -1576,12 +1576,14 @@
1576
1576
  };
1577
1577
  var convertValueFromKwikUIFormatToBasicFormat = function (field, value) {
1578
1578
  var convertedValue = value;
1579
- switch (field.type) {
1580
- case EFieldType.DATE:
1581
- convertedValue = convertTuiDayFormatToDateString(value);
1582
- break;
1583
- default:
1584
- break;
1579
+ if (isNotEmpty(value)) {
1580
+ switch (field.type) {
1581
+ case EFieldType.DATE:
1582
+ convertedValue = convertTuiDayFormatToDateString(value);
1583
+ break;
1584
+ default:
1585
+ break;
1586
+ }
1585
1587
  }
1586
1588
  return convertedValue;
1587
1589
  };
@@ -3487,11 +3489,11 @@
3487
3489
  }
3488
3490
  if (field.key === "contact_number") {
3489
3491
  field = _this.setFieldKeyValue(field, "type", "phone");
3492
+ }
3493
+ if (field.type === "phone" || field.type === "number") {
3490
3494
  field.properties = _this.setMissingFieldKeyValue(field.properties, "countryCode", "+91");
3491
3495
  field.properties = _this.setMissingFieldKeyValue(field.properties, "phoneMaskAfterCountryCode", "####-######");
3492
3496
  field.properties = _this.setMissingFieldKeyValue(field.properties, "removeCountryCodeFromValue", true);
3493
- }
3494
- if (field.type === "phone" || field.type === "number") {
3495
3497
  field.properties = _this.setMissingFieldKeyValue(field.properties, "decimal", "never");
3496
3498
  field.properties = _this.setMissingFieldKeyValue(field.properties, "prefix", "");
3497
3499
  field.properties = _this.setMissingFieldKeyValue(field.properties, "postfix", "");