Parameterize configuration fields, custom variable name
Hi community,
I would like to parameterize some fields in a template and also for more clarity would like to have custom variable name, not the one that is proposed by the system. However, when I change variable name I'm getting an error, field just red and I can't proceed. For example :
How I can solve that? Or is it possible to have customized variable name at all?
Comments
-
Hello,
You can customize as long as you are following syntax. The error is about not meeting the minimum requirements,
its expecting "v_" before vni and "__x" after uplink.
E.G. {$v_vni-0-3_Bandwidth_Uplink__M}
You can customize inbetween text as you like, as in e.g.
{$v_vni0/3_Uplink__BW}. Hope this helps.
Thank you.
Accepted as Solution -
thank you Rao
-
Hi fun4net,
As Rao mentions, the syntax is important when using variables in Service Templates, Device Templates, etc.,. To add a bit to his response...
The syntax must match depending on the variable being assigned. This variable syntax can be seen when clicking on the gear icon and looking at the system generated syntax. The variable name will follow the below syntax:
{$v_<description>__<variable_type>}
"{$v_" at the beginning is required and cannot be changed.
"__<variable_type>}" at the end is required and cannot be changed.
"<description>" can be changed / customized for more clarity.
When applying this to the example you posted, the pre-defined variable would look similar to the below:
{$v_vni-0-3_Bandwidth_Uplink__uplink}
The description (vni-0-3_Bandwidth_Uplink) can be changed / customized to something like the below as an example.
{$v_vni-0-3_Internet_Link__uplink}
Please note when changing the description mentioned above, the only special characters that can be used are "-" and "_". Also, do not use a double underscore ("__") when changing the description.