Accessing parameter units in reports? #3526
-
|
I'm testing out reports - or labels to be more specific. I can successfully use the following to get an output: What I'm missing is the parameters unit, in this case 'mm' - any way to easily access this? |
Beta Was this translation helpful? Give feedback.
Answered by
SchrodingersGat
Aug 13, 2022
Replies: 1 comment 4 replies
-
|
I think something like the following should work: {% for param in part.parameters %}
{{ param.template.name }} : {{ param.data }} {{ param.template.units }}
{% endfor %}Note here that you're using |
Beta Was this translation helpful? Give feedback.
4 replies
Answer selected by
miggland
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment

I think something like the following should work:
{% for param in part.parameters %} {{ param.template.name }} : {{ param.data }} {{ param.template.units }} {% endfor %}Note here that you're using
part.parametersto directly access the parameters, not the top-levelparametersobject which returns the simplified dict object.