Преглед изворни кода

fix(core): Further fix on custom field float default

Michael Bromley пре 3 година
родитељ
комит
b8fdbd8b31
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      packages/core/src/entity/register-custom-entity-fields.ts

+ 1 - 1
packages/core/src/entity/register-custom-entity-fields.ts

@@ -110,7 +110,7 @@ function registerCustomFieldsForEntity(
                         // unless you specify the precision.
                         const defaultValueDecimalPlaces = customField.defaultValue.toString().split('.')[1];
                         if (defaultValueDecimalPlaces) {
-                            options.precision = defaultValueDecimalPlaces.length;
+                            options.scale = defaultValueDecimalPlaces.length;
                         }
                     }
                     if (