Formatting for totals row replicates the LookML on the data section of the explore but doesn't transfer to the viz section

Hello

We’re having an issue with the formatting of the Totals row when we select this option on the data part  of the explore. 

The value_format for the measure is defaulted in the LookML as below

              value_format_name: decimal_0

And it is formatted in LookML using the Liquid HTML here

              html: {% if value < 0 %}
                 <font style="color: #990000"> ▼ ( {{ rendered_value | times: -1 | round: 0}} ) </font>
              {% elsif value > 0 %}
                 <font style="color: #009900"> ▲ {{ rendered_value | round: 0}}  </font>
              {% else %}
                 <font style="color: #000000"> {{ rendered_value | round: 0}} </font>
              {% endif %} ;;

(I have tried both value and rendered_value without success), these format correctly for the relevant measures and dimensions in the data section of the explore (see below)

42aa77f8-e621-41ba-abdf-01ea308a0cee.png
Totals row formatted the same as the table rows above

This doesn’t transfer to the viz

7717ad4f-0e6c-4157-b242-60c6b4bedc1b.png
Totals row loses the colour/decimals/and shape formatting in the viz

I can live without the colour and the shape but the decimal places needs to be resolved, any help gratefully received.  Many thanks.

0 3 898
3 REPLIES 3

leobardor
Participant V

Hi Sstanford!

Based on the liquid syntax, did you try using “round” without arguments?

URL of example:

https://shopify.github.io/liquid/filters/round/

f14123c4-9949-4bd6-8191-49c5f1ffe64f.png

Best regards,

Leo

Hi Leo

Thanks for the suggestion, I’ve amended the code as below but it still generates the multiple decimal value in the totals row in the viz . 

35b659d6-426e-41c8-851d-2aa74b18cf69.png
c0d969bf-7385-40c8-abff-0c3236118a42.png

Kind regards.

I’m having the same problems as this, it looks like the html parameter is not picked up or used in the totals.

Top Labels in this Space
Top Solution Authors