{%- macro fmt_int(val) -%} {%- if val is not none -%} {{ "{:,}".format(val) }} {%- else -%} — {%- endif -%} {%- endmacro -%} {%- macro fmt_float(val) -%} {%- if val is not none -%} {{ "%.2f" % val }} {%- else -%} — {%- endif -%} {%- endmacro -%}