fantasy-ngzorro 1.3.44 → 1.3.45

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.
@@ -2262,7 +2262,7 @@ var HdFormLinesComponent = /** @class */ (function () {
2262
2262
  function (item) {
2263
2263
  // 新增行 初始数据都为null
2264
2264
  formGroupObj[item.name] = _this.fb.control({
2265
- value: formLinesDataItem[item.name] === 0 ? 0 : (formLinesDataItem[item.name] || item.value || null),
2265
+ value: _this.judgeValueIsNotEmpty(formLinesDataItem[item.name]) ? formLinesDataItem[item.name] : (item.value || null),
2266
2266
  disabled: item.disabled
2267
2267
  }, item.require ? [Validators.required] : []);
2268
2268
  if (item.selectOption && item.selectOption.label) {
@@ -2666,7 +2666,7 @@ var HdFormLinesComponent = /** @class */ (function () {
2666
2666
  function (item) {
2667
2667
  // 新增行 初始数据都为null
2668
2668
  formGroupObj[item.name] = _this.fb.control({
2669
- value: formLinesDataItem[item.name] === 0 ? 0 : (formLinesDataItem[item.name] || item.value || null),
2669
+ value: _this.judgeValueIsNotEmpty(formLinesDataItem[item.name]) ? formLinesDataItem[item.name] : (item.value || null),
2670
2670
  disabled: item.disabled
2671
2671
  }, item.require ? [Validators.required] : []);
2672
2672
  if (item.selectOption && item.selectOption.label) {
@@ -3101,6 +3101,22 @@ var HdFormLinesComponent = /** @class */ (function () {
3101
3101
  return '<空>';
3102
3102
  }
3103
3103
  };
3104
+ /**
3105
+ * @param {?} str
3106
+ * @return {?}
3107
+ */
3108
+ HdFormLinesComponent.prototype.judgeValueIsNotEmpty = /**
3109
+ * @param {?} str
3110
+ * @return {?}
3111
+ */
3112
+ function (str) {
3113
+ if (str === null && str === undefined) {
3114
+ return false;
3115
+ }
3116
+ else {
3117
+ return true;
3118
+ }
3119
+ };
3104
3120
  HdFormLinesComponent.decorators = [
3105
3121
  { type: Component, args: [{
3106
3122
  selector: 'hd-form-lines',