@steedos-widgets/amis-lib 6.10.19 → 6.10.21

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.
package/dist/index.esm.js CHANGED
@@ -20135,10 +20135,6 @@ const getFieldEditTpl = async (field, label)=>{
20135
20135
  visibleOn: field.visibleOn,
20136
20136
  requiredOn: field.requiredOn
20137
20137
  };
20138
-
20139
- if(field.formula){
20140
- tpl.value = `$${field.formula}`;
20141
- }
20142
20138
 
20143
20139
  if(isOpinionField(field)){
20144
20140
  tpl.type = 'input-group';
@@ -20336,10 +20332,16 @@ const getFieldEditTpl = async (field, label)=>{
20336
20332
  } else {
20337
20333
  tpl.type = "input-text";
20338
20334
  }
20335
+ if(field.formula){
20336
+ tpl.value = `$${field.formula}`;
20337
+ }
20339
20338
  break;
20340
20339
  case "number":
20341
20340
  tpl.type = "input-number";
20342
- tpl.precision=2;
20341
+ tpl.precision=field.digits;
20342
+ if(field.formula){
20343
+ tpl.value = `$${field.formula}`;
20344
+ }
20343
20345
  break;
20344
20346
  case "date":
20345
20347
  tpl.type = "input-date";