Merge syntax on ui-only formula fields not displaying data according to metadata

  • 1
  • Problem
  • Updated 3 years ago
  • Acknowledged
Ui-only field like this:


Merge Syntax like this:

{{$Model.scheduledInitialAppointments.data.0.Percent}}

Expected Result in runtime:
47%

Actual Result in runtime:

0.4727272727272727
Photo of Matt Sones

Matt Sones, Champion

  • 31,478 Points 20k badge 2x thumb

Posted 3 years ago

  • 1
Photo of Matt Sones

Matt Sones, Champion

  • 31,478 Points 20k badge 2x thumb
Anyone know a way around this? the long strings of numbers are getting really ugly...
Photo of Matt Sones

Matt Sones, Champion

  • 31,478 Points 20k badge 2x thumb
I suppose I could ROUND(value*100) to all my percent fields, and return them as TEXT instead with + '%'
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,006 Points 20k badge 2x thumb
Are you sure that your "percent" field is not a string field?  If it is you just need to mulply it by 1 and then the percentage rendering tools in the formula will work. 
Photo of Matt Sones

Matt Sones, Champion

  • 31,478 Points 20k badge 2x thumb
Rob,

Take a look at the image in the original post. The "Percent" field is a formula field with type Percent.
Length 3, Decimals 0.
Photo of Rob Hatch

Rob Hatch, Official Rep

  • 44,006 Points 20k badge 2x thumb
Ok,  I misunderstood.  I thought that your formula was:   {{$Model.scheduledInitialAppointments.data.0.Percent}}    (Which is a valid formula btw)  I guess you are using the merge syntax to show the field on your page, and in that case you are right - we are not processing the rendering suggested by the metadata override.  This has been noted...
Photo of Matt Sones

Matt Sones, Champion

  • 31,478 Points 20k badge 2x thumb
Thanks, Rob...

Any thoughts on when this might be updated? I have to weigh the work of changing all my percent formula fields to text fields with ROUND(old_percent_formula) + '%'... or waiting until the fix...
Photo of Matt Sones

Matt Sones, Champion

  • 31,478 Points 20k badge 2x thumb
As an aside... being able to use global merge syntax in formulas is awesome. :)
Photo of Matt Sones

Matt Sones, Champion

  • 31,478 Points 20k badge 2x thumb
any update on this?
Photo of Tami Lust

Tami Lust

  • 5,280 Points 5k badge 2x thumb
I am experiencing this issue as well. Trying to use a Ui-Only percent field in the title of a graph and the meta data is not being honored. Any update on this?